[TD]synchronize defaults in code and prefs

This commit is contained in:
wandererfan
2020-03-13 14:52:27 -04:00
committed by WandererFan
parent 2dfc4099b6
commit ee626abef4
14 changed files with 222 additions and 240 deletions

View File

@@ -656,7 +656,7 @@ bool DrawUtil::isCrazy(TopoDS_Edge e)
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter().GetGroup("BaseApp")->
GetGroup("Preferences")->GetGroup("Mod/TechDraw/debug");
bool crazyOK = hGrp->GetBool("allowCrazyEdge", true);
bool crazyOK = hGrp->GetBool("allowCrazyEdge", false);
if (crazyOK) {
return false;
}

View File

@@ -273,7 +273,7 @@ int DrawViewBalloon::prefEnd(void) const
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter().
GetGroup("BaseApp")->GetGroup("Preferences")->
GetGroup("Mod/TechDraw/Decorations");
int end = hGrp->GetInt("BalloonArrow", 0);
int end = hGrp->GetInt("BalloonArrow", 1);
return end;
}

View File

@@ -1159,7 +1159,7 @@ bool DrawViewDimension::showUnits() const
bool result = false;
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter()
.GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/TechDraw/Dimensions");
result = hGrp->GetBool("ShowUnits", true);
result = hGrp->GetBool("ShowUnits", false);
return result;
}

View File

@@ -1462,7 +1462,7 @@ bool DrawViewPart::prefIsoViz(void)
{
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter()
.GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/TechDraw/HLR");
bool result = hGrp->GetBool("IsoViz", true);
bool result = hGrp->GetBool("IsoViz", false);
return result;
}
@@ -1470,7 +1470,7 @@ bool DrawViewPart::prefHardHid(void)
{
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter()
.GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/TechDraw/HLR");
bool result = hGrp->GetBool("HardHid", true);
bool result = hGrp->GetBool("HardHid", false);
return result;
}
@@ -1478,7 +1478,7 @@ bool DrawViewPart::prefSeamHid(void)
{
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter()
.GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/TechDraw/HLR");
bool result = hGrp->GetBool("SeamHid", true);
bool result = hGrp->GetBool("SeamHid", false);
return result;
}
@@ -1486,7 +1486,7 @@ bool DrawViewPart::prefSmoothHid(void)
{
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter()
.GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/TechDraw/HLR");
bool result = hGrp->GetBool("SmoothHid", true);
bool result = hGrp->GetBool("SmoothHid", false);
return result;
}
@@ -1494,7 +1494,7 @@ bool DrawViewPart::prefIsoHid(void)
{
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter()
.GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/TechDraw/HLR");
bool result = hGrp->GetBool("IsoHid", true);
bool result = hGrp->GetBool("IsoHid", false);
return result;
}

View File

@@ -904,7 +904,7 @@ void DrawViewSection::getParameters()
hGrp = App::GetApplication().GetUserParameter()
.GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/TechDraw/General");
bool fuseFirst = hGrp->GetBool("SectionFuseFirst",true);
bool fuseFirst = hGrp->GetBool("SectionFuseFirst", false);
FuseBeforeCut.setValue(fuseFirst);
}

View File

