Salome HOME
Prefernces.
authorstv <stv@opencascade.com>
Mon, 27 Jun 2005 11:29:58 +0000 (11:29 +0000)
committerstv <stv@opencascade.com>
Mon, 27 Jun 2005 11:29:58 +0000 (11:29 +0000)
13 files changed:
src/OBJECT/SMESH_Actor.cxx
src/OBJECT/SMESH_ActorUtils.cxx
src/OBJECT/SMESH_ActorUtils.h
src/SMESHGUI/SMESHGUI.cxx
src/SMESHGUI/SMESHGUI.h
src/SMESHGUI/SMESHGUI_AddMeshElementDlg.cxx
src/SMESHGUI/SMESHGUI_ClippingDlg.cxx
src/SMESHGUI/SMESHGUI_CreatePolyhedralVolumeDlg.cxx
src/SMESHGUI/SMESHGUI_FilterDlg.cxx
src/SMESHGUI/SMESHGUI_MeshPatternDlg.cxx
src/SMESHGUI/SMESHGUI_NodesDlg.cxx
src/SMESHGUI/SMESHGUI_VTKUtils.cxx
src/SMESHGUI/SMESH_msg_en.po

index 7bea5e30b0f153a15719ac0ba42dfc96f0a1977e..667a80b6ef86c709448e1f785d67f6434c8f510b 100644 (file)
@@ -114,10 +114,10 @@ SMESH_ActorDef::SMESH_ActorDef()
   myIsShrinkable = false;
   myIsShrunk = false;
 
-  myControlsPrecision = (long)SMESH::GetFloat( "SMESH:ControlsPrecision", -1 );
+  myControlsPrecision = (long)SMESH::GetFloat( "SMESH:controls_precision", -1 );
 
-  float aPointSize = SMESH::GetFloat("SMESH:SettingsNodesSize",3);
-  float aLineWidth = SMESH::GetFloat("SMESH:SettingsWidth",1);
+  float aPointSize = SMESH::GetFloat("SMESH:node_size",3);
+  float aLineWidth = SMESH::GetFloat("SMESH:element_width",1);
 
   vtkMatrix4x4 *aMatrix = vtkMatrix4x4::New();
   VTKViewer_ExtractUnstructuredGrid* aFilter = NULL;
@@ -126,16 +126,12 @@ SMESH_ActorDef::SMESH_ActorDef()
   //-----------------------------------------
   float anRGB[3] = {1,1,1};
   mySurfaceProp = vtkProperty::New();
