From 4d98127e08ba65528b767e92a0c8780aa8b5c811 Mon Sep 17 00:00:00 2001 From: amx Date: Mon, 29 Jan 2007 15:52:55 +0000 Subject: [PATCH] PAL13456 : change default values for Vertex Maker style and size. --- src/GEOMGUI/GEOM_Displayer.cxx | 10 ++++----- src/GEOMGUI/GeometryGUI.cxx | 38 +++++++++++++++++++++------------- 2 files changed, 29 insertions(+), 19 deletions(-) diff --git a/src/GEOMGUI/GEOM_Displayer.cxx b/src/GEOMGUI/GEOM_Displayer.cxx index 48827ca65..1511436a7 100644 --- a/src/GEOMGUI/GEOM_Displayer.cxx +++ b/src/GEOMGUI/GEOM_Displayer.cxx @@ -237,12 +237,12 @@ GEOM_Displayer::GEOM_Displayer( SalomeApp_Study* st ) myShadingColor = SalomeApp_Tools::color( col ); myDisplayMode = resMgr->integerValue("Geometry", "display_mode", 0); - myTypeOfMarker = (Aspect_TypeOfMarker)resMgr->integerValue("Geometry", "type_of_marker", 0); + myTypeOfMarker = (Aspect_TypeOfMarker)resMgr->integerValue("Geometry", "type_of_marker", Aspect_TOM_PLUS); myScaleOfMarker = resMgr->doubleValue("Geometry", "marker_scale", 1.); - if(myScaleOfMarker < 1.) - myScaleOfMarker = 1.; - if(myScaleOfMarker > 8.) - myScaleOfMarker = 8.; + if(myScaleOfMarker < 1.0) + myScaleOfMarker = 1.0; + if(myScaleOfMarker > 7.) + myScaleOfMarker = 7.; myColor = -1; diff --git a/src/GEOMGUI/GeometryGUI.cxx b/src/GEOMGUI/GeometryGUI.cxx index bd3d9759d..1362269dc 100644 --- a/src/GEOMGUI/GeometryGUI.cxx +++ b/src/GEOMGUI/GeometryGUI.cxx @@ -1680,7 +1680,7 @@ void GeometryGUI::createPreferences() LightApp_Preferences::Selector, "Geometry", "type_of_marker" ); int markerScale = addPreference( tr( "PREF_MARKER_SCALE" ), VertexGroup, - LightApp_Preferences::IntSpin, "Geometry", "marker_scale" ); + LightApp_Preferences::DblSpin, "Geometry", "marker_scale" ); // Set property for default display mode QStringList aModesList; @@ -1701,34 +1701,44 @@ void GeometryGUI::createPreferences() // Set property for type of vertex marker QStringList aTypeOfMarkerList; - aTypeOfMarkerList.append( tr("TOM_POINT") ); + QValueList anTypeOfMarkerIndexesList; + aTypeOfMarkerList.append( tr("TOM_PLUS") ); - aTypeOfMarkerList.append( tr("TOM_STAR") ); - aTypeOfMarkerList.append( tr("TOM_O") ); - aTypeOfMarkerList.append( tr("TOM_X") ); - aTypeOfMarkerList.append( tr("TOM_O_POINT") ); - aTypeOfMarkerList.append( tr("TOM_O_PLUS") ); - aTypeOfMarkerList.append( tr("TOM_O_STAR") ); - aTypeOfMarkerList.append( tr("TOM_O_X") ); + anTypeOfMarkerIndexesList.append(Aspect_TOM_PLUS); - QValueList anTypeOfMarkerIndexesList; + aTypeOfMarkerList.append( tr("TOM_POINT") ); anTypeOfMarkerIndexesList.append(Aspect_TOM_POINT); - anTypeOfMarkerIndexesList.append(Aspect_TOM_PLUS); + + aTypeOfMarkerList.append( tr("TOM_STAR") ); anTypeOfMarkerIndexesList.append(Aspect_TOM_STAR); + + aTypeOfMarkerList.append( tr("TOM_O") ); anTypeOfMarkerIndexesList.append(Aspect_TOM_O); + + aTypeOfMarkerList.append( tr("TOM_X") ); anTypeOfMarkerIndexesList.append(Aspect_TOM_X); + + aTypeOfMarkerList.append( tr("TOM_O_POINT") ); anTypeOfMarkerIndexesList.append(Aspect_TOM_O_POINT); + + aTypeOfMarkerList.append( tr("TOM_O_PLUS") ); anTypeOfMarkerIndexesList.append(Aspect_TOM_O_PLUS); + + aTypeOfMarkerList.append( tr("TOM_O_STAR") ); anTypeOfMarkerIndexesList.append(Aspect_TOM_O_STAR); + + aTypeOfMarkerList.append( tr("TOM_O_X") ); anTypeOfMarkerIndexesList.append(Aspect_TOM_O_X); + setPreferenceProperty( typeOfMarker, "strings", aTypeOfMarkerList ); setPreferenceProperty( typeOfMarker, "indexes", anTypeOfMarkerIndexesList ); // Set property for Vertex Marker scale - setPreferenceProperty( markerScale, "min", 0.25 ); - setPreferenceProperty( markerScale, "max", 10. ); - setPreferenceProperty( markerScale, "precision", 1 ); + setPreferenceProperty( markerScale, "min", 1. ); + setPreferenceProperty( markerScale, "max", 7. ); + setPreferenceProperty( markerScale, "precision", 0.01 ); + setPreferenceProperty( markerScale, "step", 0.5 ); } -- 2.39.2