@@ -216,7 +216,7 @@ for ProjectionGroups</string>
<property name="toolTip">
<string>Normal line color</string>
</property>
<property name="color" stdset="0">
<property name="color">
<color>
<red>0</red>
<green>0</green>
@@ -286,7 +286,7 @@ for ProjectionGroups</string>
<property name="toolTip">
<string>Preselection color</string>
</property>
<property name="color" stdset="0">
<property name="color">
<color>
<red>255</red>
<green>255</green>
@@ -318,7 +318,7 @@ for ProjectionGroups</string>
<property name="toolTip">
<string>Section face color</string>
</property>
<property name="color" stdset="0">
<property name="color">
<color>
<red>225</red>
<green>225</green>
@@ -350,7 +350,7 @@ for ProjectionGroups</string>
<property name="toolTip">
<string>Selected item color</string>
</property>
<property name="color" stdset="0">
<property name="color">
<color>
<red>28</red>
<green>173</green>
@@ -382,7 +382,7 @@ for ProjectionGroups</string>
<property name="toolTip">
<string>Section face hatch color</string>
</property>
<property name="color" stdset="0">
<property name="color">
<color>
<red>0</red>
<green>0</green>
@@ -414,7 +414,7 @@ for ProjectionGroups</string>
<property name="toolTip">
<string>Window background color</string>
</property>
<property name="color" stdset="0">
<property name="color">
<color>
<red>80</red>
<green>80</green>
@@ -446,7 +446,7 @@ for ProjectionGroups</string>
<property name="toolTip">
<string>Geometric hatch color</string>
</property>
<property name="color" stdset="0">
<property name="color">
<color>
<red>0</red>
<green>0</green>
@@ -473,7 +473,7 @@ for ProjectionGroups</string>
<property name="toolTip">
<string>Color of Dimension lines and text.</string>
</property>
<property name="color" stdset="0">
<property name="color">
<color>
<red>0</red>
<green>0</green>
@@ -565,7 +565,7 @@ for ProjectionGroups</string>
<property name="toolTip">
<string>Face color</string>
</property>
<property name="color" stdset="0">
<property name="color">
<color>
<red>255</red>
<green>255</green>
@@ -597,7 +597,7 @@ for ProjectionGroups</string>
<property name="toolTip">
<string>Default color for annotations </string>
</property>
<property name="color" stdset="0">
<property name="color">
<color>
<red>0</red>
<green>0</green>
@@ -733,7 +733,7 @@ for ProjectionGroups</string>
</spacer>
</item>
<item row="1" column="2">
<widget class="Gui::PrefUnitSpinBox" name="plsb_LabelSize" native="true">
<widget class="Gui::PrefUnitSpinBox" name="plsb_LabelSize">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
@@ -743,7 +743,7 @@ for ProjectionGroups</string>
<property name="toolTip">
<string>Label size</string>
</property>
<property name="value" stdset="0">
<property name="value">
<double>8.000000000000000</double>
</property>
<property name="prefEntry" stdset="0">
@@ -793,7 +793,7 @@ for ProjectionGroups</string>
</widget>
</item>
<item row="0" column="2">
<widget class="Gui::PrefFileChooser" name="pfc_DefTemp" native="true">
<widget class="Gui::PrefFileChooser" name="pfc_DefTemp">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
@@ -844,7 +844,7 @@ for ProjectionGroups</string>
</spacer>
</item>
<item row="1" column="2">
<widget class="Gui::PrefFileChooser" name="pfc_DefDir" native="true">
<widget class="Gui::PrefFileChooser" name="pfc_DefDir">
<property name="minimumSize">
<size>
<width>0</width>
@@ -884,7 +884,7 @@ for ProjectionGroups</string>
</widget>
</item>
<item row="2" column="2">
<widget class="Gui::PrefFileChooser" name="pfc_HatchFile" native="true">
<widget class="Gui::PrefFileChooser" name="pfc_HatchFile">
<property name="minimumSize">
<size>
<width>0</width>
@@ -921,7 +921,7 @@ for ProjectionGroups</string>
</widget>
</item>
<item row="3" column="2">
<widget class="Gui::PrefFileChooser" name="pfc_LineGroup" native="true">
<widget class="Gui::PrefFileChooser" name="pfc_LineGroup">
<property name="minimumSize">
<size>
<width>0</width>
@@ -958,7 +958,7 @@ for ProjectionGroups</string>
</widget>
</item>
<item row="4" column="2">
<widget class="Gui::PrefFileChooser" name="pfc_Welding" native="true">
<widget class="Gui::PrefFileChooser" name="pfc_Welding">
<property name="minimumSize">
<size>
<width>0</width>
@@ -998,7 +998,7 @@ for ProjectionGroups</string>
</widget>
</item>
<item row="5" column="2">
<widget class="Gui::PrefFileChooser" name="pfc_FilePattern" native="true">
<widget class="Gui::PrefFileChooser" name="pfc_FilePattern">
<property name="minimumSize">
<size>
<width>0</width>

