- QColor o(c0, c1, c2);
-
- vtkFloatingPointType faces_orientation_scale = anActor->GetFacesOrientationScale();
- bool faces_orientation_3dvectors = anActor->GetFacesOrientation3DVectors();
-
- SMESHGUI_Preferences_ColorDlg *aDlg =
- new SMESHGUI_Preferences_ColorDlg( SMESHGUI::GetSMESHGUI() );
- aDlg->SetColor(1, c);
- aDlg->SetColor(2, e);
- aDlg->SetColor(3, n);
- aDlg->SetColor(4, b);
- aDlg->SetColor(5, c0D);
- aDlg->SetColor(6, o);
- aDlg->SetIntValue(1, Edgewidth);
- aDlg->SetIntValue(2, int(Shrink*100.));
- aDlg->SetIntValue(3, size0D);
- aDlg->SetDoubleValue(1, faces_orientation_scale);
- aDlg->SetBooleanValue(1, faces_orientation_3dvectors);
-
- aDlg->setCustomMarkerMap( theMarkerMap[ aStudy->StudyId() ] );
-
- VTK::MarkerType aMarkerTypeCurrent = anActor->GetMarkerType();
- VTK::MarkerScale aMarkerScaleCurrent = anActor->GetMarkerScale();
- int aMarkerTextureCurrent = anActor->GetMarkerTexture();
- if( aMarkerTypeCurrent != VTK::MT_USER )
- aDlg->setStandardMarker( aMarkerTypeCurrent, aMarkerScaleCurrent );
- else
- aDlg->setCustomMarker( aMarkerTextureCurrent );
-
- if(aDlg->exec()){
- QColor color = aDlg->GetColor(1);
- QColor edgecolor = aDlg->GetColor(2);
- QColor nodecolor = aDlg->GetColor(3);
- QColor backfacecolor = aDlg->GetColor(4);
- QColor color0D = aDlg->GetColor(5);
- QColor faces_orientation_color = aDlg->GetColor(6);
+ o.setRgb(c0, c1, c2);
+
+ faces_orientation_scale = anActor->GetFacesOrientationScale();
+ faces_orientation_3dvectors = anActor->GetFacesOrientation3DVectors();
+
+ aMarkerTypeCurrent = anActor->GetMarkerType();
+ aMarkerScaleCurrent = anActor->GetMarkerScale();
+ aMarkerTextureCurrent = anActor->GetMarkerTexture();
+
+ // even if there are multiple objects in the selection,
+ // we need only the first one to get values for the dialog
+ break;
+ }
+ }
+ }
+
+ SMESHGUI_Preferences_ColorDlg *aDlg =
+ new SMESHGUI_Preferences_ColorDlg( SMESHGUI::GetSMESHGUI() );
+ aDlg->SetColor(1, c);
+ aDlg->SetColor(2, e);
+ aDlg->SetColor(3, n);
+ aDlg->SetColor(4, b);
+ aDlg->SetColor(5, c0D);
+ aDlg->SetColor(6, o);
+ aDlg->SetIntValue(1, Edgewidth);
+ aDlg->SetIntValue(2, int(Shrink*100.));
+ aDlg->SetIntValue(3, size0D);
+ aDlg->SetDoubleValue(1, faces_orientation_scale);
+ aDlg->SetBooleanValue(1, faces_orientation_3dvectors);
+
+ aDlg->setCustomMarkerMap( theMarkerMap[ aStudy->StudyId() ] );
+
+ if( aMarkerTypeCurrent != VTK::MT_USER )
+ aDlg->setStandardMarker( aMarkerTypeCurrent, aMarkerScaleCurrent );
+ else
+ aDlg->setCustomMarker( aMarkerTextureCurrent );
+
+ if(aDlg->exec()){
+ QColor color = aDlg->GetColor(1);
+ QColor edgecolor = aDlg->GetColor(2);
+ QColor nodecolor = aDlg->GetColor(3);
+ QColor backfacecolor = aDlg->GetColor(4);
+ QColor color0D = aDlg->GetColor(5);
+ QColor faces_orientation_color = aDlg->GetColor(6);
+
+ /* Point marker */
+ theMarkerMap[ aStudy->StudyId() ] = aDlg->getCustomMarkerMap();
+
+ SALOME_ListIteratorOfListIO It( selected );
+ for( ; It.More(); It.Next()){
+ Handle(SALOME_InteractiveObject) IObject = It.Value();
+ if(IObject->hasEntry()){
+ if(SMESH_Actor *anActor = SMESH::FindActorByEntry(IObject->getEntry())){