Skip to content

Commit

Permalink
[PD] Hole initialization bugfix
Browse files Browse the repository at this point in the history
- by default there is no hole head cut and therefore its parameter must be initialized as read-only (will be enably when user sets a head cut)

- also fix a typo

- also fix a UI file issue (automatically done by Qt Designer)
  • Loading branch information
donovaly committed Jun 25, 2022
1 parent 175d2cf commit 1b2f006
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion src/Mod/PartDesign/App/FeatureHole.cpp
Expand Up @@ -665,13 +665,17 @@ Hole::Hole()
HoleCutType.setEnums(HoleCutType_None_Enums);

ADD_PROPERTY_TYPE(HoleCutCustomValues, (false), "Hole", App::Prop_None, "Custom cut values");
HoleCutCustomValues.setReadOnly(true);

ADD_PROPERTY_TYPE(HoleCutDiameter, (0.0), "Hole", App::Prop_None, "Head cut diameter");
HoleCutDiameter.setReadOnly(true);

ADD_PROPERTY_TYPE(HoleCutDepth, (0.0), "Hole", App::Prop_None, "Head cut deth");
ADD_PROPERTY_TYPE(HoleCutDepth, (0.0), "Hole", App::Prop_None, "Head cut depth");
HoleCutDepth.setReadOnly(true);

ADD_PROPERTY_TYPE(HoleCutCountersinkAngle, (90.0), "Hole", App::Prop_None, "Head cut countersink angle");
HoleCutCountersinkAngle.setConstraints(&floatAngle);
HoleCutCountersinkAngle.setReadOnly(true);

ADD_PROPERTY_TYPE(DepthType, (0L), "Hole", App::Prop_None, "Type");
DepthType.setEnums(DepthTypeEnums);
Expand Down
2 changes: 1 addition & 1 deletion src/Mod/PartDesign/Gui/TaskHoleParameters.ui
Expand Up @@ -6,7 +6,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>355</width>
<width>438</width>
<height>561</height>
</rect>
</property>
Expand Down

0 comments on commit 1b2f006

Please sign in to comment.