View File

@@ -251,7 +251,57 @@
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<layout class="QGridLayout" name="gridLayout_2">
<layout class="QGridLayout" name="gridLayout_2" columnstretch="1,0,1">
<property name="horizontalSpacing">
<number>24</number>
</property>
<item row="2" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>OverLap Radius (TBI)</string>
</property>
</widget>
</item>
<item row="2" column="2">
<widget class="Gui::PrefDoubleSpinBox" name="pdsbOverlapRadius">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="baseSize">
<size>
<width>0</width>
<height>33</height>
</size>
</property>
<property name="toolTip">
<string>Area to be inspected for overlap object selection. (not implemented yet)</string>
</property>
<property name="statusTip">
<string/>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="value">
<double>20.000000000000000</double>
</property>
<property name="prefEntry" stdset="0">
<cstring>OverlapRadius</cstring>
</property>
<property name="prefPath" stdset="0">
<cstring>Mod/TechDraw/General</cstring>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="label_3">
<property name="minimumSize">
@@ -271,18 +321,12 @@
</property>
</widget>
</item>
<item row="0" column="1">
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
<item row="1" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Mark Fuzz</string>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</widget>
</item>
<item row="0" column="2">
<widget class="Gui::PrefDoubleSpinBox" name="pdsbEdgeFuzz">
@@ -294,7 +338,7 @@
</property>
<property name="minimumSize">
<size>
<width>174</width>
<width>0</width>
<height>0</height>
</size>
</property>
@@ -324,13 +368,6 @@
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Mark Fuzz</string>
</property>
</widget>
</item>
<item row="1" column="2">
<widget class="Gui::PrefDoubleSpinBox" name="pdsbMarkFuzz">
<property name="sizePolicy">
@@ -341,7 +378,7 @@
</property>
<property name="minimumSize">
<size>
<width>174</width>
<width>0</width>
<height>0</height>
</size>
</property>
@@ -371,81 +408,24 @@
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Overlap Radius</string>
<item row="0" column="1">
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item row="2" column="2">
<widget class="Gui::PrefDoubleSpinBox" name="pdsbOverlapRadius">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<property name="sizeHint" stdset="0">
<size>
<width>174</width>
<height>0</height>
<width>40</width>
<height>20</height>
</size>
</property>
<property name="baseSize">
<size>
<width>0</width>
<height>33</height>
</size>
</property>
<property name="toolTip">
<string>Area to be inspected for overlap object selection.
(not implemented yet)</string>
</property>
<property name="statusTip">
<string/>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="value">
<double>20.000000000000000</double>
</property>
<property name="prefEntry" stdset="0">
<cstring>OverlapRadius</cstring>
</property>
<property name="prefPath" stdset="0">
<cstring>Mod/TechDraw/General</cstring>
</property>
</widget>
</spacer>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_12">
<property name="font">
<font>
<pointsize>12</pointsize>
<italic>true</italic>
</font>
</property>
<property name="frameShape">
<enum>QFrame::Box</enum>
</property>
<property name="text">
<string>Items in italics are default values for new objects. They have no effect on existing objects.</string>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QGroupBox" name="gb_SizeAdj">
<property name="sizePolicy">
@@ -463,75 +443,9 @@
<property name="title">
<string>Size Adjustments</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<layout class="QVBoxLayout" name="verticalLayout_4">
<item>
<layout class="QGridLayout" name="gridLayout_3">
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Vertex Scale</string>
</property>
</widget>
</item>
<item row="0" column="2">
<widget class="Gui::PrefDoubleSpinBox" name="pdsbVertexScale">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>174</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Scale of vertex dots. Multiplier of line width.</string>
</property>
<property name="accessibleName">
<string/>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="value">
<double>5.000000000000000</double>
</property>
<property name="prefEntry" stdset="0">
<cstring>VertexScale</cstring>
</property>
<property name="prefPath" stdset="0">
<cstring>Mod/TechDraw/General</cstring>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_2">
<property name="font">
<font>
<italic>true</italic>
</font>
</property>
<property name="text">
<string>Center Mark Scale</string>
</property>
</widget>
</item>
<item row="1" column="1">
<spacer name="horizontalSpacer_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<layout class="QGridLayout" name="gridLayout_3" columnstretch="1,0,1">
<item row="1" column="2">
<widget class="Gui::PrefDoubleSpinBox" name="pdsbCenterScale">
<property name="sizePolicy">
@@ -540,14 +454,8 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>174</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Size of center marks. Multiplier of vertex size.</string>
<string>Size of center marks. Multiplier of vertex size.</string>
</property>
<property name="accessibleName">
<string/>
@@ -566,6 +474,65 @@
</property>
</widget>
</item>
<item row="2" column="2">
<widget class="Gui::PrefDoubleSpinBox" name="pdsbToleranceScale">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="baseSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Tolerance font size adjustment. Multiplier of dimension font size.</string>
</property>
<property name="accessibleName">
<string/>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="value">
<double>0.500000000000000</double>
</property>
<property name="prefEntry" stdset="0">
<cstring>TolSizeAdjust</cstring>
</property>
<property name="prefPath" stdset="0">
<cstring>Mod/TechDraw/Dimensions</cstring>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Vertex Scale</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_2">
<property name="font">
<font>
<italic>true</italic>
</font>
</property>
<property name="text">
<string>Center Mark Scale</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="lbl_LabelFont">
<property name="minimumSize">
@@ -590,28 +557,23 @@
</property>
</widget>
</item>
<item row="2" column="2">
<widget class="Gui::PrefDoubleSpinBox" name="pdsbToleranceScale">
<item row="3" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Template Edit Mark</string>
</property>
</widget>
</item>
<item row="0" column="2">
<widget class="Gui::PrefDoubleSpinBox" name="pdsbVertexScale">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>174</width>
<height>0</height>
</size>
</property>
<property name="baseSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Tolerance font size adjustment. Multiplier of dimension font size.</string>
<string>Scale of vertex dots. Multiplier of line width.</string>
</property>
<property name="accessibleName">
<string/>
@@ -620,20 +582,13 @@
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="value">
<double>0.500000000000000</double>
<double>5.000000000000000</double>
</property>
<property name="prefEntry" stdset="0">
<cstring>TolSizeAdjust</cstring>
<cstring>VertexScale</cstring>
</property>
<property name="prefPath" stdset="0">
<cstring>Mod/TechDraw/Dimensions</cstring>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Template Edit Mark</string>
<cstring>Mod/TechDraw/General</cstring>
</property>
</widget>
</item>
@@ -665,11 +620,43 @@
</property>
</widget>
</item>
<item row="1" column="1">
<spacer name="horizontalSpacer_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_12">
<property name="font">
<font>
<pointsize>12</pointsize>
<italic>true</italic>
</font>
</property>
<property name="frameShape">
<enum>QFrame::Box</enum>
</property>
<property name="text">
<string>Items in italics are default values for new objects. They have no effect on existing objects.</string>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
<item row="4" column="0">
<spacer name="verticalSpacer">
<property name="orientation">

