* PartDesign: Enable selecting a sketch as base plane of another sketch
* to squash
* Part: Attacher: enable attaching to empty objects such as empty Sketch or Body.
* Update SketchWorkflow.cpp
Removes check on function parameters for height & length (first
introduced in commit 5217b24), relying on values assigned in "obj".
If those params are present, they're assigned to "obj" anyway, so
the check is redundant.
Fixes#22585
With PR 19941 there is a regression where parts of the document
won't be restored. This is caused by overriding the virtual method
handleChangedPropertyType() but not calling the method of the base class.
While searching for a fix another problem showed up where (due to the
incomplete loading) exceptions are thrown but not handled within TD.
Therefore the method recompute() is overridden in DrawView to also handle
OCC exceptions.
Unlike in the bug description of issue 19654 the user doesn't have
to preselect an edge in the 3D view but first start the dimension
command and then select an edge.
This commit adds some security checks to TechDrawHandler::quit(),
TechDrawHandler::getPage() and TDHandlerDimension::onSelectionChanged()
to be on the safe side that no null pointers are dereferenced.
But the ultimative fix for this whole problem is to change
activateHandler() and immediately delete the passed TechDrawHandler if
it fails to find the appropriate QGVPage. This is needed as otherwise
the handler behaves like a ghost object that affects the selection
mechanism and disallows to select anything in the 3D view or the tree
view.
Fixes issue 19654
When validating distance joints, parts would move from preview position to
a different valid solution. This was caused by preSolve() being called
inconsistently - applied during offset changes for all joint types, but
distance joints are not in JointUsingPreSolve list.
Fix: Only call preSolve() for joint types that are designed to use it,
matching the logic used elsewhere in the codebase.
When user has specified a filter for a multi selection attempt, for
example Ctrl + clicking on a disallowed edge, the visual highlighting of
previously selected valid objects (that filter allowed) would disappear,
even though they were still internally valid in selection system.
The root cause of that was that when `addSelection()` failed, the code
still applied a `SoSelectionElementAction::None` to the scene graph
path, which was clearing visual highlighting for all objects in that
path, including those valid selection.
So, the fix is to set `pPath` to `nullptr` if selection fails, to
prevent any visual action from happening and being applied, in essence
leaving correct (and existing) selection untouched.
* Measure: Add circle center distance types to quickmeasure
* Measure: Add cylinder axis distance types to quickmeasure
* Measure: Fix PointToCylinder minimum distance not computing
* Quickmeasure: compute circle and cylinder diameters when they are closed
* Quickmeasure: add angle measurement between cylinder & circle axes
* Quickmeasure: Remove minimum distance between circle center and cylinder surface
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
---------
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* Gui: Widen the default customize dialog
* Gui: Make panels the same width in keyboard and toolbars tabs
* Remove namespace additions
---------
Co-authored-by: Ryan Kembrey <ryan.kembrey@student.uts>
* Sketcher: Use different colors for touch/window selection
As the title says. I think it was missing, so currently right to left
motion makes the box selection in Sketcher green with dashed lines,
whereas motion from left to right makes it blue with solid lines.
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
---------
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Not all unicode characters are allowed as XML output. When writing disallowed characters the SAX parser throws an exception
when loading a project file that results into a broken document and thus to a possible loss of data.
This PR replaces all disallowed characters with an underscore and prints a warning.
This fixes https://github.com/FreeCAD/FreeCAD/issues/22123
Note: It does not fix an already corrupted project file.
Since OCC 7.7 using GeomLib_IsPlanarSurface without a custom tolerance may fail because the default value is too strict.
To fix this problem forward the passed tolerance value to GeomLib_IsPlanarSurface.
This fixes issue 20633