Several group commands are active but require an active document to work. This PR overrides the method isActive() to
disable the commands if no active document exists.
The affected commands are:
* Std_ViewGroup
* Std_LinkActions
* PartDesign_CompDatums
* PartDesign_CompSketches
Uses new material system for appearance
Each feature object now has a property called ShapeMaterial that
describes its physical properties. If it has a shape, it has a
material.
The ShapeColor attribute is replaced by a ShapeAppearance attribute.
This is a material list that describes all appearance properties, not
just diffuse color. As a list in can be used for all elements of a
shape, such as edges and faces.
A new widget is provided to allow the user to select materials in a
consistent fashion. It can also launch the material editor with its
more advanced capabilities.
The problem is caused by conflicting values of the anonymous enum of ViewProviderSubShapeBinder. The solution is to set a higher value than the highest value of EditMode
The use of static_cast here could cause undefined behaviour because at this point it's not guaranteed that findBodyOf()
really returns a PartDesign::Body
* Allow adding subfeatures to MultiTransform if there is no active Body
Previously the active Body would be checked and used to add new
subfeatures.
This would either do nothing, when no Body was active,
causing confusion for users becaues than can edit other features without
an active Body.
Or it would add the subfeature to the wrong Body if another Body than the
one of the MultiTransform was active.
Now the Body of the MultiTransform is checked and used.
# Conflicts:
# src/Mod/PartDesign/Gui/TaskMultiTransformParameters.cpp
* Change getTopTransformedObject() to protected
This needs to be called from the MultiTransform.
* Fix typo
The reason of the crash is a static_cast of an unknown type that causes undefined behaviour. The feature AdditiveLoft has the
property Section of type PropertyLinkSubList but the function does a static_cast to PropertyLinkList.
The solution is to use a dynamic_cast that returns null if the cast fails.
Reference selection in the GUI was accidentially changed to only
allow specific types of objects, preventing e.g. selection of a DatumPlane
for mirroring.
This restores the previous functionality.
* Updated ts files
* Merged crowdin translations
* [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>
* PD: Make datum points highlightable/selectable
Give the user some feedback by changing the color of the datum point
marker as the user selects or hovers over it.
Closes#9540
* Update translations
* [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>
Before calling the closeSubTask() function from the dialog reject()
function, the slotDeletedObject() is called from the transaction being
aborted. This causes the subFeature pointer to be nullptr and subsequent
apply() functions from the SpinBox widgets to crash.
Before calling apply check if the subFeature is still there.
Remove and re-insert the selected objects at the specified point in the
tree while preserving their relative order.
The code used to insert them in reverse order.
Closes#12287
The python console commands where not consistenly reported because
the apply function was not called or not implemented.
The function is now called from the base class and also when
a subfeature is closed in MultiTransform.
Some missing properties are also added.