-  anRGB[0] = SMESH::GetFloat("SMESH:SettingsFillColorRed", 0)/255.;
-  anRGB[1] = SMESH::GetFloat("SMESH:SettingsFillColorGreen", 170)/255.;
-  anRGB[2] = SMESH::GetFloat("SMESH:SettingsFillColorBlue", 255)/255.;
-  mySurfaceProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
+  SMESH::GetColor( "SMESH", "fill_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 170, 255 ) );
+  mySurfaceProp->SetColor( anRGB[0], anRGB[1], anRGB[2] );
 
   myBackSurfaceProp = vtkProperty::New();
-  anRGB[0] = SMESH::GetFloat("SMESH:SettingsBackFaceColorRed", 0)/255.;
-  anRGB[1] = SMESH::GetFloat("SMESH:SettingsBackFaceColorGreen", 0)/255.;
-  anRGB[2] = SMESH::GetFloat("SMESH:SettingsBackFaceColorBlue", 255)/255.;
-  myBackSurfaceProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
+  SMESH::GetColor( "SMESH", "backface_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 0, 255 ) );
+  myBackSurfaceProp->SetColor( anRGB[0], anRGB[1], anRGB[2] );
 
   my2DActor = SMESH_DeviceActor::New();
   my2DActor->SetUserMatrix(aMatrix);
@@ -170,9 +166,7 @@ SMESH_ActorDef::SMESH_ActorDef()
   myEdgeProp->SetAmbient(1.0);
   myEdgeProp->SetDiffuse(0.0);
   myEdgeProp->SetSpecular(0.0);
-  anRGB[0] = SMESH::GetFloat("SMESH:SettingsOutlineColorRed", 0)/255.;
-  anRGB[1] = SMESH::GetFloat("SMESH:SettingsOutlineColorGreen", 170)/255.;
-  anRGB[2] = SMESH::GetFloat("SMESH:SettingsOutlineColorBlue", 255)/255.;
+  SMESH::GetColor( "SMESH", "outline_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 170, 255 ) );
   myEdgeProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
   myEdgeProp->SetLineWidth(aLineWidth);
 
@@ -215,9 +209,7 @@ SMESH_ActorDef::SMESH_ActorDef()
   //Definition 0D divice of the actor
   //---------------------------------
   myNodeProp = vtkProperty::New();
-  anRGB[0] = SMESH::GetFloat("SMESH:SettingsNodeColorRed",255)/255.;
-  anRGB[1] = SMESH::GetFloat("SMESH:SettingsNodeColorGreen",0)/255.;
-  anRGB[2] = SMESH::GetFloat("SMESH:SettingsNodeColorBlue",0)/255.;
+  SMESH::GetColor( "SMESH", "node_color", anRGB[0], anRGB[1], anRGB[2], QColor( 255, 0, 0 ) );
   myNodeProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
   myNodeProp->SetPointSize(aPointSize);
 
@@ -246,9 +238,7 @@ SMESH_ActorDef::SMESH_ActorDef()
   myHighlightProp->SetAmbient(1.0);
   myHighlightProp->SetDiffuse(0.0);
   myHighlightProp->SetSpecular(0.0);
-  anRGB[0] = SMESH::GetFloat("SMESH:SettingsSelectColorRed", 255)/255.;   // 1;
-  anRGB[1] = SMESH::GetFloat("SMESH:SettingsSelectColorGreen", 255)/255.; // 1;
-  anRGB[2] = SMESH::GetFloat("SMESH:SettingsSelectColorBlue", 255)/255.;  // 1;
+  SMESH::GetColor( "SMESH", "selection_object_color", anRGB[0], anRGB[1], anRGB[2], QColor( 255, 255, 255 ) );
   myHighlightProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
   myHighlightProp->SetPointSize(aPointSize);
   myHighlightProp->SetRepresentation(1);
@@ -257,9 +247,7 @@ SMESH_ActorDef::SMESH_ActorDef()
   myPreselectProp->SetAmbient(1.0);
   myPreselectProp->SetDiffuse(0.0);
   myPreselectProp->SetSpecular(0.0);
-  anRGB[0] = SMESH::GetFloat("SMESH:SettingsPreSelectColorRed", 0)/255.;     // 0;
-  anRGB[1] = SMESH::GetFloat("SMESH:SettingsPreSelectColorGreen", 255)/255.; // 1;
-  anRGB[2] = SMESH::GetFloat("SMESH:SettingsPreSelectColorBlue", 255)/255.;  // 1;
+  SMESH::GetColor( "SMESH", "highlight_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 255, 255 ) );
   myPreselectProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
   myPreselectProp->SetPointSize(aPointSize);
   myPreselectProp->SetRepresentation(1);
@@ -269,7 +257,7 @@ SMESH_ActorDef::SMESH_ActorDef()
   myHighlitableActor->PickableOff();
   myHighlitableActor->SetRepresentation(SMESH_DeviceActor::eWireframe);
 
-  SetShrinkFactor(SMESH::GetFloat("SMESH:SettingsShrinkCoeff", 75)/100.);
+  SetShrinkFactor( SMESH::GetFloat( "SMESH", "shrink_coeff", 0.75 ) );
 
   myName = "";
   myIO = NULL;
@@ -294,13 +282,14 @@ SMESH_ActorDef::SMESH_ActorDef()
   if( !mgr )
     return;
 
-  QColor aTColor = mgr->colorValue( "ScalarBarTitleColor", "SMESH", QColor( 255, 255, 255 ) );
+  QColor aTColor = mgr->colorValue( "SMESH", "ScalarBarTitleColor", QColor( 255, 255, 255 ) );
   aScalarBarTitleProp->SetColor( aTColor.red()/255., aTColor.green()/255., aTColor.blue()/255. );
 
   aScalarBarTitleProp->SetFontFamilyToArial();
   
-  if( mgr->hasValue( "ScalarBarTitleFont", "SMESH" ) ){
-    QString str = mgr->stringValue( "ScalarBarTitleFont", "SMESH" );
+  if ( mgr->hasValue( "SMESH", "ScalarBarTitleFont" ) )
+  {
+    QString str = mgr->stringValue( "SMESH", "ScalarBarTitleFont" );
     if ( str == "Arial" )
       aScalarBarTitleProp->SetFontFamilyToArial();
     else if ( str == "Courier" )
@@ -309,17 +298,17 @@ SMESH_ActorDef::SMESH_ActorDef()
       aScalarBarTitleProp->SetFontFamilyToTimes();
   }
 
-  if ( mgr->stringValue( "ScalarBarTitleBold", "SMESH" ) == "true" )
+  if ( mgr->booleanValue( "SMESH", "ScalarBarTitleBold" ) )
     aScalarBarTitleProp->BoldOn();
   else
     aScalarBarTitleProp->BoldOff();
 
-  if ( mgr->stringValue( "ScalarBarTitleItalic", "SMESH" ) == "true" )
+  if ( mgr->booleanValue( "SMESH", "ScalarBarTitleItalic" ) )
     aScalarBarTitleProp->ItalicOn();
   else
     aScalarBarTitleProp->ItalicOff();
 
-  if ( mgr->stringValue( "ScalarBarTitleShadow", "SMESH" ) == "true" )
+  if ( mgr->booleanValue( "SMESH", "ScalarBarTitleShadow" ) )
     aScalarBarTitleProp->ShadowOn();
   else
     aScalarBarTitleProp->ShadowOff();
@@ -329,13 +318,13 @@ SMESH_ActorDef::SMESH_ActorDef()
 
   vtkTextProperty* aScalarBarLabelProp = vtkTextProperty::New();
 
-  aTColor = mgr->colorValue( "ScalarBarLabelColor", "SMESH", QColor( 255, 255, 255 ) );
+  aTColor = mgr->colorValue( "SMESH", "ScalarBarLabelColor", QColor( 255, 255, 255 ) );
   aScalarBarLabelProp->SetColor( aTColor.red()/255., aTColor.green()/255., aTColor.blue()/255. );
 
   aScalarBarLabelProp->SetFontFamilyToArial();
-  if( mgr->hasValue( "ScalarBarLabelFont", "SMESH" ) )
+  if( mgr->hasValue( "SMESH", "ScalarBarLabelFont" ) )
   {
-    QString str = mgr->stringValue( "ScalarBarLabelFont", "SMESH" );
+    QString str = mgr->stringValue( "SMESH", "ScalarBarLabelFont" );
     if( str == "Arial" )
       aScalarBarLabelProp->SetFontFamilyToArial();
     else if( str == "Courier" )
@@ -344,17 +333,17 @@ SMESH_ActorDef::SMESH_ActorDef()
       aScalarBarLabelProp->SetFontFamilyToTimes();
   }
 
-  if( mgr->stringValue( "ScalarBarLabelBold", "SMESH" ) == "true" )
+  if ( mgr->booleanValue( "SMESH", "ScalarBarLabelBold" ) )
     aScalarBarLabelProp->BoldOn();
   else
     aScalarBarLabelProp->BoldOff();
 
-  if ( mgr->stringValue( "ScalarBarLabelItalic", "SMESH" ) == "true" )
+  if ( mgr->booleanValue( "SMESH", "ScalarBarLabelItalic" ) )
     aScalarBarLabelProp->ItalicOn();
   else
     aScalarBarLabelProp->ItalicOff();
 
-  if( mgr->stringValue( "ScalarBarLabelShadow", "SMESH" ) == "true" )
+  if( mgr->booleanValue( "SMESH", "ScalarBarLabelShadow" ) )
     aScalarBarLabelProp->ShadowOn();
   else
     aScalarBarLabelProp->ShadowOff();
@@ -362,37 +351,37 @@ SMESH_ActorDef::SMESH_ActorDef()
   myScalarBarActor->SetLabelTextProperty( aScalarBarLabelProp );
   aScalarBarLabelProp->Delete();
 
-  if( mgr->stringValue( "ScalarBarOrientation", "SMESH" ) == "Horizontal" )
+  if( mgr->stringValue( "SMESH", "ScalarBarOrientation" ) == "Horizontal" )
     myScalarBarActor->SetOrientationToHorizontal();
   else
     myScalarBarActor->SetOrientationToVertical();
 
-  float aXVal = mgr->stringValue( "ScalarBarOrientation", "SMESH" ) == "Horizontal" ? 0.20 : 0.01;
-  if( mgr->hasValue( "ScalarBarXPosition", "SMESH" ) )
-    aXVal = mgr->doubleValue( "ScalarBarXPosition", "SMESH", aXVal );
-  float aYVal = mgr->stringValue( "ScalarBarOrientation", "SMESH" ) == "Horizontal" ? 0.01 : 0.1;
-  if( mgr->hasValue( "ScalarBarYPosition", "SMESH" ) )
-    aYVal = mgr->doubleValue( "ScalarBarYPosition", "SMESH", aYVal );
+  float aXVal = mgr->stringValue( "SMESH", "ScalarBarOrientation" ) == "Horizontal" ? 0.20 : 0.01;
+  if( mgr->hasValue( "SMESH", "ScalarBarXPosition" ) )
+    aXVal = mgr->doubleValue( "SMESH", "ScalarBarXPosition", aXVal );
+  float aYVal = mgr->stringValue( "SMESH", "ScalarBarOrientation" ) == "Horizontal" ? 0.01 : 0.1;
+  if( mgr->hasValue( "SMESH", "ScalarBarYPosition" ) )
+    aYVal = mgr->doubleValue( "SMESH", "ScalarBarYPosition", aYVal );
   myScalarBarActor->SetPosition( aXVal, aYVal );
 
-  float aWVal = mgr->stringValue( "ScalarBarOrientation", "SMESH" ) == "Horizontal" ? 0.60 : 0.10;
-  if( mgr->hasValue( "ScalarBarWidth", "SMESH" ) )
-    aWVal = mgr->doubleValue( "ScalarBarWidth", "SMESH", aWVal );
+  float aWVal = mgr->stringValue( "SMESH", "ScalarBarOrientation" ) == "Horizontal" ? 0.60 : 0.10;
+  if( mgr->hasValue( "SMESH", "ScalarBarWidth" ) )
+    aWVal = mgr->doubleValue( "SMESH", "ScalarBarWidth", aWVal );
   myScalarBarActor->SetWidth( aWVal );
 
-  float aHVal = mgr->stringValue( "ScalarBarOrientation", "SMESH" ) == "Horizontal" ? 0.12 : 0.80;
-  if( mgr->hasValue( "ScalarBarHeight", "SMESH" ) )
-    aHVal = mgr->doubleValue( "ScalarBarHeight", "SMESH", aHVal );
+  float aHVal = mgr->stringValue( "SMESH", "ScalarBarOrientation" ) == "Horizontal" ? 0.12 : 0.80;
+  if( mgr->hasValue( "SMESH", "ScalarBarHeight" ) )
+    aHVal = mgr->doubleValue( "SMESH", "ScalarBarHeight", aHVal );
   myScalarBarActor->SetHeight( aHVal );
 
   int anIntVal = 5;
-  if( mgr->hasValue( "ScalarBarNbOfLabels", "SMESH" ) )
-    anIntVal = mgr->integerValue( "ScalarBarNbOfLabels", "SMESH", anIntVal );
+  if( mgr->hasValue( "SMESH", "ScalarBarNbOfLabels" ) )
+    anIntVal = mgr->integerValue( "SMESH", "ScalarBarNbOfLabels", anIntVal );
   myScalarBarActor->SetNumberOfLabels( anIntVal == 0 ? 5: anIntVal );
 
   anIntVal = 64;
-  if( mgr->hasValue( "ScalarBarNbOfColors", "SMESH" ) )
-    anIntVal = mgr->integerValue( "ScalarBarNbOfColors", "SMESH", anIntVal );
+  if( mgr->hasValue( "SMESH", "ScalarBarNbOfColors" ) )
+    anIntVal = mgr->integerValue( "SMESH", "ScalarBarNbOfColors", anIntVal );
   myScalarBarActor->SetMaximumNumberOfColors( anIntVal == 0 ? 64 : anIntVal );
 
 
@@ -625,7 +614,7 @@ SetControlMode(eControl theMode,
     return;
 
   myControlMode = eNone;
-  theCheckEntityMode &= mgr->stringValue( "DispayEntity", "SMESH" ) == "true";
+  theCheckEntityMode &= mgr->booleanValue( "SMESH", "display_entity", false );
 
   my1DActor->GetMapper()->SetScalarVisibility(false);
   my2DActor->GetMapper()->SetScalarVisibility(false);
index 05aa47c5938ead514f8aa70b367ee3a8d72c099b..feee143db948dd0510aa8ec57b3d4ee291f974a1 100644 (file)
@@ -20,8 +20,9 @@
 
 #include "SMESH_ActorUtils.h"
 
-#include "SUIT_ResourceMgr.h"
+#include "SUIT_Tools.h"
 #include "SUIT_Session.h"
+#include "SUIT_ResourceMgr.h"
 
 #include "utilities.h"
 
@@ -42,10 +43,10 @@ namespace SMESH{
     float val = theDefault;
     if( pos>=0 ) 
     {
-      QString val = theValue.right( theValue.length()-pos-1 ),
+      QString name = theValue.right( theValue.length()-pos-1 ),
               sect = theValue.left( pos );
-      if( !val.isEmpty() && !sect.isEmpty() )
-       val = GetFloat( val, sect, theDefault );
+      if( !name.isEmpty() && !sect.isEmpty() )
+       val = GetFloat( name, sect, theDefault );
     }
     return val;
   }
@@ -70,4 +71,31 @@ namespace SMESH{
     aWriter->Delete();
   }
 
+  QColor GetColor( const QString& theSect, const QString& theName, const QColor& def )
+  {
+    QColor c = def;
+    SUIT_ResourceMgr* mgr = SUIT_Session::session()->resourceMgr();
+    if ( mgr )
+      c = mgr->colorValue( theSect, theName, def );
+    return c;
+  }
+
+  void GetColor( const QString& theSect, const QString& theName, int& r, int& g, int& b, const QColor& def )
+  {
+    QColor c = def;
+    SUIT_ResourceMgr* mgr = SUIT_Session::session()->resourceMgr();
+    if ( mgr )
+      c = mgr->colorValue( theSect, theName, def );
+
+    SUIT_Tools::rgbSet( SUIT_Tools::rgbSet( c ), r, g, b );
+  }
+
+  void GetColor( const QString& theSect, const QString& theName, float& r, float& g, float& b, const QColor& def )
+  {
+    int ir( 0 ), ig( 0 ), ib( 0 );
+    GetColor( theSect, theName, ir, ig, ib, def );
+    r = ir / 255.;
+    g = ig / 255.;
+    b = ib / 255.;
+  }
 }
index b4f8194c54cc9c6eda8fc29eedd9f98906515886..f28e8d6c9ae5568fae70b246c3b4df9b1ec89c57 100644 (file)
@@ -20,6 +20,7 @@
 #ifndef SMESH_ACTORUTILS_H
 #define SMESH_ACTORUTILS_H
 
+#include <qcolor.h>
 #include <qstring.h>
 
 class vtkUnstructuredGrid;
@@ -29,6 +30,10 @@ namespace SMESH{
   float GetFloat( const QString& theValue, float theDefault = 0 );
   float GetFloat( const QString& theName, const QString& theSection, float theDefault = 0 );
 
+  QColor GetColor( const QString& theSect, const QString& theName, const QColor&t = QColor() );
+  void   GetColor( const QString& theSect, const QString& theName, int&, int&, int&, const QColor&t = QColor() );
+  void   GetColor( const QString& theSect, const QString& theName, float&, float&, float&, const QColor&t = QColor() );
+
   void WriteUnstructuredGrid(vtkUnstructuredGrid* theGrid, const char* theFileName);
 
 }
index 511b6f1cfa8d85f8a45119b712c84f60fcce903f..29840349b28f6654539ff2c6590e6c2e39fef221 100644 (file)
 
 #include "QtxPopupMgr.h"
 
-#include "SalomeApp_Application.h"
-#include "SalomeApp_NameDlg.h"
-#include "SalomeApp_DataOwner.h"
-#include "SalomeApp_ImportOperation.h"
 #include "SalomeApp_Tools.h"
 #include "SalomeApp_Study.h"
+#include "SalomeApp_NameDlg.h"
+#include "SalomeApp_DataOwner.h"
+#include "SalomeApp_Application.h"
+#include "SalomeApp_Preferences.h"
 #include "SalomeApp_VTKSelector.h"
 
+#include "SalomeApp_ImportOperation.h"
+
 #include <SVTK_ViewWindow.h>
 #include <SVTK_ViewModel.h>
 
@@ -845,7 +847,6 @@ SalomeApp_Module( "SMESH" )
     myComponentSMESH = SMESH::SMESH_Gen::_narrow( comp );
   }
 
-  myAutomaticUpdate = false;
   myActiveDialogBox = 0 ;
   myState = -1 ;
 
@@ -880,6 +881,15 @@ SalomeApp_SelectionMgr* SMESHGUI::selectionMgr()
     return 0;
 }
 
+bool SMESHGUI::automaticUpdate()
+{
+  SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr();
+  if ( !resMgr )
+    return false;
+
+  return resMgr->booleanValue( "SMESH", "auto_update", false );
+}
+
 //=============================================================================
 /*!
  *
@@ -1326,8 +1336,7 @@ bool SMESHGUI::OnGUIEvent( int theCommandID )
        }
        CORBA::Long anId = aStudy->StudyId();
        TVisualObjPtr aVisualObj = SMESH::GetVisualObj(anId,IObject->getEntry());
-       cout<<"myAutomaticUpdate - "<<myAutomaticUpdate<<endl;
-       if(myAutomaticUpdate && aVisualObj){
+       if ( automaticUpdate() && aVisualObj){
          aVisualObj->Update();
          SMESH_Actor* anActor = SMESH::FindActorByEntry(IObject->getEntry());
          if(!anActor){
@@ -1765,14 +1774,14 @@ bool SMESHGUI::OnGUIEvent( int theCommandID )
     
   case 1001:                                   // AUTOMATIC UPDATE PREFERENCES
     {
-      if (act->isOn()) {
-       mgr->setValue( "SMESH", "AutomaticUpdate", true );
-       myAutomaticUpdate = true;
-      }
-      else {
-       mgr->setValue( "SMESH", "AutomaticUpdate", false );
-       myAutomaticUpdate = false;
-      }
+//       if (act->isOn()) {
+//     mgr->setValue( "SMESH", "AutomaticUpdate", true );
+//     myAutomaticUpdate = true;
+//       }
+//       else {
+//     mgr->setValue( "SMESH", "AutomaticUpdate", false );
+//     myAutomaticUpdate = false;
+//       }
       break;
     }
 
@@ -2377,14 +2386,14 @@ bool SMESHGUI::SetSettings(SUIT_Desktop* parent)
   action( 10003 )->setOn( Shrink );
 
   // Automatic Update
-  if ( mgr->booleanValue( "SMESH","AutomaticUpdate", false ) ) {
-    action( 1001 )->setOn( true );
-    myAutomaticUpdate = true;
-  }
-  else {
-    action( 1001 )->setOn( false );
-    myAutomaticUpdate = false;
-  }
+//   if ( mgr->booleanValue( "SMESH","AutomaticUpdate", false ) ) {
+//     action( 1001 )->setOn( true );
+//     myAutomaticUpdate = true;
+//   }
+//   else {
+//     action( 1001 )->setOn( false );
+//     myAutomaticUpdate = false;
+//   }
 
   if ( mgr->booleanValue( "SMESH","DispayEntity", false ) )
     action( 10071 )->setOn( true );
@@ -2481,10 +2490,10 @@ void SMESHGUI::initialize( CAM_Application* app )
 {
   SalomeApp_Module::initialize( app );
 
-  SUIT_ResourceMgr* mgr = app->resourceMgr();
-  if ( mgr )
+//   SUIT_ResourceMgr* mgr = app->resourceMgr();
+//   if ( mgr )
   /* Automatic Update flag */
-    myAutomaticUpdate = mgr->booleanValue( "SMESH", "AutomaticUpdate", myAutomaticUpdate );
+//     myAutomaticUpdate = mgr->booleanValue( "SMESH", "AutomaticUpdate", myAutomaticUpdate );
 
   // ----- create actions --------------
 
@@ -3128,6 +3137,77 @@ void SMESHGUI::viewManagers( QStringList& list ) const
 
 void SMESHGUI::onViewManagerAdded( SUIT_ViewManager* mgr )
 {
-  if( dynamic_cast<VTKViewer_ViewManager*>( mgr ) )
+  if ( dynamic_cast<VTKViewer_ViewManager*>( mgr ) )
     SMESH::UpdateSelectionProp( this );
 }
+
+void SMESHGUI::createPreferences()
+{
+  int genTab = addPreference( tr( "PREF_TAB_GENERAL" ) );
+
+  int qaGroup = addPreference( tr( "PREF_GROUP_QUALITY" ), genTab );
+  addPreference( tr( "PREF_DISPLAY_ENTITY" ), qaGroup, SalomeApp_Preferences::Bool, "Mesh", "display_entity" );
+  addPreference( tr( "PREF_AUTO_UPDATE" ), qaGroup, SalomeApp_Preferences::Bool, "Mesh", "auto_update" );
+
+  int precGroup = addPreference( tr( "PREF_GROUP_PRECISION" ), genTab );
+  setPreferenceProperty( precGroup, "columns", 1 );
+
+  addPreference( tr( "PREF_PRECISION_USE" ), precGroup, SalomeApp_Preferences::Bool );
+  int prec = addPreference( tr( "PREF_PRECISION_VALUE" ), precGroup, SalomeApp_Preferences::IntSpin, "SMESH", "controls_precision" );
+
+  setPreferenceProperty( prec, "min", 0 );
+  setPreferenceProperty( prec, "max", 16 );
+
+  int meshTab = addPreference( tr( "PREF_TAB_MESH" ) );
+  int nodeGroup = addPreference( tr( "PREF_GROUP_NODES" ), meshTab );
+
+  addPreference( tr( "PREF_COLOR" ), nodeGroup, SalomeApp_Preferences::Color, "SMESH", "node_color" );
+  int nodeSz = addPreference( tr( "PREF_SIZE" ), nodeGroup, SalomeApp_Preferences::IntSpin, "SMESH", "node_size" );
+
+  setPreferenceProperty( nodeSz, "min", 1 );
+  setPreferenceProperty( nodeSz, "max", 5 );
+
+  int elemGroup = addPreference( tr( "PREF_GROUP_ELEMENTS" ), meshTab );
+
+  addPreference( tr( "PREF_FILL" ), elemGroup, SalomeApp_Preferences::Color, "SMESH", "fill_color" );
+  addPreference( tr( "PREF_OUTLINE" ), elemGroup, SalomeApp_Preferences::Color, "SMESH", "outline_color" );
+  addPreference( tr( "PREF_BACKFACE" ), elemGroup, SalomeApp_Preferences::Color, "SMESH", "backface_color" );
+  addPreference( "", elemGroup, SalomeApp_Preferences::Space );
+
+  int elemW = addPreference( tr( "PREF_WIDTH" ), elemGroup, SalomeApp_Preferences::IntSpin, "SMESH", "element_width" );
+  int shrink = addPreference( tr( "PREF_SHRINK_COEFF" ), elemGroup, SalomeApp_Preferences::IntSpin, "SMESH", "shrink_coeff" );
+
+  setPreferenceProperty( elemW, "min", 1 );
+  setPreferenceProperty( elemW, "max", 5 );
+
+  setPreferenceProperty( shrink, "min", 0 );
+  setPreferenceProperty( shrink, "max", 100 );
+
+  int selTab = addPreference( tr( "PREF_TAB_SELECTION" ) );
+
+  int selGroup = addPreference( tr( "PREF_GROUP_SELECTION" ), selTab );
+
+  addPreference( tr( "PREF_OBJECT_COLOR" ), selGroup, SalomeApp_Preferences::Color, "SMESH", "selection_object_color" );
+  addPreference( tr( "PREF_ELEMENT_COLOR" ), selGroup, SalomeApp_Preferences::Color, "SMESH", "selection_element_color" );
+  int selW = addPreference( tr( "PREF_WIDTH" ), selGroup, SalomeApp_Preferences::IntSpin, "SMESH", "selection_width" );
+  
+  setPreferenceProperty( selW, "min", 1 );
+  setPreferenceProperty( selW, "max", 5 );
+  
+  int preGroup = addPreference( tr( "PREF_GROUP_PRESELECTION" ), selTab );
+
+  addPreference( tr( "PREF_HIGHLIGHT_COLOR" ), preGroup, SalomeApp_Preferences::Color, "SMESH", "highlight_color" );
+  int preW = addPreference( tr( "PREF_WIDTH" ), preGroup, SalomeApp_Preferences::IntSpin, "SMESH", "highlight_width" );
+
+  setPreferenceProperty( preW, "min", 1 );
+  setPreferenceProperty( preW, "max", 5 );
+
+  int precSelGroup = addPreference( tr( "PREF_GROUP_PRECISION" ), selTab );
+
+  addPreference( tr( "PREF_NODES" ), precSelGroup, SalomeApp_Preferences::Double, "SMESH", "selection_precision_node" );
+  addPreference( tr( "PREF_ELEMENTS" ), precSelGroup, SalomeApp_Preferences::Double, "SMESH", "selection_precision_element" );
+}
+
+void SMESHGUI::preferencesChanged( const QString&, const QString& )
+{
+}
index ec883cab7c9a797193597ced12848056244a14ee..396de4b862f08383db787e41a2b9581c5692dce4 100644 (file)
@@ -68,6 +68,8 @@ public :
   static SalomeApp_Study*         activeStudy();
   bool                            isActiveStudyLocked();
 
+  static bool                     automaticUpdate();
+
   virtual QString     engineIOR() const;
   virtual void        initialize( CAM_Application* );
   virtual void        windows( QMap<int, int>& ) const;
@@ -96,6 +98,9 @@ public :
   void EmitSignalStudyFrameChanged() ;
   void EmitSignalCloseAllDialogs() ;
 
+  virtual void                createPreferences();
+  virtual void                preferencesChanged( const QString&, const QString& );
+
 public slots:
   virtual bool                deactivateModule( SUIT_Study* );
   virtual bool                activateModule( SUIT_Study* );
@@ -119,9 +124,7 @@ private :
   static SMESH::SMESH_Gen_var      myComponentSMESH;
   QDialog*                         myActiveDialogBox;
   int                              myState;
-  bool                             myAutomaticUpdate;
   QMap<int,QString>                myRules;
 };
 
-
 #endif
index 263758674743da0150dcd5bab341b388efbd2d5e..c9a559b388060bec0d348a076d4e08c33522bf2c 100644 (file)
@@ -118,21 +118,17 @@ namespace SMESH {
       myPreviewActor->VisibilityOff();
       myPreviewActor->SetMapper(myMapper);
 
-      vtkProperty* aProp = vtkProperty::New();
       float anRGB[3];
-      anRGB[0] = GetFloat("SMESH:SettingsFillColorRed", 0)/255.;
-      anRGB[1] = GetFloat("SMESH:SettingsFillColorGreen", 170)/255.;
-      anRGB[2] = GetFloat("SMESH:SettingsFillColorBlue", 255)/255.;
-      aProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
-      myPreviewActor->SetProperty(aProp);
+      vtkProperty* aProp = vtkProperty::New();
+      GetColor( "SMESH", "fill_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 170, 255 ) );
+      aProp->SetColor( anRGB[0], anRGB[1], anRGB[2] );
+      myPreviewActor->SetProperty( aProp );
       aProp->Delete();
 
       vtkProperty* aBackProp = vtkProperty::New();
-      anRGB[0] = GetFloat("SMESH:SettingsBackFaceColorRed", 0)/255.;
-      anRGB[1] = GetFloat("SMESH:SettingsBackFaceColorGreen", 0)/255.;
-      anRGB[2] = GetFloat("SMESH:SettingsBackFaceColorBlue", 255)/255.;
-      aBackProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
-      myPreviewActor->SetBackfaceProperty(aBackProp);
+      GetColor( "SMESH", "backface_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 0, 255 ) );
+      aBackProp->SetColor( anRGB[0], anRGB[1], anRGB[2] );
+      myPreviewActor->SetBackfaceProperty( aBackProp );
       aBackProp->Delete();
 
       myVTKViewWindow->AddActor(myPreviewActor);
index f415162d5e45fed3f6856b009319b87f91bee996..bdc7b83af001521d526ef4c1e4f11a6ff4655f98 100644 (file)
@@ -157,20 +157,16 @@ protected:
     myActor->SetInfinitive(true);
     myActor->SetMapper(myMapper);
 
-    vtkProperty* aProp = vtkProperty::New();
     float anRGB[3];
-    anRGB[0] = SMESH::GetFloat("SMESH:SettingsFillColorRed", 0)/255.;
-    anRGB[1] = SMESH::GetFloat("SMESH:SettingsFillColorGreen", 170)/255.;
-    anRGB[2] = SMESH::GetFloat("SMESH:SettingsFillColorBlue", 255)/255.;
+    vtkProperty* aProp = vtkProperty::New();
+    SMESH::GetColor( "SMESH", "fill_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 170, 255 ) );
     aProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
     aProp->SetOpacity(0.75);
     myActor->SetProperty(aProp);
     aProp->Delete();
 
     vtkProperty* aBackProp = vtkProperty::New();
-    anRGB[0] = SMESH::GetFloat("SMESH:SettingsBackFaceColorRed", 0)/255.;
-    anRGB[1] = SMESH::GetFloat("SMESH:SettingsBackFaceColorGreen", 0)/255.;
-    anRGB[2] = SMESH::GetFloat("SMESH:SettingsBackFaceColorBlue", 255)/255.;
+    SMESH::GetColor( "SMESH", "backface_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 0, 255 ) );
     aBackProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
     aBackProp->SetOpacity(0.75);
     myActor->SetBackfaceProperty(aBackProp);
index abf447e17425fd4ca058b342b976906374553db9..b84c11b10206eb936656de6a627faec3d799eb01 100644 (file)
@@ -112,19 +112,15 @@ class TPolySimulation{
       myPreviewActor->VisibilityOff();
       myPreviewActor->SetMapper( myMapper );
 
-      vtkProperty* aProp = vtkProperty::New();
       float anRGB[3];
-      anRGB[0] = GetFloat("SMESH:SettingsFillColorRed", 0)/255.;
-      anRGB[1] = GetFloat("SMESH:SettingsFillColorGreen", 170)/255.;
-      anRGB[2] = GetFloat("SMESH:SettingsFillColorBlue", 255)/255.;
+      vtkProperty* aProp = vtkProperty::New();
+      GetColor( "SMESH", "fill_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 170, 255 ) );
       aProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
       myPreviewActor->SetProperty( aProp );
       aProp->Delete();
 
       vtkProperty* aBackProp = vtkProperty::New();
-      anRGB[0] = GetFloat("SMESH:SettingsBackFaceColorRed", 0)/255.;
-      anRGB[1] = GetFloat("SMESH:SettingsBackFaceColorGreen", 0)/255.;
-      anRGB[2] = GetFloat("SMESH:SettingsBackFaceColorBlue", 255)/255.;
+      GetColor( "SMESH", "backface_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 0, 255 ) );
       aBackProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
       myPreviewActor->SetBackfaceProperty( aBackProp );
       aBackProp->Delete();
index b2e9627b8bc4e51151235c62f71d24cb9f8f2179..f1b72a35e62a8c7a8b312c57f9c7e19a162acf20 100755 (executable)
@@ -2192,13 +2192,8 @@ bool SMESHGUI_FilterDlg::createFilter (const int theType)
   long aPrecision = -1;
   SUIT_ResourceMgr* mgr = SMESH::GetResourceMgr( mySMESHGUI );
 
-  if (mgr && mgr->hasValue("SMESH", "ControlsPrecision")) {
-    QString aStr = mgr->stringValue("SMESH", "ControlsPrecision");
-    bool isOk = false;
-    int aVal = aStr.toInt(&isOk);
-    if (isOk)
-      aPrecision = aVal;
-  }
+  if ( mgr && mgr->booleanValue( "SMESH", "use_precision", false ) )
+    aPrecision = mgr->integerValue( "SMESH", "controls_precision", aPrecision );
 
   for (CORBA::ULong i = 0; i < n; i++) {
     SMESH::Filter::Criterion aCriterion = createCriterion();
index e896c4e6c0c2bf73268561238b31eb4f796119fb..ecd3c522ac29a48bcae2caa1265538f86eee1a42 100755 (executable)
@@ -415,9 +415,7 @@ bool SMESHGUI_MeshPatternDlg::onApply()
     if ( myPattern->MakeMesh( myMesh, toCreatePolygons, toCreatePolyedrs ) ) {
       mySelectionMgr->clearSelected();
       SUIT_ResourceMgr* mgr = SMESH::GetResourceMgr( mySMESHGUI );
-      bool autoUpdate = false;
-      if (mgr && mgr->stringValue("SMESH", "AutomaticUpdate").compare("true") == 0)
-        autoUpdate = true;
+      bool autoUpdate = SMESHGUI::automaticUpdate();
       if (!isRefine() && autoUpdate) {
        _PTR(SObject) aSO = SMESH::FindSObject(myMesh.in());
        SMESH_Actor* anActor = SMESH::FindActorByEntry(aSO->GetID().c_str());
@@ -855,7 +853,7 @@ void SMESHGUI_MeshPatternDlg::displayPreview()
     aProp->SetRepresentationToWireframe();
     aProp->SetColor(250, 0, 250);
     if (SMESH::FindActorByObject(myMesh))
-      aProp->SetLineWidth(SMESH::GetFloat("SMESH:SettingsWidth", 1) +1);
+      aProp->SetLineWidth( SMESH::GetFloat( "SMESH:element_width", 1 ) + 1 );
     else
       aProp->SetLineWidth(1);
     myPreviewActor->SetProperty(aProp);
index 3237ae7939419f384f29ff694dbafd8cc058243b..47e8f82c2a554187a58180597899e548b2f1fe96 100644 (file)
@@ -178,15 +178,13 @@ namespace SMESH {
       aProp->SetRepresentationToPoints();
 
       float anRGB[3];
-      anRGB[0] = GetFloat("SMESH:SettingsNodeColorRed",0)/255.;
-      anRGB[1] = GetFloat("SMESH:SettingsNodeColorGreen",255)/255.;
-      anRGB[2] = GetFloat("SMESH:SettingsNodeColorBlue",0)/255.;
-      aProp->SetColor(anRGB[0],anRGB[1],anRGB[2]);
+      GetColor( "SMESH", "node_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 255, 0 ) );
+      aProp->SetColor( anRGB[0], anRGB[1], anRGB[2] );
 
-      float aPointSize = GetFloat("SMESH:SettingsNodesSize",3);
-      aProp->SetPointSize(aPointSize);
+      float aPointSize = GetFloat( "SMESH:node_size", 3 );
+      aProp->SetPointSize( aPointSize );
 
-      myPreviewActor->SetProperty(aProp);
+      myPreviewActor->SetProperty( aProp );
       aProp->Delete();
 
       myViewWindow->AddActor(myPreviewActor);
index 924450bb9039b1bf5c9ab0af174fea58eaeab7a9..cc4ccdcaf8d1fa241e6d7d3d6494374d5373bfa5 100644 (file)
@@ -435,15 +435,15 @@ namespace SMESH{
       return;
     }
 
-    QColor aHiColor = mgr->colorValue( "SMESH", "SettingsSelectColor", Qt::white ),
-           aSelColor = mgr->colorValue( "SMESH", "SettingsItemSelectColor", Qt::yellow ),
-          aPreColor = mgr->colorValue( "SMESH", "SettingsPreSelectColor", Qt::cyan );
+    QColor aHiColor = mgr->colorValue( "SMESH", "selection_object_color", Qt::white ),
+           aSelColor = mgr->colorValue( "SMESH", "selection_element_color", Qt::yellow ),
+          aPreColor = mgr->colorValue( "SMESH", "highlight_color", Qt::cyan );
 
-    int SW = mgr->integerValue( "SMESH", "SettingsItemSelectWidth", 5 ),
-        PW = mgr->integerValue( "SMESH", "SettingsPreSelectWidth", 5 );
+    int SW = mgr->integerValue( "SMESH", "selection_width", 5 ),
+        PW = mgr->integerValue( "SMESH", "highlight_width", 5 );
 
-    double SP1 = mgr->doubleValue( "SMESH", "SettingsNodeSelectTol", 0.025 ),
-           SP2 = mgr->doubleValue( "SMESH", "SettingsElementsSelectTol", 0.001 );
+    double SP1 = mgr->doubleValue( "SMESH", "selection_precision_node", 0.025 ),
+           SP2 = mgr->doubleValue( "SMESH", "selection_precision_element", 0.001 );
 
     for ( int i=0, n=views.count(); i<n; i++ ) {
         SVTK_ViewWindow* aVtkView = GetVtkViewWindow( views[i] );
index 8de00d7b76f3b57cebee5a229aa50fa128e39c23..f1f419eb42500f6dd33e24afc016fedcea150f8e 100644 (file)
@@ -9,7 +9,6 @@ msgstr ""
 "Last-Translator: FULLNAME <EMAIL@ADDRESS>\n"
 "Content-Type: text/plain; charset=iso-8859-1\n"
 
-
 #-------------------------------------------------------------------------
 # BUTTON
 #-------------------------------------------------------------------------
@@ -1455,6 +1454,7 @@ msgid "SMESHGUI_SmoothingDlg::IS_PARAMETRIC"
 msgstr "in parametric space"
 
 #---------------SMESHGUI_SewingDlg-----------
+
 msgid "SMESHGUI_SewingDlg::CREATE_POLYGONS_INSTEAD_SPLITTING"
 msgstr "Create polygons instead of splitting"
 
@@ -1536,8 +1536,8 @@ msgstr "Nodes on the side 1 are either not linked or not laying on the element s
 msgid "SMESHGUI_SewingDlg::ERROR_9"
 msgstr "Nodes on the side 2 are either not linked or not laying on the element set boundary"
 
-
 #----------------------------------------------------
+
 msgid "SMESHGUI_ExtrusionDlg::EXTRUSION_ALONG_LINE"
 msgstr "Extrusion along a line"
 
@@ -1611,84 +1611,6 @@ msgstr "Revolution of 1D elements"
 msgid "SMESHGUI_RevolutionDlg::REVOLUTION_2D"
 msgstr "Revolution of 2D elements"
 
-#----------------------------------------------------
-
-msgid "SMESHGUI_SewingDlg::MERGE_EQUAL_ELEMENTS"
-msgstr "Merge equal elements"
-
-msgid "SMESHGUI_SewingDlg::SEW_FREE_BORDERS"
-msgstr "Sew Free Borders"
-
-msgid "SMESHGUI_SewingDlg::BORDER"
-msgstr "Border"
-
-msgid "SMESHGUI_SewingDlg::BORDER_1"
-msgstr "Border 1"
-
-msgid "SMESHGUI_SewingDlg::BORDER_2"
-msgstr "Border 2"
-
-msgid "SMESHGUI_SewingDlg::SEW_CONFORM_FREE_BORDERS"
-msgstr "Sew Conform Free Borders"
-
-msgid "SMESHGUI_SewingDlg::SEW_BORDER_TO_SIDE"
-msgstr "Sew Border To Side"
-
-msgid "SMESHGUI_SewingDlg::SIDE"
-msgstr "Side"
-
-msgid "SMESHGUI_SewingDlg::SEW_SIDE_ELEMENTS"
-msgstr "Sew Side Elements"
-
-msgid "SMESHGUI_SewingDlg::SIDE_1"
-msgstr "Side 1"
-
-msgid "SMESHGUI_SewingDlg::SIDE_2"
-msgstr "Side 2"
-
-msgid "SMESHGUI_SewingDlg::NODE1_TO_MERGE"
-msgstr "Node 1 To Merge"
-
-msgid "SMESHGUI_SewingDlg::NODE2_TO_MERGE"
-msgstr "Node 2 To Merge"
-
-msgid "SMESHGUI_SewingDlg::FIRST_NODE_ID"
-msgstr "First Node ID"
-
-msgid "SMESHGUI_SewingDlg::SECOND_NODE_ID"
-msgstr "Second Node ID"
-
-msgid "SMESHGUI_SewingDlg::LAST_NODE_ID"
-msgstr "Last Node ID"
-
-msgid "SMESHGUI_SewingDlg::ERROR_1"
-msgstr "Free Border1 not found by the selected nodes"
-
-msgid "SMESHGUI_SewingDlg::ERROR_2"
-msgstr "Free Border2 not found by the selected nodes"
-
-msgid "SMESHGUI_SewingDlg::ERROR_3"
-msgstr "Free Border1 and Border2 not found by the selected nodes"
-
-msgid "SMESHGUI_SewingDlg::ERROR_4"
-msgstr "No path from the first side node to the last side node have been found"
-
-msgid "SMESHGUI_SewingDlg::ERROR_5"
-msgstr "Not allowed to splite volumes on the side!"
-
-msgid "SMESHGUI_SewingDlg::ERROR_6"
-msgstr "Different number of elements selected on the sides"
-
-msgid "SMESHGUI_SewingDlg::ERROR_7"
-msgstr "Element sets are topologically different or given nodes are inconvenient"
-
-msgid "SMESHGUI_SewingDlg::ERROR_8"
-msgstr "Nodes on the side 1 are either not linked or not laying on the element set boundary"
-
-msgid "SMESHGUI_SewingDlg::ERROR_9"
-msgstr "Nodes on the side 2 are either not linked or not laying on the element set boundary"
-
-
 #----------------------------------------------------
 
 #Coincident nodes
@@ -2800,3 +2722,81 @@ msgstr "Modification Toolbar"
 msgid "TB_DISP_MODE"
 msgstr "Display Mode Toolbar"
 
+#-------------------------------------------------------------------------
+# PREFEERENCES
+#-------------------------------------------------------------------------
+
+msgid "SMESHGUI::PREF_TAB_GENERAL"
+msgstr "General"
+
+msgid "SMESHGUI::PREF_GROUP_QUALITY"
+msgstr "Quality controls"
+
+msgid "SMESHGUI::PREF_DISPLAY_ENTITY"
+msgstr "Display entity"
+
+msgid "SMESHGUI::PREF_AUTO_UPDATE"
+msgstr "Automatic update"
+
+msgid "SMESHGUI::PREF_PRECISION_USE"
+msgstr "Use precision"
+
+msgid "SMESHGUI::PREF_PRECISION_VALUE"
+msgstr "Number of digits after point"
+
+msgid "SMESHGUI::PREF_GROUP_PRECISION"
+msgstr "Precision"
+
+msgid "SMESHGUI::PREF_TAB_MESH"
+msgstr "Mesh"
+
+msgid "SMESHGUI::PREF_GROUP_NODES"
+msgstr "Nodes"
+
+msgid "SMESHGUI::PREF_GROUP_ELEMENTS"
+msgstr "Elements"
+
+msgid "SMESHGUI::PREF_COLOR"
+msgstr "Color"
+
+msgid "SMESHGUI::PREF_SIZE"
+msgstr "Size"
+
+msgid "SMESHGUI::PREF_WIDTH"
+msgstr "Width"
+
+msgid "SMESHGUI::PREF_FILL"
+msgstr "Fill"
+
+msgid "SMESHGUI::PREF_OUTLINE"
+msgstr "Outline"
+
+msgid "SMESHGUI::PREF_BACKFACE"
+msgstr "Back face"
+
+msgid "SMESHGUI::PREF_SHRINK_COEFF"
+msgstr "Shrink coef."
+
+msgid "SMESHGUI::PREF_TAB_SELECTION"
+msgstr "Selection"
+
+msgid "SMESHGUI::PREF_GROUP_SELECTION"
+msgstr "Selection"
+
+msgid "SMESHGUI::PREF_GROUP_PRESELECTION"
+msgstr "Preselection"
+
+msgid "SMESHGUI::PREF_OBJECT_COLOR"
+msgstr "Object color"
+
+msgid "SMESHGUI::PREF_ELEMENT_COLOR"
+msgstr "Element color"
+
+msgid "SMESHGUI::PREF_HIGHLIGHT_COLOR"
+msgstr "Highlight color"
+
+msgid "SMESHGUI::PREF_NODES"
+msgstr "Nodes"
+
+msgid "SMESHGUI::PREF_ELEMENTS"
+msgstr "Elements"