View File

@@ -218,7 +218,7 @@
</widget>
</item>
<item row="5" column="2">
<widget class="Gui::PrefUnitSpinBox" name="plsb_FontSize" native="true">
<widget class="Gui::PrefUnitSpinBox" name="plsb_FontSize">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
@@ -228,7 +228,7 @@
<property name="toolTip">
<string>Dimension text font size</string>
</property>
<property name="value" stdset="0">
<property name="value">
<double>4.000000000000000</double>
</property>
<property name="prefEntry" stdset="0">
@@ -240,7 +240,7 @@
</widget>
</item>
<item row="8" column="2">
<widget class="Gui::PrefUnitSpinBox" name="plsb_ArrowSize" native="true">
<widget class="Gui::PrefUnitSpinBox" name="plsb_ArrowSize">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
@@ -250,7 +250,7 @@
<property name="toolTip">
<string>Arrowhead size</string>
</property>
<property name="value" stdset="0">
<property name="value">
<double>5.000000000000000</double>
</property>
<property name="prefEntry" stdset="0">

View File

@@ -313,7 +313,7 @@ int QGIArrow::getPrefArrowStyle()
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter().
GetGroup("BaseApp")->GetGroup("Preferences")->
GetGroup("Mod/TechDraw/Dimensions");
int style = hGrp->GetInt("ArrowStyle", 0);
int style = hGrp->GetInt("ArrowStyle", 1);
return style;
}

