From: dmv Date: Tue, 3 Nov 2009 15:27:43 +0000 (+0000) Subject: 0020012: EDF 831 GEOM : API for points representation in 3D viewer X-Git-Tag: V5_1_3rc2~17 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=d2f606321a6f64e755b72cffdbd8c4bf2904a565;p=modules%2Fgeom.git 0020012: EDF 831 GEOM : API for points representation in 3D viewer --- diff --git a/resources/Makefile.am b/resources/Makefile.am index 7e74345c4..7f6261d32 100644 --- a/resources/Makefile.am +++ b/resources/Makefile.am @@ -186,6 +186,15 @@ suppressintwires.png \ marker.png \ marker2.png \ marker3.png \ +marker_1.png \ +marker_2.png \ +marker_3.png \ +marker_4.png \ +marker_5.png \ +marker_6.png \ +marker_7.png \ +marker_8.png \ +marker_9.png \ position.png \ position2.png \ position3.png \ diff --git a/resources/marker_1.png b/resources/marker_1.png new file mode 100755 index 000000000..f0d21091d Binary files /dev/null and b/resources/marker_1.png differ diff --git a/resources/marker_2.png b/resources/marker_2.png new file mode 100755 index 000000000..8bbaa854e Binary files /dev/null and b/resources/marker_2.png differ diff --git a/resources/marker_3.png b/resources/marker_3.png new file mode 100755 index 000000000..e37d613e1 Binary files /dev/null and b/resources/marker_3.png differ diff --git a/resources/marker_4.png b/resources/marker_4.png new file mode 100755 index 000000000..78c805532 Binary files /dev/null and b/resources/marker_4.png differ diff --git a/resources/marker_5.png b/resources/marker_5.png new file mode 100755 index 000000000..a994c1100 Binary files /dev/null and b/resources/marker_5.png differ diff --git a/resources/marker_6.png b/resources/marker_6.png new file mode 100755 index 000000000..967b93ecc Binary files /dev/null and b/resources/marker_6.png differ diff --git a/resources/marker_7.png b/resources/marker_7.png new file mode 100755 index 000000000..7a3eb90f6 Binary files /dev/null and b/resources/marker_7.png differ diff --git a/resources/marker_8.png b/resources/marker_8.png new file mode 100755 index 000000000..3b3ccc481 Binary files /dev/null and b/resources/marker_8.png differ diff --git a/resources/marker_9.png b/resources/marker_9.png new file mode 100755 index 000000000..0d7603681 Binary files /dev/null and b/resources/marker_9.png differ diff --git a/src/GEOMGUI/GEOM_images.ts b/src/GEOMGUI/GEOM_images.ts index 2e25def67..748ecd84f 100644 --- a/src/GEOMGUI/GEOM_images.ts +++ b/src/GEOMGUI/GEOM_images.ts @@ -629,6 +629,42 @@ ICON_SELECT select1.png + + ICON_VERTEX_MARKER_1 + marker_1.png + + + ICON_VERTEX_MARKER_2 + marker_2.png + + + ICON_VERTEX_MARKER_3 + marker_3.png + + + ICON_VERTEX_MARKER_4 + marker_4.png + + + ICON_VERTEX_MARKER_5 + marker_5.png + + + ICON_VERTEX_MARKER_6 + marker_6.png + + + ICON_VERTEX_MARKER_7 + marker_7.png + + + ICON_VERTEX_MARKER_8 + marker_8.png + + + ICON_VERTEX_MARKER_9 + marker_9.png + ICO_ARC arc.png diff --git a/src/GEOMGUI/GeometryGUI.cxx b/src/GEOMGUI/GeometryGUI.cxx index cfb50c82b..5e88b7c2c 100644 --- a/src/GEOMGUI/GeometryGUI.cxx +++ b/src/GEOMGUI/GeometryGUI.cxx @@ -1589,39 +1589,30 @@ void GeometryGUI::createPreferences() setPreferenceProperty( step, "precision", 3 ); // Set property for type of vertex marker - QStringList aTypeOfMarkerList; QList anTypeOfMarkerIndexesList; + QList anTypeOfMarkerIconsList; - aTypeOfMarkerList.append( tr("TOM_PLUS") ); anTypeOfMarkerIndexesList.append(Aspect_TOM_PLUS); - - aTypeOfMarkerList.append( tr("TOM_POINT") ); anTypeOfMarkerIndexesList.append(Aspect_TOM_POINT); - - 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); + // Create icons list + SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr(); + for (int i = 1; i<=9; i++) { + QString str = "ICON_VERTEX_MARKER_"; + str.append( QString::number(i) ); + QPixmap pixmap (resMgr->loadPixmap("GEOM", tr( str.toLatin1().data() ))); + anTypeOfMarkerIconsList.append(pixmap); + } - setPreferenceProperty( typeOfMarker, "strings", aTypeOfMarkerList ); setPreferenceProperty( typeOfMarker, "indexes", anTypeOfMarkerIndexesList ); + setPreferenceProperty( typeOfMarker, "icons", anTypeOfMarkerIconsList ); // Set property for Vertex Marker scale setPreferenceProperty( markerScale, "min", 1. );