Skip to content

Let getSupport() check if WP mode is set to auto before changing WP needlessly

Created by: Moult

Also refactor getSupport() function to be a little bit more semantic and reduce nested if statements so logic is clearer.

To check that it all works as expected, I tested working plane "auto" mode behaviour as follows:

  1. Set to auto.
  2. The simplest case is that it sets the working plane to current "View" rotation of the viewport.
  3. If you have a face selected already, it will set the WP to that face when you draft your new objects
  4. Otherwise, if you begin drafting, but start drafting on an existing object's face, the WP will match that face's alignment

If you WP mode is not on "auto", it will stay on whatever you set to WP to and will not change (which was what the report on the forum was all about).

https://forum.freecadweb.org/viewtopic.php?f=23&t=36508

Merge request reports