View File

@@ -106,7 +106,7 @@ QPainterPath QGICMark::shape() const
{
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter().GetGroup("BaseApp")->
GetGroup("Preferences")->GetGroup("Mod/TechDraw/General");
double result = hGrp->GetFloat("MarkFuzz",20.0);
double result = hGrp->GetFloat("MarkFuzz",5.0);
return result;
}

View File

@@ -138,7 +138,7 @@ int QGIHighlight::getHoleStyle()
{
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter()
.GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/TechDraw/Decorations");
int style = hGrp->GetInt("MattingStyle", 1l);
int style = hGrp->GetInt("MattingStyle", 0);
return style;
}

View File

@@ -262,25 +262,20 @@ Qt::PenCapStyle QGIPrimPath::prefCapStyle()
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter()
.GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/TechDraw/General");
Qt::PenCapStyle result;
//old parameter format UINT
unsigned int oldStyle = hGrp->GetUnsigned("EdgeCapStyle", 0xFF); //0x00 FlatCap, 0x10 SquareCap, 0x20 RoundCap
result = (Qt::PenCapStyle) oldStyle;
int newStyle;
if (oldStyle == 0xFF) { //no old style parm found
newStyle = hGrp->GetInt("EdgeCapStyle", 32); //0x00 FlatCap, 0x10 SquareCap, 0x20 RoundCap
switch (newStyle) {
case 0:
result = (Qt::PenCapStyle) 0x20; //round;
break;
case 1:
result = (Qt::PenCapStyle) 0x10; //square;
break;
case 2:
result = (Qt::PenCapStyle) 0x00; //flat
break;
default:
result = (Qt::PenCapStyle) 0x20;
}
newStyle = hGrp->GetInt("EdgeCapStyle", 32); //0x00 FlatCap, 0x10 SquareCap, 0x20 RoundCap
switch (newStyle) {
case 0:
result = (Qt::PenCapStyle) 0x20; //round;
break;
case 1:
result = (Qt::PenCapStyle) 0x10; //square;
break;
case 2:
result = (Qt::PenCapStyle) 0x00; //flat
break;
default:
result = (Qt::PenCapStyle) 0x20;
}
return result;
}

View File

@@ -1288,6 +1288,6 @@ bool QGIViewPart::prefPrintCenters(void)
{
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter().GetGroup("BaseApp")->
GetGroup("Preferences")->GetGroup("Mod/TechDraw/Decorations");
bool printCenters = hGrp->GetBool("PrintCenterMarks", true); //true matches v0.18 behaviour
bool printCenters = hGrp->GetBool("PrintCenterMarks", false); //true matches v0.18 behaviour
return printCenters;
}

View File

@@ -89,7 +89,7 @@ ViewProviderViewPart::ViewProviderViewPart()
hGrp = App::GetApplication().GetUserParameter().GetGroup("BaseApp")->
GetGroup("Preferences")->GetGroup("Mod/TechDraw/Decorations");
double defScale = hGrp->GetFloat("CenterMarkScale",2.0);
double defScale = hGrp->GetFloat("CenterMarkScale",0.50);
bool defShowCenters = hGrp->GetBool("ShowCenterMarks", false);
//decorations