From dc15e8f077ace99a044129efd8f699f948ccc30e Mon Sep 17 00:00:00 2001 From: JimStar Date: Sun, 8 Jul 2018 15:04:00 +1200 Subject: [PATCH] Extended global marker size to be used for Path --- src/Mod/Path/Gui/ViewProviderPath.cpp | 6 +----- src/Mod/Path/Gui/ViewProviderPath.h | 1 - 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/src/Mod/Path/Gui/ViewProviderPath.cpp b/src/Mod/Path/Gui/ViewProviderPath.cpp index 79492d89d8..305605be6e 100644 --- a/src/Mod/Path/Gui/ViewProviderPath.cpp +++ b/src/Mod/Path/Gui/ViewProviderPath.cpp @@ -91,8 +91,6 @@ ViewProviderPath::ViewProviderPath() ADD_PROPERTY_TYPE(NormalColor,(lr,lg,lb),"Path",App::Prop_None,"The color of the feed rate moves"); ADD_PROPERTY_TYPE(MarkerColor,(mr,mg,mb),"Path",App::Prop_None,"The color of the markers"); ADD_PROPERTY_TYPE(LineWidth,(lwidth),"Path",App::Prop_None,"The line width of this path"); - int markerSize = hGrp->GetInt("DefaultPathMarkerSize",4); - ADD_PROPERTY_TYPE(MarkerSize,(markerSize),"Path",App::Prop_None,"The point size of the markers"); ADD_PROPERTY_TYPE(ShowNodes,(false),"Path",App::Prop_None,"Turns the display of nodes on/off"); @@ -121,7 +119,7 @@ ViewProviderPath::ViewProviderPath() pcMarkerStyle = new SoDrawStyle(); pcMarkerStyle->ref(); pcMarkerStyle->style = SoDrawStyle::POINTS; - pcMarkerStyle->pointSize = MarkerSize.getValue(); + pcMarkerStyle->pointSize = App::GetApplication().GetParameterGroupByPath("User parameter:BaseApp/Preferences/View")->GetInt("MarkerSize", 4); pcDrawStyle = new SoDrawStyle(); pcDrawStyle->ref(); @@ -305,8 +303,6 @@ void ViewProviderPath::onChanged(const App::Property* prop) if (prop == &LineWidth) { pcDrawStyle->lineWidth = LineWidth.getValue(); - } else if (prop == &MarkerSize) { - pcMarkerStyle->pointSize = MarkerSize.getValue(); } else if (prop == &NormalColor) { if (colorindex.size() > 0 && coordStart>=0 && coordStart<(int)colorindex.size()) { const App::Color& c = NormalColor.getValue(); diff --git a/src/Mod/Path/Gui/ViewProviderPath.h b/src/Mod/Path/Gui/ViewProviderPath.h index 291b2ccd8b..18666c91da 100644 --- a/src/Mod/Path/Gui/ViewProviderPath.h +++ b/src/Mod/Path/Gui/ViewProviderPath.h @@ -59,7 +59,6 @@ public: App::PropertyInteger LineWidth; App::PropertyColor NormalColor; App::PropertyColor MarkerColor; - App::PropertyInteger MarkerSize; App::PropertyBool ShowNodes; App::PropertyVector StartPosition;