Salome HOME
Bug IPAL22876: TC6.5.0: Show error is absent in popup menu for multiply selection
[modules/visu.git] / src / VISUGUI / VisuGUI.cxx
index 28dd76e20ff378604cfebac5591d429860ee14ff..a8c76b6b0a0274cb4f605f20199ee5464551464c 100644 (file)
@@ -1,29 +1,36 @@
-//  Copyright (C) 2007-2008  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2012  CEA/DEN, EDF R&D, OPEN CASCADE
 //
-//  Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-//  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+// Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
 //
-//  This library is free software; you can redistribute it and/or
-//  modify it under the terms of the GNU Lesser General Public
-//  License as published by the Free Software Foundation; either
-//  version 2.1 of the License.
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
 //
-//  This library is distributed in the hope that it will be useful,
-//  but WITHOUT ANY WARRANTY; without even the implied warranty of
-//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-//  Lesser General Public License for more details.
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+// Lesser General Public License for more details.
 //
-//  You should have received a copy of the GNU Lesser General Public
-//  License along with this library; if not, write to the Free Software
-//  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
 //
-//  See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
 //
+
 //  VISU VISUGUI : GUI of VISU component
 //  File   : VisuGUI.cxx
 //  Author :
 //  Module : VISU
 
+#include <Standard_math.hxx>  // E.A. must be included before Python.h to fix compilation on windows
+#ifdef HAVE_FINITE
+#undef HAVE_FINITE            // VSR: avoid compilation warning on Linux : "HAVE_FINITE" redefined
+#endif
+#include "Python.h"
+
 #include "VisuGUI.h"
 
 // STL Includes
 #include "SVTK_Functor.h"
 //#include "SVTK_MainWindow.h"
 
+#include "VTKViewer_Algorithm.h"
+#include "VTKViewer_MarkerDlg.h"
+
 #include "SPlot2d_ViewModel.h"
 #include "VisuGUI_SetupPlot2dDlg.h"
 #include "Plot2d_SetupCurveDlg.h"
 #include "Plot2d_ViewManager.h"
+#include "Plot2d_SetupCurveScaleDlg.h"
 
 #include "QtxPagePrefMgr.h"
 #include "OB_Browser.h"
@@ -76,6 +87,7 @@
 #include "SalomeApp_Application.h"
 #include "SalomeApp_DataModel.h"
 #include "SalomeApp_Study.h"
+#include "SalomeApp_DataObject.h"
 #include "SalomeApp_CheckFileDlg.h"
 
 #include "LightApp_SelectionMgr.h"
 #include "VisuGUI_CursorDlg.h"
 #include "VisuGUI_Selection.h"
 #include "VisuGUI_TimeAnimation.h"
+#include "VisuGUI_EvolutionDlg.h"
 #include "VisuGUI_EditContainerDlg.h"
 #include "VisuGUI_ClippingDlg.h"
 #include "VisuGUI_Plot3DDlg.h"
 #include "VisuGUI_Displayer.h"
 #include "VisuGUI_BuildProgressDlg.h"
 #include "VisuGUI_TransparencyDlg.h"
-#include "VisuGUI_CacheDlg.h"
+#include "VisuGUI_ShrinkFactorDlg.h"
+//#include "VisuGUI_CacheDlg.h"
 #include "VisuGUI_Table3dDlg.h"
 #include "VisuGUI_ClippingPanel.h"
 #include "VisuGUI_FilterScalarsDlg.h"
 #include "VISU_CutLines_i.hh"
 #include "VisuGUI_CutLinesDlg.h"
 
+#include "VISU_CutSegment_i.hh"
+#include "VisuGUI_CutSegmentDlg.h"
+
 #include "VISU_StreamLines_i.hh"
 #include "VisuGUI_StreamLinesDlg.h"
 
 #include "VISU_Vectors_i.hh"
 #include "VisuGUI_VectorsDlg.h"
 
-#include "VisuGUI_TableDlg.h"
+#include "VISU_TableDlg.h"
 #include "VisuGUI_FileInfoDlg.h"
 
 #include "SALOMEconfig.h"
@@ -182,6 +199,7 @@ static int MYDEBUG = 0;
 VisuGUI
 ::VisuGUI():
   SalomeApp_Module( "VISU" ),
+  LightApp_Module("VISU"),
   myDisplayer( 0 ),
   mySlider( NULL ),
   mySweep( NULL )
@@ -191,6 +209,132 @@ VisuGUI
 VisuGUI
 ::~VisuGUI()
 {
+  if( myDisplayer ) {
+    delete myDisplayer;
+    myDisplayer = 0;
+  }
+
+  if( mySlider ) {
+    delete mySlider;
+    mySlider = 0;
+  }
+
+  if( mySweep ) {
+    delete mySweep;
+    mySweep = 0;
+  }
+}
+
+void
+VisuGUI
+::OnImportFromSauvFile()
+{
+  if(MYDEBUG) MESSAGE("VisuGUI::OnImportFromSauvFile()");
+
+  if ( CheckLock(GetCStudy(GetAppStudy(this)),GetDesktop(this)) )
+    return;
+
+  SUIT_ResourceMgr* aResourceMgr = GetResourceMgr();
+
+  // Get file name(s)
+  QStringList aFilter;
+  aFilter.append( tr( "FLT_SAUV_FILES" ) );
+  aFilter.append( tr( "FLT_ALL_FILES" ) );
+
+  bool toUseBuildProgress = aResourceMgr->booleanValue("VISU", "use_build_progress", false);
+
+  SalomeApp_CheckFileDlg fd( GetDesktop(this), true, tr("USE_BUILD_PROGRESS") );
+  fd.setWindowTitle( tr( "IMPORT_FROM_FILE" ) );
+  fd.setFileMode( SalomeApp_CheckFileDlg::ExistingFiles );
+  fd.setFilters( aFilter );
+  fd.SetChecked( toUseBuildProgress );
+  if ( SalomeApp_CheckFileDlg::getLastVisitedPath().isEmpty() )
+    fd.setDirectory( QDir::currentPath() );
+
+  QStringList fileNames;
+  if ( !fd.exec() )
+    return; // cancelled, return
+
+  fileNames = fd.selectedFiles();
+  toUseBuildProgress = fd.IsChecked();
+
+  if ( fileNames.count() == 0 )
+    return; // nothing selected, return
+
+  SUIT_OverrideCursor wc;
+  QStringList errors;
+
+  for ( QStringList::ConstIterator it = fileNames.begin(); it != fileNames.end(); ++it ) {
+    QFileInfo aFileInfo( *it );
+
+    if ( !aFileInfo.exists() ) {
+      // file not exist
+      errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).
+                     arg( tr( "ERR_FILE_NOT_EXISTS" ) ) );
+    }
+    else {
+      std::string file_in = aFileInfo.filePath().toLatin1().constData();
+      std::string file_tmp = file_in + ".med";
+#ifdef WNT
+      std::string cmd = "%PYTHONBIN% ";
+#else
+      std::string cmd = "python ";
+#endif
+      cmd += "-c \"";
+      cmd += "from medutilities import convert ; convert(r'" + file_in + "', 'GIBI', 'MED', 1, r'" + file_tmp + "')";
+      cmd += "\"";
+      system(cmd.c_str());
+      QString fff(file_tmp.c_str());
+      aFileInfo = fff;
+      try {
+        if ( !toUseBuildProgress ) {
+          // build progress is not used, use build flags from settings
+          bool toBuildFields = aResourceMgr->booleanValue( "VISU", "build_fields",     true );
+          bool toBuildMinMax = aResourceMgr->booleanValue( "VISU", "build_min_max",    true );
+          bool toBuildGroups = aResourceMgr->booleanValue( "VISU", "build_groups",     true );
+          bool toBuildAll    = aResourceMgr->booleanValue( "VISU", "full_med_loading", false );
+          bool toBuildAtOnce = aResourceMgr->booleanValue( "VISU", "build_at_once",    false );
+
+          QString anInfo( tr( "IMPORT_FROM_FILE" ) + " " + aFileInfo.filePath() + " ... " );
+          application()->putInfo( anInfo );
+
+          VISU::Result_var aResult = GetVisuGen( this )->CreateResult( aFileInfo.filePath().toLatin1().constData() );
+
+          if ( CORBA::is_nil( aResult.in() ) ) {
+            errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).
+                           arg( tr( "ERR_ERROR_IN_THE_FILE" ) ) );
+          }
+          else {
+            aResult->SetBuildFields( toBuildFields, toBuildMinMax );
+            aResult->SetBuildGroups( toBuildGroups );
+            aResult->Build( toBuildAll, toBuildAtOnce );
+            application()->putInfo( anInfo + tr("INF_DONE") );
+          }
+        } // if ( !toUseBuildProgress )
+        else {
+          // use build progress
+          wc.suspend();
+          VisuGUI_BuildProgressDlg* aBuildProgressDlg = new VisuGUI_BuildProgressDlg( GetDesktop(this) );
+          aBuildProgressDlg->setFileName( aFileInfo.filePath() );
+          aBuildProgressDlg->setGenerator( GetVisuGen(this) );
+          aBuildProgressDlg->exec();
+          wc.resume();
+        }
+      } // try
+      catch(...) {
+        errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).arg( tr( "UNKNOWN_IMPORT_ERROR" ) ) );
+      }
+    } // else // if ( !aFileInfo.exists() )
+  } // for (...)
+
+  if ( errors.count() > 0 ) {
+    SUIT_MessageBox::critical( GetDesktop(this),
+                               tr("ERR_ERROR"),
+                               tr("IMPORT_ERRORS" ) + "\n" + errors.join( "\n" ) );
+  }
+  else {
+    UpdateObjBrowser(this);
+  }
 }
 
 void
@@ -232,6 +376,7 @@ VisuGUI
 
   SUIT_OverrideCursor wc;
   QStringList errors;
+  QStringList anEntryList;
 
   for ( QStringList::ConstIterator it = fileNames.begin(); it != fileNames.end(); ++it ) {
     QFileInfo aFileInfo( *it );
@@ -239,57 +384,61 @@ VisuGUI
     if ( !aFileInfo.exists() ) {
       // file not exist
       errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).
-                    arg( tr( "ERR_FILE_NOT_EXISTS" ) ) );
+                     arg( tr( "ERR_FILE_NOT_EXISTS" ) ) );
     }
     else {
       try {
-       if ( !toUseBuildProgress ) {
-         // build progress is not used, use build flags from settings
-         bool toBuildFields = aResourceMgr->booleanValue( "VISU", "build_fields",     true );
-         bool toBuildMinMax = aResourceMgr->booleanValue( "VISU", "build_min_max",    true );
-         bool toBuildGroups = aResourceMgr->booleanValue( "VISU", "build_groups",     true );
-         bool toBuildAll    = aResourceMgr->booleanValue( "VISU", "full_med_loading", false );
-         bool toBuildAtOnce = aResourceMgr->booleanValue( "VISU", "build_at_once",    false );
-
-         QString anInfo( tr( "IMPORT_FROM_FILE" ) + " " + aFileInfo.filePath() + " ... " );
-         application()->putInfo( anInfo );
-
-         VISU::Result_var aResult = GetVisuGen( this )->CreateResult( aFileInfo.filePath().toLatin1().constData() );
-
-         if ( CORBA::is_nil( aResult.in() ) ) {
-           errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).
-                          arg( tr( "ERR_ERROR_IN_THE_FILE" ) ) );
-         }
-         else {
-           aResult->SetBuildFields( toBuildFields, toBuildMinMax );
-           aResult->SetBuildGroups( toBuildGroups );
-           aResult->Build( toBuildAll, toBuildAtOnce );
-           application()->putInfo( anInfo + tr("INF_DONE") );
-         }
-       } // if ( !toUseBuildProgress )
-       else {
-         // use build progress
-         wc.suspend();
-         VisuGUI_BuildProgressDlg* aBuildProgressDlg = new VisuGUI_BuildProgressDlg( GetDesktop(this) );
-         aBuildProgressDlg->setFileName( aFileInfo.filePath() );
-         aBuildProgressDlg->setGenerator( GetVisuGen(this) );
-         aBuildProgressDlg->exec();
-         wc.resume();
-       }
+        if ( !toUseBuildProgress ) {
+          // build progress is not used, use build flags from settings
+          bool toBuildFields = aResourceMgr->booleanValue( "VISU", "build_fields",     true );
+          bool toBuildMinMax = aResourceMgr->booleanValue( "VISU", "build_min_max",    true );
+          bool toBuildGroups = aResourceMgr->booleanValue( "VISU", "build_groups",     true );
+          bool toBuildAll    = aResourceMgr->booleanValue( "VISU", "full_med_loading", false );
+          bool toBuildAtOnce = aResourceMgr->booleanValue( "VISU", "build_at_once",    false );
+
+          QString anInfo( tr( "IMPORT_FROM_FILE" ) + " " + aFileInfo.filePath() + " ... " );
+          application()->putInfo( anInfo );
+
+          VISU::Result_var aResult = GetVisuGen( this )->CreateResult( aFileInfo.filePath().toLatin1().constData() );
+
+          if ( CORBA::is_nil( aResult.in() ) ) {
+            errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).
+                           arg( tr( "ERR_ERROR_IN_THE_FILE" ) ) );
+          }
+          else {
+            aResult->SetBuildFields( toBuildFields, toBuildMinMax );
+            aResult->SetBuildGroups( toBuildGroups );
+            aResult->Build( toBuildAll, toBuildAtOnce );
+            if( VISU::Result_i* aCResult = dynamic_cast<VISU::Result_i*>( VISU::GetServant( aResult ).in() ) )
+              anEntryList.append( aCResult->GetEntry().c_str() );
+            application()->putInfo( anInfo + tr("INF_DONE") );
+          }
+        } // if ( !toUseBuildProgress )
+        else {
+          // use build progress
+          wc.suspend();
+          VisuGUI_BuildProgressDlg* aBuildProgressDlg = new VisuGUI_BuildProgressDlg( GetDesktop(this) );
+          aBuildProgressDlg->setFileName( aFileInfo.filePath() );
+          aBuildProgressDlg->setGenerator( GetVisuGen(this) );
+          aBuildProgressDlg->exec();
+          wc.resume();
+        }
       } // try
       catch(...) {
-       errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).arg( tr( "UNKNOWN_IMPORT_ERROR" ) ) );
+        errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).arg( tr( "UNKNOWN_IMPORT_ERROR" ) ) );
       }
     } // else // if ( !aFileInfo.exists() )
   } // for (...)
 
   if ( errors.count() > 0 ) {
     SUIT_MessageBox::critical( GetDesktop(this),
-                              tr("ERR_ERROR"),
-                              tr("IMPORT_ERRORS" ) + "\n" + errors.join( "\n" ) );
+                               tr("ERR_ERROR"),
+                               tr("IMPORT_ERRORS" ) + "\n" + errors.join( "\n" ) );
   }
   else {
     UpdateObjBrowser(this);
+    if( getApp() )
+      getApp()->browseObjects( anEntryList );
   }
 }
 
@@ -305,53 +454,77 @@ VisuGUI
   aFilter.append( tr("FLT_TABLE_FILES") );
   aFilter.append( tr("FLT_ALL_FILES") );
 
-  QString anInitialPath = "";
-  if ( SUIT_FileDlg::getLastVisitedPath().isEmpty() )
-    anInitialPath = QDir::currentPath();
+  //QString anInitialPath = "";
+  //if ( SUIT_FileDlg::getLastVisitedPath().isEmpty() )
+  //  anInitialPath = QDir::currentPath();
+
+  //QStringList aFiles = SUIT_FileDlg::getOpenFileNames(GetDesktop(this),
+  //                                                    anInitialPath,
+  //                                                    aFilter,
+  //                                                    tr("TLT_IMPORT_TABLE"));
+
+  SUIT_ResourceMgr* aResourceMgr = GetResourceMgr();
+  bool aFirstStrAsTitle = aResourceMgr->booleanValue("VISU", "first_str_as_title", false);
+
+  SalomeApp_CheckFileDlg fd( GetDesktop(this), true, tr("FIRST_STR_AS_TITLE") );
+  fd.setWindowTitle( tr( "IMPORT_FROM_FILE" ) );
+  fd.setFileMode( SalomeApp_CheckFileDlg::ExistingFiles );
+  fd.setFilters( aFilter );
+  fd.SetChecked( aFirstStrAsTitle );
+  if ( SalomeApp_CheckFileDlg::getLastVisitedPath().isEmpty() )
+    fd.setDirectory( QDir::currentPath() );
+
+  QStringList aFiles;
+  if ( !fd.exec() )
+    return; // cancelled, return
+  aFiles = fd.selectedFiles();
+  aFirstStrAsTitle = fd.IsChecked();
 
-  QStringList aFiles = SUIT_FileDlg::getOpenFileNames(GetDesktop(this),
-                                                     anInitialPath,
-                                                     aFilter,
-                                                     tr("TLT_IMPORT_TABLE"));
   if ( aFiles.count() == 0 )
     return; // nothing selected
 
   QStringList errors;
+  QStringList anEntryList;
   for ( QStringList::ConstIterator it = aFiles.begin(); it != aFiles.end(); ++it ) {
     QFileInfo aFileInfo( *it );
 
     if ( !aFileInfo.exists() ) {
       errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).
-                    arg( tr( "ERR_FILE_NOT_EXISTS" ) ) );
+                     arg( tr( "ERR_FILE_NOT_EXISTS" ) ) );
     }
     else {
       try {
-       QString anInfo( tr("TLT_IMPORT_TABLE") + " " + aFileInfo.filePath() + " ..." );
-       application()->putInfo( anInfo );
+        QString anInfo( tr("TLT_IMPORT_TABLE") + " " + aFileInfo.filePath() + " ..." );
+        application()->putInfo( anInfo );
 
-       CORBA::Object_var anObject = GetVisuGen(this)->ImportTables(aFileInfo.filePath().toLatin1().constData());
+        SALOMEDS::SObject_var anObject =
+          GetVisuGen(this)->ImportTables(aFileInfo.filePath().toLatin1().constData(),
+                                         aFirstStrAsTitle);
 
-       if (CORBA::is_nil(anObject.in())) {
-         errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).
-                        arg( tr( "ERR_ERROR_IN_THE_FILE" ) ) );
-       }
-       else {
-         application()->putInfo( anInfo + tr("INF_DONE") );
-       }
+        if (CORBA::is_nil(anObject.in())) {
+          errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).
+                         arg( tr( "ERR_ERROR_IN_THE_FILE" ) ) );
+        }
+        else {
+          anEntryList.append( anObject->GetID() );
+          application()->putInfo( anInfo + tr("INF_DONE") );
+        }
       }
       catch(...) {
-       errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).arg( tr( "UNKNOWN_IMPORT_ERROR" ) ) );
+        errors.append( QString( "%1 :\n\t%2" ).arg( aFileInfo.filePath() ).arg( tr( "UNSUPPORTED_FILE_FORMAT" ) ) );
       }
     }
   }
 
   if ( errors.count() > 0 ) {
     SUIT_MessageBox::critical( GetDesktop(this),
-                              tr("ERR_ERROR"),
-                              tr("IMPORT_ERRORS" ) + "\n" + errors.join( "\n" ) );
+                               tr("ERR_ERROR"),
+                               tr("IMPORT_ERRORS" ) + "\n" + errors.join( "\n" ) );
   }
   else {
     UpdateObjBrowser(this);
+    if( getApp() )
+      getApp()->browseObjects( anEntryList );
   }
 }
 
@@ -401,8 +574,8 @@ VisuGUI
         if (!aTabAttr) return;
         aTitle = aTabAttr->GetTitle().c_str();
       } else {
-       _PTR(AttributeTableOfInteger) aTabAttr (anAttr);
-       if (!aTabAttr) return;
+        _PTR(AttributeTableOfInteger) aTabAttr (anAttr);
+        if (!aTabAttr) return;
         aTitle = aTabAttr->GetTitle().c_str();
       }
       aTitle.simplified();
@@ -421,7 +594,8 @@ VisuGUI
 
       // get name for the file
       QStringList aFilter;
-      aFilter.append("Table Files (*.xls)");
+      aFilter.append("Table Files (*.txt *.tab)");
+      aFilter.append("CSV Table Files (*.csv)");
 
       QFileInfo aFileInfo =
         SUIT_FileDlg::getFileName(GetDesktop(this),
@@ -434,25 +608,25 @@ VisuGUI
       QString aFile = aFileInfo.filePath();
       if (!aFile.isEmpty()) {
         application()->putInfo(tr("MEN_EXPORT_TABLE") + " " + aFile + " ...");
-       aDir = Qtx::dir(aFile, true);
+        aDir = Qtx::dir(aFile, true);
         aResourceMgr->setValue("VISU", "OutputDir", aDir);
 
-       try {
-         GetVisuGen(this)->ExportTableToFile(GetSObject(aSObj), (const char*)aFile.toLatin1());
+        try {
+          GetVisuGen(this)->ExportTableToFile(GetSObject(aSObj), (const char*)aFile.toLatin1());
           application()->putInfo(aFile + " " + tr("INF_DONE"));
-       } catch(std::exception& exc) {
-         INFOS(exc.what());
-         SUIT_MessageBox::warning(GetDesktop(this),
+        } catch(std::exception& exc) {
+          INFOS(exc.what());
+          SUIT_MessageBox::warning(GetDesktop(this),
                                    tr("WRN_VISU"),
-                                  tr("ERR_ERROR_DURING_EXPORT") + " " + tr(exc.what()) );
+                                   tr("ERR_ERROR_DURING_EXPORT") + " " + tr(exc.what()) );
 
-       } catch(...) {
-         INFOS((const char*)tr("ERR_ERROR_DURING_EXPORT").toLatin1());
-         SUIT_MessageBox::warning( GetDesktop(this),
+        } catch(...) {
+          INFOS((const char*)tr("ERR_ERROR_DURING_EXPORT").toLatin1());
+          SUIT_MessageBox::warning( GetDesktop(this),
                                     tr("WRN_VISU"),
-                                   tr("ERR_ERROR_DURING_EXPORT") );
+                                    tr("ERR_ERROR_DURING_EXPORT") );
 
-       }
+        }
       }
     }
   }
@@ -471,6 +645,7 @@ VisuGUI
   SALOME_ListIO aListIO;
   aSelectionMgr->selectedObjects(aListIO);
 
+  QStringList anEntryList;
   SALOME_ListIteratorOfListIO It (aListIO);
   QApplication::setOverrideCursor(Qt::WaitCursor);
   for (; It.More(); It.Next()) {
@@ -510,14 +685,15 @@ VisuGUI
         }
       }
 
+      VISU::Result_var aResult;
       CORBA::Object_var anObject = VISU::SObjectToObject(aSObject);
       if (!CORBA::is_nil(anObject)) {
         SALOME_MED::MED_var aMED = SALOME_MED::MED::_narrow(anObject);
         if (!CORBA::is_nil(aMED.in()))
-          GetVisuGen(this)->ImportMed(aSObject);
+          aResult = GetVisuGen(this)->ImportMed(aSObject);
         SALOME_MED::FIELD_var aField = SALOME_MED::FIELD::_narrow(anObject);
         if (!CORBA::is_nil(aField.in()))
-          GetVisuGen(this)->ImportMedField(aField);
+          aResult = GetVisuGen(this)->ImportMedField(aField);
       } else {
         SALOMEDS::SObject_var aSFather = aSObject->GetFather();
         SALOMEDS::GenericAttribute_var anAttr;
@@ -525,11 +701,17 @@ VisuGUI
         SALOMEDS::AttributeName_var aName = SALOMEDS::AttributeName::_narrow(anAttr);
         CORBA::String_var aValue = aName->Value();
         if (strcmp(aValue.in(), "MEDFIELD") == 0)
-          GetVisuGen(this)->ImportMed(aSObject);
+          aResult = GetVisuGen(this)->ImportMed(aSObject);
       }
+
+      if( !CORBA::is_nil( aResult ) )
+        if( VISU::Result_i* aCResult = dynamic_cast<VISU::Result_i*>( VISU::GetServant( aResult ).in() ) )
+          anEntryList.append( aCResult->GetEntry().c_str() );
     }
   }
   UpdateObjBrowser(this, true);
+  if( getApp() )
+    getApp()->browseObjects( anEntryList );
   QApplication::restoreOverrideCursor();
 }
 
@@ -596,14 +778,26 @@ void VisuGUI::OnLoadComponentData()
 
 void
 CreateCurves( SalomeApp_Module* theModule,
-              VISU::CutLines_i* thePrs,
+              VISU::CutLinesBase_i* thePrs,
               QDialog* theDlg,
               const bool theCreate = true )
 {
   if ( !thePrs )
     return;
-  VisuGUI_CutLinesDlg* aCutDlg = dynamic_cast<VisuGUI_CutLinesDlg*>( theDlg );
-  if ( !aCutDlg )
+
+  // temporary code, to be revised (VisuGUI_CutLinesDlg and VisuGUI_CutSegmentDlg classes
+  // should have common intermediate interface with at least two methods called below)
+  bool isGenerateTable = false;
+  bool isGenerateCurves = false;
+  if ( VisuGUI_CutLinesDlg* aCutDlg = dynamic_cast<VisuGUI_CutLinesDlg*>( theDlg ) ) {
+    isGenerateTable = aCutDlg->isGenerateTable();
+    isGenerateCurves = aCutDlg->isGenerateCurves();
+  }
+  else if ( VisuGUI_CutSegmentDlg* aCutDlg = dynamic_cast<VisuGUI_CutSegmentDlg*>( theDlg ) ) {
+    isGenerateTable = aCutDlg->isGenerateTable();
+    isGenerateCurves = aCutDlg->isGenerateCurves();
+  }
+  else
     return;
 
   _PTR(Study)   aStudy = GetCStudy( GetAppStudy( theModule ) );
@@ -618,38 +812,38 @@ CreateCurves( SalomeApp_Module* theModule,
       if( aTblObj ) {
         _PTR(GenericAttribute) anAttr;
         if (aTblObj->FindAttribute( anAttr, "AttributeName" ) ) {
-         _PTR(ChildIterator) aChildIter = aStudy->NewChildIterator( aTblObj );
-         SalomeApp_Study* salome_study = GetAppStudy( theModule );
-         for( aChildIter->InitEx( false ); aChildIter->More(); aChildIter->Next() ){
-           salome_study->deleteReferencesTo( aChildIter->Value() );
-           _PTR(SObject) aSO = aChildIter->Value();
-           if(aSO){
-             Storable::TRestoringMap aRestoringMap = Storable::GetStorableMap(aSO);
-             if (aRestoringMap["myComment"] == "CURVE") {
-               CORBA::Object_var aCORBAObject = VISU::ClientSObjectToObject(aSO);
-               if(!CORBA::is_nil(aCORBAObject)){
-                 PortableServer::ServantBase_var aServant = VISU::GetServant(aCORBAObject);
-                 if(VISU::Curve_i* aCurve = dynamic_cast<VISU::Curve_i*>(aServant.in())){
-                   PlotRemoveCurve(theModule, aCurve);
-                 }
-               }
-             }
-           }
+          _PTR(ChildIterator) aChildIter = aStudy->NewChildIterator( aTblObj );
+          SalomeApp_Study* salome_study = GetAppStudy( theModule );
+          for( aChildIter->InitEx( false ); aChildIter->More(); aChildIter->Next() ){
+            salome_study->deleteReferencesTo( aChildIter->Value() );
+            _PTR(SObject) aSO = aChildIter->Value();
+            if(aSO){
+              Storable::TRestoringMap aRestoringMap = Storable::GetStorableMap(aSO);
+              if (aRestoringMap["myComment"] == "CURVE") {
+                CORBA::Object_var aCORBAObject = VISU::ClientSObjectToObject(aSO);
+                if(!CORBA::is_nil(aCORBAObject)){
+                  PortableServer::ServantBase_var aServant = VISU::GetServant(aCORBAObject);
+                  if(VISU::Curve_i* aCurve = dynamic_cast<VISU::Curve_i*>(aServant.in())){
+                    PlotRemoveCurve(theModule, aCurve);
+                  }
+                }
+              }
+            }
 
-         }
+          }
 
           aBuilder->RemoveObjectWithChildren( aTblObj ); // We should have only one child
 
-         //UpdateObjBrowser(theModule,true,aTblObj);
+          //UpdateObjBrowser(theModule,true,aTblObj);
           break;
         }
       }
     }
   }
 
-  if ( aCutDlg->isGenerateTable() ) {
+  if ( isGenerateTable ) {
     GetVisuGen( theModule )->CreateTable( thePrs->GetEntry().c_str() );
-    if ( aCutDlg->isGenerateCurves() ) {
+    if ( isGenerateCurves ) {
       if ( aSObject ) {
         _PTR(StudyBuilder) aBuilder = aStudy->NewBuilder();
         _PTR(ChildIterator) aIter = aStudy->NewChildIterator(aSObject);
@@ -695,8 +889,7 @@ VisuGUI
   // create mesh presentation and display it in aViewWindow
   VISU::Mesh_i* aPrs = CreateMesh(this, anIO, aViewWindow);
   aViewWindow->highlight(anIO, 1);
-  if (aPrs)
-    emit presentationCreated(aPrs);
+  processPresentationCreated(aPrs);
 }
 
 void
@@ -723,8 +916,7 @@ VisuGUI
     // create mesh presentation and display it in aViewWindow
     VISU::Mesh_i* aPrs = CreateMesh(this, anIO, aViewWindow);
     aViewWindow->highlight(anIO, 1);
-    if (aPrs)
-      emit presentationCreated(aPrs);
+    processPresentationCreated(aPrs);
   }
 }
 
@@ -733,8 +925,7 @@ VisuGUI
 ::OnCreateScalarMap()
 {
   Prs3d_i* aPrs = CreatePrs3d<VISU::ScalarMap_i,VisuGUI_ScalarBarDlg,1>(this);
-  if (aPrs)
-    emit presentationCreated(aPrs);
+  processPresentationCreated(aPrs);
 }
 
 
@@ -743,8 +934,7 @@ VisuGUI
 ::OnCreateDeformedShape()
 {
   Prs3d_i* aPrs = CreatePrs3d<VISU::DeformedShape_i,VisuGUI_DeformedShapeDlg,1>(this);
-  if (aPrs)
-    emit presentationCreated(aPrs);
+  processPresentationCreated(aPrs);
 }
 
 void
@@ -752,8 +942,7 @@ VisuGUI
 ::OnCreateDeformedShapeAndScalarMap()
 {
   Prs3d_i* aPrs = CreatePrs3d<VISU::DeformedShapeAndScalarMap_i,VisuGUI_DeformedShapeAndScalarMapDlg,1>(this);
-  if (aPrs)
-    emit presentationCreated(aPrs);
+  processPresentationCreated(aPrs);
 }
 
 void
@@ -761,8 +950,7 @@ VisuGUI
 ::OnCreateVectors()
 {
   Prs3d_i* aPrs = CreatePrs3d<VISU::Vectors_i,VisuGUI_VectorsDlg,1>(this);
-  if (aPrs)
-    emit presentationCreated(aPrs);
+  processPresentationCreated(aPrs);
 }
 
 void
@@ -770,8 +958,7 @@ VisuGUI
 ::OnCreateIsoSurfaces()
 {
   Prs3d_i* aPrs = CreatePrs3d<VISU::IsoSurfaces_i,VisuGUI_IsoSurfacesDlg,1>(this);
-  if (aPrs)
-    emit presentationCreated(aPrs);
+  processPresentationCreated(aPrs);
 }
 
 void
@@ -779,8 +966,7 @@ VisuGUI
 ::OnCreateCutPlanes()
 {
   Prs3d_i* aPrs = CreatePrs3d<VISU::CutPlanes_i,VisuGUI_CutPlanesDlg,0>(this);
-  if (aPrs)
-    emit presentationCreated(aPrs);
+  processPresentationCreated(aPrs);
 }
 
 void
@@ -788,8 +974,15 @@ VisuGUI
 ::OnCreateCutLines()
 {
   Prs3d_i* aPrs = CreatePrs3d<VISU::CutLines_i,VisuGUI_CutLinesDlg,0>(this);
-  if (aPrs)
-    emit presentationCreated(aPrs);
+  processPresentationCreated(aPrs);
+}
+
+void
+VisuGUI
+::OnCreateCutSegment()
+{
+  Prs3d_i* aPrs = CreatePrs3d<VISU::CutSegment_i,VisuGUI_CutSegmentDlg,0>(this);
+  processPresentationCreated(aPrs);
 }
 
 void
@@ -797,8 +990,7 @@ VisuGUI
 ::OnCreateStreamLines()
 {
   Prs3d_i* aPrs = CreatePrs3d<VISU::StreamLines_i,VisuGUI_StreamLinesDlg,1>(this);
-  if (aPrs)
-    emit presentationCreated(aPrs);
+  processPresentationCreated(aPrs);
 }
 
 void
@@ -806,8 +998,7 @@ VisuGUI
 ::OnCreatePlot3D()
 {
   Prs3d_i* aPrs = CreatePrs3d<VISU::Plot3D_i,VisuGUI_Plot3DDlg,0>(this);
-  if (aPrs)
-    emit presentationCreated(aPrs);
+  processPresentationCreated(aPrs);
 }
 
 void
@@ -815,8 +1006,17 @@ VisuGUI
 ::OnCreatePlot2dView()
 {
   CheckLock(GetCStudy(GetAppStudy(this)),GetDesktop(this));
-  GetVisuGen( this )->CreateContainer();
+  VISU::Container_var aContainer = GetVisuGen( this )->CreateContainer();
   UpdateObjBrowser(this);
+
+  if( !CORBA::is_nil( aContainer.in() ) ) {
+    if( VISU::Container_i* aCContainer = dynamic_cast<VISU::Container_i*>( VISU::GetServant( aContainer ).in() ) ) {
+      QStringList anEntryList;
+      anEntryList.append( aCContainer->GetEntry().c_str() );
+      if( getApp() )
+        getApp()->browseObjects( anEntryList );
+    }
+  }
 }
 
 void
@@ -846,31 +1046,33 @@ VisuGUI
     switch (aType) {
     case VISU::TPOINTMAP3D:
       if(SVTK_ViewWindow* aViewWindow = GetActiveViewWindow<SVTK_ViewWindow>(this)){
-       displayer()->Display(anIO->getEntry());
-       aViewWindow->highlight(anIO, 1);
-       aViewWindow->getRenderer()->ResetCameraClippingRange();
-       aViewWindow->Repaint();
-       break;
+        displayer()->Display(anIO->getEntry());
+        aViewWindow->highlight(anIO, 1);
+        aViewWindow->getRenderer()->ResetCameraClippingRange();
+        aViewWindow->Repaint();
+        break;
       }
       else {
-       if (SPlot2d_Viewer* aPlot2d = GetPlot2dViewer(this, false))
-         aPlot2d->Repaint();
-       displayer()->Display(anIO->getEntry());
+        if (SPlot2d_Viewer* aPlot2d = GetPlot2dViewer(this, false))
+          aPlot2d->Repaint();
+        displayer()->Display(anIO->getEntry());
       }
     case VISU::TCURVE:
     case VISU::TCONTAINER:
     case VISU::TTABLE:
+      getViewManager(SPlot2d_Viewer::Type(), true);
       displayer()->Display(anIO->getEntry());
+      aSelectionMgr->setSelectedObjects(aList);
       break;
     default: {
       VISU::Prs3d_i* aPrs3d = VISU::GetPrs3dFromBase(aBase);
       if(aPrs3d){
-       if(SVTK_ViewWindow* aViewWindow = GetActiveViewWindow<SVTK_ViewWindow>(this)){
-         displayer()->Display(anIO->getEntry());
-         aViewWindow->highlight(anIO, 1);
-         aViewWindow->getRenderer()->ResetCameraClippingRange();
-         aViewWindow->Repaint();
-       }
+        if(SVTK_ViewWindow* aViewWindow = GetActiveViewWindow<SVTK_ViewWindow>(this)){
+          displayer()->Display(anIO->getEntry());
+          aViewWindow->highlight(anIO, 1);
+          aViewWindow->getRenderer()->ResetCameraClippingRange();
+          aViewWindow->Repaint();
+        }
       }
     }
     }
@@ -887,7 +1089,7 @@ VisuGUI
   LightApp_SelectionMgr* aSelectionMgr = GetSelectionMgr(this);
   if (!aSelectionMgr)
     return;
-  
+
   SALOME_ListIO aSel, aList;
   aSelectionMgr->selectedObjects(aSel);
   extractContainers(aSel, aList);
@@ -926,6 +1128,7 @@ void VisuGUI::activateAppropriateViewer( Handle(SALOME_InteractiveObject) theIO
   case VISU::TTABLE: {
     // Activate Plot2d
     GetPlot2dViewer(this, true);
+    break;
   }
   case VISU::TCOLOREDPRS3DHOLDER :
   case VISU::TPOINTMAP3D : {
@@ -941,16 +1144,16 @@ void VisuGUI::activateAppropriateViewer( Handle(SALOME_InteractiveObject) theIO
       aChild = anIter->Value();
       CORBA::Object_var aCORBAObject = VISU::ClientSObjectToObject(aChild);
       if(!CORBA::is_nil(aCORBAObject)){
-       PortableServer::ServantBase_var aServant = VISU::GetServant(aCORBAObject);
-       if( dynamic_cast<VISU::Curve_i*>(aServant.in()))
-         hasCurvesChildren = true;
+        PortableServer::ServantBase_var aServant = VISU::GetServant(aCORBAObject);
+        if( dynamic_cast<VISU::Curve_i*>(aServant.in()))
+          hasCurvesChildren = true;
       }
     }
 
     if (hasCurvesChildren && ( aViewerType == SPlot2d_Viewer::Type() || aViewerType == SVTK_Viewer::Type() ) ) {
       return;
     } else {
-      // activate SVTK Viewer  
+      // activate SVTK Viewer
       getApp()->getViewManager( SVTK_Viewer::Type(), true );
       return;
     }
@@ -991,11 +1194,12 @@ VisuGUI
     vw->unHighlightAll();
     if (vtkRenderer *aRen = vw->getRenderer()) {
       vtkActor *anActor;
-      vtkActorCollection *anActColl = aRen->GetActors();
+      VTK::ActorCollectionCopy aCopy(aRen->GetActors());
+      vtkActorCollection *anActColl = aCopy.GetActors();
       for (anActColl->InitTraversal(); (anActor = anActColl->GetNextActor()) != NULL; ) {
         if (anActor->GetVisibility() > 0)
           if (VISU_Actor* anVISUActor = VISU_Actor::SafeDownCast(anActor)) {
-           RemoveScalarBarPosition(this, vw, anVISUActor->GetPrs3d());
+            RemoveScalarBarPosition(this, vw, anVISUActor->GetPrs3d());
             anVISUActor->VisibilityOff();
           }
       }
@@ -1012,7 +1216,7 @@ namespace
   //----------------------------------------------------------------------------
   VISU::Prs3d_i*
   GetPrsToModify(const SalomeApp_Module* theModule,
-                Handle(SALOME_InteractiveObject)& theIO)
+                 Handle(SALOME_InteractiveObject)& theIO)
   {
     VISU::TSelectionInfo aSelectionInfo = VISU::GetSelectedObjects(theModule);
     if(aSelectionInfo.empty())
@@ -1075,6 +1279,16 @@ VisuGUI
     EditPrs3d<VISU::CutLines_i, VisuGUI_CutLinesDlg, 0>(this, anIO, aPrs3d);
 }
 
+//----------------------------------------------------------------------------
+void
+VisuGUI
+::OnEditCutSegment()
+{
+  Handle(SALOME_InteractiveObject) anIO;
+  if (VISU::Prs3d_i* aPrs3d = GetPrsToModify(this, anIO))
+    EditPrs3d<VISU::CutSegment_i, VisuGUI_CutSegmentDlg, 0>(this, anIO, aPrs3d);
+}
+
 //----------------------------------------------------------------------------
 void
 VisuGUI
@@ -1212,6 +1426,7 @@ VisuGUI
         break;
       case VISU::WIREFRAME :
       case VISU::INSIDEFRAME :
+      case VISU::FEATURE_EDGES :       
         anOldColor = aMesh->GetLinkColor();
         break;
       case VISU::SHADED :
@@ -1244,6 +1459,7 @@ VisuGUI
           break;
         case VISU::SHADED :
         case VISU::SURFACEFRAME :
+        case VISU::FEATURE_EDGES :
           aMesh->SetCellColor(aNewColor);
           break;
       }
@@ -1266,20 +1482,30 @@ VisuGUI
     return;
 
   VISU::Mesh_i* aMesh = dynamic_cast<VISU::Mesh_i*>(aPrs3d);
-  if(!aMesh)
+  VISU::ScalarMap_i* aScalarMap = dynamic_cast<VISU::ScalarMap_i*>(aPrs3d);
+  if(!aMesh && !aScalarMap)
     return;
 
-  SALOMEDS::Color anOldColor = aMesh->GetLinkColor(), aNewColor;
+  SALOMEDS::Color anOldColor, aNewColor;
+  if (aMesh)
+    anOldColor = aMesh->GetLinkColor();
+  else if (aScalarMap)
+    anOldColor = aScalarMap->GetLinkColor();
+
+
   QColor aColor (int(255*anOldColor.R),
-                int(255*anOldColor.G),
-                int(255*anOldColor.B));
+                 int(255*anOldColor.G),
+                 int(255*anOldColor.B));
   QColor aColorNew = QColorDialog::getColor(aColor, GetDesktop(this));
   if (aColorNew.isValid()) {
     aNewColor.R = aColorNew.red()/255.;
     aNewColor.G = aColorNew.green()/255.;
     aNewColor.B = aColorNew.blue()/255.;
-    aMesh->SetLinkColor(aNewColor);
-    RecreateActor(this, aMesh);
+    if (aMesh)
+      aMesh->SetLinkColor(aNewColor);
+    else
+      aScalarMap->SetLinkColor(aNewColor);
+    RecreateActor(this, aPrs3d);
   }
 }
 
@@ -1301,11 +1527,12 @@ VisuGUI
   VISU_ActorBase* anActorBase = NULL;
   VISU::Prs3d_i* aPrs3d = NULL;
   SVTK_ViewWindow* aViewWindow = NULL;
-  float oldlwid;
+  float oldlwid = 1;
   bool isPrs3d = false;
 
   if (GetPrs3dSelectionInfo(this, aPrs3d, aViewWindow, anActor)) {
     isPrs3d = true;
+    oldlwid = anActor->GetLineWidth();
   }
   else {
     aViewWindow = GetActiveViewWindow<SVTK_ViewWindow>(this);
@@ -1320,7 +1547,7 @@ VisuGUI
   VisuGUI_CursorDlg* CursorDlg =
     new VisuGUI_CursorDlg (GetDesktop(this), (const char*)tr("DLG_LINEWIDTH_TITLE").toLatin1(), TRUE);
 
-  CursorDlg->helpFileName = "viewing_3d_presentations_intro_page.html#width_opacity_anchor";
+  CursorDlg->helpFileName = "viewing_3d_presentations_page.html#width_opacity_anchor";
   CursorDlg->Comment1->setText(tr("DLG_LINEWIDTH_CMT1"));
   CursorDlg->Comment2->setText(tr("DLG_LINEWIDTH_CMT2"));
   CursorDlg->SpinBox1->setMinimum(1);
@@ -1341,6 +1568,83 @@ VisuGUI
   delete CursorDlg;
 }
 
+//----------------------------------------------------------------------------
+void
+VisuGUI
+::OnChangePointMarker()
+{
+  SALOME_ListIO aListIO;
+  GetSelectionMgr( this )->selectedObjects( aListIO );
+  if( aListIO.Extent() < 1 )
+    return;
+
+  VISU::StudyId2MarkerMap& aMarkerMap = GetVisuGen( this )->GetMarkerMap();
+  _PTR(Study) aCStudy = GetCStudy( GetAppStudy( this ) );
+  int aStudyId = aCStudy->StudyId();
+
+  QPixmap aPointSpritePixmap;
+  if( SUIT_ResourceMgr* aResourceMgr = VISU::GetResourceMgr() )
+    aPointSpritePixmap = aResourceMgr->loadPixmap( "VISU", tr( "ICON_POINT_SPRITE" ) );
+
+  bool update = false;
+  for( SALOME_ListIteratorOfListIO It( aListIO ); It.More(); It.Next() )
+  {
+    Handle(SALOME_InteractiveObject)& anIO = It.Value();
+    std::vector<VISU::Prs3d_i*> aPrsList = GetPrs3dList( this, anIO );
+    for( int i = 0, n = aPrsList.size(); i < n; i++ )
+    {
+      if( VISU::Prs3d_i* aPrs = aPrsList[i] )
+      {
+        VTKViewer_MarkerDlg* aDlg = new VTKViewer_MarkerDlg( GetDesktop( this ) );
+        aDlg->setHelpData( "VISU", "point_marker_page.html" );
+
+        aDlg->setCustomMarkerMap( aMarkerMap[ aStudyId ] );
+
+        aDlg->addExtraStdMarker( VTK::MT_POINT_SPRITE, aPointSpritePixmap );
+
+        VISU::MarkerType aMarkerTypeCurrent = aPrs->GetMarkerType();
+        VISU::MarkerScale aMarkerScaleCurrent = aPrs->GetMarkerScale();
+        int aMarkerTextureCurrent = aPrs->GetMarkerTexture();
+        if( aMarkerTypeCurrent != VISU::MT_USER )
+          aDlg->setStandardMarker( (VTK::MarkerType)aMarkerTypeCurrent, (VTK::MarkerScale)aMarkerScaleCurrent );
+        else
+          aDlg->setCustomMarker( aMarkerTextureCurrent );
+
+        if( aDlg->exec() )
+        {
+          aMarkerMap[ aStudyId ] = aDlg->getCustomMarkerMap();
+
+          VISU::MarkerType aMarkerTypeNew = (VISU::MarkerType)aDlg->getMarkerType();
+          VISU::MarkerScale aMarkerScaleNew = (VISU::MarkerScale)aDlg->getStandardMarkerScale();
+          int aMarkerTextureNew = aDlg->getCustomMarkerID();
+          if( aMarkerTypeNew != VISU::MT_USER )
+            aPrs->SetMarkerStd( aMarkerTypeNew, aMarkerScaleNew );
+          else
+            aPrs->SetMarkerTexture( aMarkerTextureNew );
+
+          aPrs->UpdateActors();
+          update = true;
+        }
+
+        delete aDlg;
+      }
+    }
+  }
+
+  if( update )
+    if( SVTK_ViewWindow* vw = GetActiveViewWindow<SVTK_ViewWindow>( this ) )
+      vw->Repaint();
+}
+
+//----------------------------------------------------------------------------
+void
+VisuGUI
+::OnChangeShrinkFactor()
+{
+  VisuGUI_ShrinkFactorDlg* aDialog = new VisuGUI_ShrinkFactorDlg( this );
+  aDialog->show();
+}
+
 //----------------------------------------------------------------------------
 void
 VisuGUI
@@ -1354,19 +1658,19 @@ VisuGUI
   Handle(SALOME_InteractiveObject) anIO = aSelectionItem.myIO;
   VISU::Base_i* aBase = aSelectionItem.myObjectInfo.myBase;
   _PTR(SObject) aSObject = aSelectionItem.myObjectInfo.mySObject;
-  if(VISU::Table_i* aTable = dynamic_cast<VISU::Table_i*>(aBase))
+  if(VISU::Table_i* aTable = dynamic_cast<VISU::Table_i*>(aBase)) {
     aSObject = GetCStudy( GetAppStudy( this ) )->FindObjectID( aTable->GetObjectEntry() );
-
-  if( !IsSObjectTable( aSObject ) )
-    return;
-
-  VisuGUI_TableDlg* dlg = new VisuGUI_TableDlg( GetDesktop( this ),
-                                               aSObject,
-                                               false,
-                                               //SAL2670 Orientation of show tables
-                                               VisuGUI_TableDlg::ttAuto,
-                                               Qt::Vertical );
-  dlg->show();
+    if( IsSObjectTable( aSObject ) ) {
+      VISU_TableDlg* dlg = new VISU_TableDlg( GetDesktop( this ),
+                                              GetCStudy( GetAppStudy( this ) ),
+                                              aTable,
+                                              false,
+                                              //SAL2670 Orientation of show tables
+                                              VISU_TableDlg::ttAuto,
+                                              Qt::Vertical );
+      dlg->show();
+    }
+  }
 }
 
 //----------------------------------------------------------------------------
@@ -1412,7 +1716,6 @@ void
 VisuGUI
 ::SetScalarBarVisibility(bool theVisibility)
 {
-  printf ("\nOnHideScalarBar");
   LightApp_SelectionMgr* aSelectionMgr = GetSelectionMgr(this);
   SALOME_ListIO aListIO;
   aSelectionMgr->selectedObjects(aListIO);
@@ -1422,16 +1725,19 @@ VisuGUI
   bool update = false;
   for (; It.More(); It.Next()) {
     Handle(SALOME_InteractiveObject)& anIO = It.Value();
-    std::vector<VISU::Prs3d_i*> aPrsList = GetPrs3dList(this, anIO);
-    if (!aPrsList.empty()) {
+    std::vector<VISU::Prs3d_i*> aPrsList = GetPrs3dList(this, anIO, true);
+    if ( aPrsList.size()>0 ) {
       for (int i = 0, n = aPrsList.size(); i < n; i++) {
         VISU::Prs3d_i* aPrsObject = aPrsList[i];
         if (aPrsObject) {
-          VISU::ScalarMap_i* aScalar = dynamic_cast<VISU::ScalarMap_i*>(aPrsObject);
-          if (aScalar) {
+          if (VISU::ScalarMap_i* aScalar = dynamic_cast<VISU::ScalarMap_i*>(aPrsObject)) {
             aScalar->SetBarVisible( theVisibility );
             RecreateActor(this, aScalar);
             update = true;
+          } else if (VISU::GaussPoints_i* aGauss = dynamic_cast<VISU::GaussPoints_i*>(aPrsObject)) {
+            aGauss->SetBarVisible( theVisibility );
+            RecreateActor(this, aGauss);
+            update = true;
           }
         }
       }
@@ -1456,7 +1762,9 @@ VisuGUI
   _PTR(SObject) aSObject = aSelectionItem.myObjectInfo.mySObject;
   VISU::Base_i* aBase = aSelectionItem.myObjectInfo.myBase;
 
-  if((aBase && aBase->GetType() == VISU::TCUTLINES) || IsSObjectTable(aSObject)) {
+  if(aBase &&
+     (aBase->GetType() == VISU::TCUTLINES || aBase->GetType() == VISU::TCUTSEGMENT) ||
+     IsSObjectTable(aSObject)) {
     GetVisuGen( this )->CreateTable( aSObject->GetID().c_str() );
     UpdateObjBrowser(this);
   }
@@ -1485,34 +1793,34 @@ VisuGUI
     anIO = it.Value();
     if (anIO->hasEntry()) {
       if (IsRemovable(anIO->getEntry(), this)) {
-       aNameList.append("\n    - ");
-       // Get Name Of the Main Object if it's a referenced object
-       VISU::TObjectInfo anObjectInfo = GetObjectByEntry(GetAppStudy(this), anIO->getEntry());
-       if(_PTR(SObject) aSObject = anObjectInfo.mySObject){
-         _PTR(SObject) aRefSObject;
-         if (aSObject->ReferencedObject(aRefSObject)) {
-           QString aRefName = QString::fromStdString ( aRefSObject->GetName() );
-           aNameList.append( aRefName );
-         }
-         else
-           aNameList.append(anIO->getName());
-       }
-       anEntries[i++] = anIO->getEntry();
+        aNameList.append("\n    - ");
+        // Get Name Of the Main Object if it's a referenced object
+        VISU::TObjectInfo anObjectInfo = GetObjectByEntry(GetAppStudy(this), anIO->getEntry());
+        if(_PTR(SObject) aSObject = anObjectInfo.mySObject){
+          _PTR(SObject) aRefSObject;
+          if (aSObject->ReferencedObject(aRefSObject)) {
+            QString aRefName = QString::fromStdString ( aRefSObject->GetName() );
+            aNameList.append( aRefName );
+          }
+          else
+            aNameList.append(anIO->getName());
+        }
+        anEntries[i++] = anIO->getEntry();
       }
     }
   }
   nbSelected = i;
   if (nbSelected < 1) {
     SUIT_MessageBox::warning(GetDesktop(this),
-                            QObject::tr("WRN_VISU"),
-                            QObject::tr("WRN_NO_APPROPRIATE_SELECTION"));
+                             QObject::tr("WRN_VISU"),
+                             QObject::tr("WRN_NO_APPROPRIATE_SELECTION"));
     return;
   }
 
   if ( SUIT_MessageBox::question( GetDesktop(this),
-                                 QObject::tr( "WRN_VISU" ),
-                                 QObject::tr( "VISU_REALLY_DELETE" ).arg( nbSelected ).arg( aNameList ),
-                                 SUIT_MessageBox::Yes | SUIT_MessageBox::No ) != SUIT_MessageBox::Yes )
+                                  QObject::tr( "WRN_VISU" ),
+                                  QObject::tr( "VISU_REALLY_DELETE" ).arg( nbSelected ).arg( aNameList ),
+                                  SUIT_MessageBox::Yes | SUIT_MessageBox::No ) != SUIT_MessageBox::Yes )
     return;
 
   // There is a transaction
@@ -1525,32 +1833,32 @@ VisuGUI
       emit beforeObjectDelete(QString(aSObject->GetID().c_str()));
       _PTR(SObject) aRefSObject;
       if (aSObject->ReferencedObject(aRefSObject)) {
-       // It can be a reference on curve, published under a container.
-       // In this case the curve should be removed from the container.
-       // See bug 10441.
-       VISU::TObjectInfo aRefObjectInfo = GetObjectByEntry(GetAppStudy(this), aRefSObject->GetID());
-       VISU::Base_i* aRefBase = aRefObjectInfo.myBase;
-       if(aRefBase && aRefBase->GetType() == VISU::TMESH){
-         DeleteSObject(this, aCStudy, aRefSObject);
-         UpdateObjBrowser(this, true, aRefSObject);
-       }else if(aRefBase && aRefBase->GetType() == VISU::TCURVE){
-         CORBA::Object_var anObject = ClientSObjectToObject(aRefSObject);
-         VISU::Curve_var aCurve = VISU::Curve::_narrow(anObject);
-         _PTR(SObject) aParentSO = aSObject->GetFather();
-         VISU::TObjectInfo aParentObjectInfo = GetObjectByEntry(GetAppStudy(this), aParentSO->GetID());
-         if(VISU::Base_i* aParentBase = aParentObjectInfo.myBase){
-           if(VISU::Container_i* aContainer = dynamic_cast<VISU::Container_i*>(aParentBase)){
-             if(aContainer->GetNbCurves() > 0){
-               aContainer->RemoveCurve(aCurve);
-               UpdateObjBrowser(this, true, aParentSO);
-             }
-           }
-         }
-       }
+        // It can be a reference on curve, published under a container.
+        // In this case the curve should be removed from the container.
+        // See bug 10441.
+        VISU::TObjectInfo aRefObjectInfo = GetObjectByEntry(GetAppStudy(this), aRefSObject->GetID());
+        VISU::Base_i* aRefBase = aRefObjectInfo.myBase;
+        if(aRefBase && aRefBase->GetType() == VISU::TMESH){
+          DeleteSObject(this, aCStudy, aRefSObject);
+          UpdateObjBrowser(this, true, aRefSObject);
+        }else if(aRefBase && aRefBase->GetType() == VISU::TCURVE){
+          CORBA::Object_var anObject = ClientSObjectToObject(aRefSObject);
+          VISU::Curve_var aCurve = VISU::Curve::_narrow(anObject);
+          _PTR(SObject) aParentSO = aSObject->GetFather();
+          VISU::TObjectInfo aParentObjectInfo = GetObjectByEntry(GetAppStudy(this), aParentSO->GetID());
+          if(VISU::Base_i* aParentBase = aParentObjectInfo.myBase){
+            if(VISU::Container_i* aContainer = dynamic_cast<VISU::Container_i*>(aParentBase)){
+              if(aContainer->GetNbCurves() > 0){
+                aContainer->RemoveCurve(aCurve);
+                UpdateObjBrowser(this, true, aParentSO);
+              }
+            }
+          }
+        }
       }
       else{
-       DeleteSObject(this, aCStudy, aSObject);
-       UpdateObjBrowser(this, true, aSObject);
+        DeleteSObject(this, aCStudy, aSObject);
+        UpdateObjBrowser(this, true, aSObject);
       }
     }
   }
@@ -1573,118 +1881,125 @@ VisuGUI
   if(VISU::Base_i* aBase = aSelectionItem.myObjectInfo.myBase){
     if(aBase->GetType() == VISU::TTABLE || aBase->GetType() == VISU::TPOINTMAP3D) {
       if(VISU::Table_i* aTable = dynamic_cast<VISU::Table_i*>(aBase)){
-       _PTR(Study) aStudy = GetCStudy(GetAppStudy(this));
-       _PTR(SObject) aSObject = aStudy->FindObjectID( aTable->GetObjectEntry() );
-       if(IsSObjectTable(aSObject)){
-         VisuGUI_SetupPlot2dDlg* aDlg = new VisuGUI_SetupPlot2dDlg(aSObject, GetDesktop(this));
-         if(aDlg->exec() == QDialog::Accepted){
-           if(!IsStudyLocked(aStudy)){
-             // if study is not locked - create new container, create curves and insert them
-             // into container, then plot container if current viewer is of VIEW_PLOT2D type
-             int horIndex;
-             QList<int> verIndices, zIndices;
-             aDlg->getCurvesSource( horIndex, verIndices, zIndices );
-             if( horIndex >= 0 && verIndices.count() > 0 ){
-               CORBA::Object_var aContainerObj = GetVisuGen(this)->CreateContainer();
-               if(VISU::Container_i* aContainer = dynamic_cast<VISU::Container_i*>(VISU::GetServant(aContainerObj).in())){
-                 for( int i = 0; i < verIndices.count(); i++ ){
-                   VISU::Curve_var aCurveObject =
-                     GetVisuGen(this)->CreateCurveWithZ(aTable->_this(), horIndex+1, verIndices[i]+1, zIndices[i]+1 );
-                   if(VISU::Curve_i* aCurve = dynamic_cast<VISU::Curve_i*>(VISU::GetServant(aCurveObject).in())){
-                     bool isAuto;
-                     int  marker, line, lineWidth;
-                     QColor color;
-                     if ( aDlg->getCurveAttributes(verIndices[i], isAuto, marker,
-                                                   line, lineWidth, color) && !isAuto )
-                     {
-                       SALOMEDS::Color c;
-                       c.R = color.red()  /255.;
-                       c.G = color.green()/255.;
-                       c.B = color.blue() /255.;
-                       aCurve->SetColor( c );
-                       aCurve->SetMarker( ( VISU::Curve::MarkerType )marker );
-                       aCurve->SetLine( ( VISU::Curve::LineType )line, lineWidth );
-                     }
-                     aContainer->AddCurve(aCurveObject);
-                   }
-                 }
-                 UpdateObjBrowser(this);
-                 PlotContainer( this, aContainer, VISU::eDisplay );
-               }
-             }
-           } else {
-             // get name of SObject
-             QString aSObjectName;
-             _PTR(GenericAttribute) anAttr;
-             if(aSObject->FindAttribute( anAttr, "AttributeName" )){
-               _PTR(AttributeName) aName = anAttr;
-               aSObjectName = QString( aName->Value().c_str() );
-             }
-             // if study is locked just get curves info and plot them
-             // if current viewer is of VIEW_PLOT2D type
-             QList<Plot2d_Curve*> container;
-             aDlg->getCurves( container );
-             if ( !container.isEmpty() ) {
-               GetPlot2dViewer( this )->getActiveViewFrame()->displayCurves( container, true );
-               GetPlot2dViewer( this )->getActiveViewFrame()->setTitle( aSObjectName );
-             }
-           }
-         }
-         delete aDlg;
-       }
+        _PTR(Study) aStudy = GetCStudy(GetAppStudy(this));
+        _PTR(SObject) aSObject = aStudy->FindObjectID( aTable->GetObjectEntry() );
+        if(IsSObjectTable(aSObject)){
+          VisuGUI_SetupPlot2dDlg* aDlg = new VisuGUI_SetupPlot2dDlg(aSObject, aTable ,GetDesktop(this));
+          if(aDlg->exec() == QDialog::Accepted){
+            if(!IsStudyLocked(aStudy)){
+              // if study is not locked - create new container, create curves and insert them
+              // into container, then plot container if current viewer is of VIEW_PLOT2D type
+              int horIndex;
+              QList<int> verIndices, ver1Indices, ver2Indices, zIndices;
+              aDlg->getCurvesSource( horIndex, ver1Indices, ver2Indices, zIndices );
+              verIndices = ver1Indices + ver2Indices;
+              if( horIndex >= 0 && verIndices.count() > 0 ){
+                CORBA::Object_var aContainerObj = GetVisuGen(this)->CreateContainer();
+                if(VISU::Container_i* aContainer = dynamic_cast<VISU::Container_i*>(VISU::GetServant(aContainerObj).in())){
+                  for( int i = 0; i < verIndices.count(); i++ ){
+                    bool isV2 = ver2Indices.contains(verIndices[i]);
+                    VISU::Curve_var aCurveObject =
+                      GetVisuGen(this)->CreateCurveWithZExt(aTable->_this(), 
+                                                            aDlg->idx(horIndex)+1, 
+                                                            aDlg->idx(verIndices[i])+1, 
+                                                            aDlg->idx(zIndices[i])+1, isV2 );
+                    if(VISU::Curve_i* aCurve = dynamic_cast<VISU::Curve_i*>(VISU::GetServant(aCurveObject).in())){
+                      bool isAuto;
+                      int  marker, line, lineWidth;
+                      QColor color;
+                      if ( aDlg->getCurveAttributes(verIndices[i], isAuto, marker,
+                                                    line, lineWidth, color) && !isAuto )
+                      {
+                        SALOMEDS::Color c;
+                        c.R = color.red()  /255.;
+                        c.G = color.green()/255.;
+                        c.B = color.blue() /255.;
+                        aCurve->SetColor( c );
+                        aCurve->SetMarker( ( VISU::Curve::MarkerType )marker );
+                        aCurve->SetLine( ( VISU::Curve::LineType )line, lineWidth );
+                      }
+                      aContainer->AddCurve(aCurveObject);
+                    }
+                  }
+                  UpdateObjBrowser(this);
+                  PlotContainer( this, aContainer, VISU::eDisplay );
+                }
+              }
+            } else {
+              // get name of SObject
+              QString aSObjectName;
+              _PTR(GenericAttribute) anAttr;
+              if(aSObject->FindAttribute( anAttr, "AttributeName" )){
+                _PTR(AttributeName) aName = anAttr;
+                aSObjectName = QString( aName->Value().c_str() );
+              }
+              // if study is locked just get curves info and plot them
+              // if current viewer is of VIEW_PLOT2D type
+              QList<Plot2d_Curve*> container;
+              aDlg->getCurves( container );
+              if ( !container.isEmpty() ) {
+                GetPlot2dViewer( this )->getActiveViewFrame()->displayCurves( container, true );
+                GetPlot2dViewer( this )->getActiveViewFrame()->setTitle( aSObjectName );
+              }
+            }
+          }
+          delete aDlg;
+        }
       }
     }
   }else if(!aSelectionItem.myIO.IsNull()){
     // check if Table SObject is selected
     _PTR(SObject) aSObject = aSelectionItem.myObjectInfo.mySObject;
     if(IsSObjectTable(aSObject)){
-      VisuGUI_SetupPlot2dDlg* aDlg = new VisuGUI_SetupPlot2dDlg(aSObject, GetDesktop(this));
+      VisuGUI_SetupPlot2dDlg* aDlg = new VisuGUI_SetupPlot2dDlg(aSObject, NULL, GetDesktop(this));
       if(aDlg->exec() == QDialog::Accepted){
-       _PTR(Study) aStudy = GetCStudy(GetAppStudy(this));
+        _PTR(Study) aStudy = GetCStudy(GetAppStudy(this));
         if(!IsStudyLocked(aStudy)){
           // if study is not locked - create new table and container objects, create curves
           // and insert them into container, then plot container if current viewer is of VIEW_PLOT2D type
           int horIndex;
-          QList<int> verIndices, zIndices;
-          aDlg->getCurvesSource( horIndex, verIndices, zIndices );
+          QList<int> verIndices, ver1Indices, ver2Indices, zIndices;
+          aDlg->getCurvesSource( horIndex, verIndices, ver2Indices, zIndices );
+          verIndices = ver1Indices + ver2Indices;
           if ( horIndex >= 0 && verIndices.count() > 0 ) {
             VISU::Table_var aTableObject = GetVisuGen(this)->CreateTable(aSObject->GetID().c_str());
             if(!CORBA::is_nil(aTableObject)){
-             VISU::Container_var aContainerObject = GetVisuGen(this)->CreateContainer();
+              VISU::Container_var aContainerObject = GetVisuGen(this)->CreateContainer();
               VISU::Container_i* aContainer = dynamic_cast<VISU::Container_i*>(VISU::GetServant(aContainerObject).in());
-             for ( int i = 0; i < verIndices.count(); i++ ) {
-               VISU::Curve_var aCurveObject = GetVisuGen(this)->CreateCurveWithZ
-                 ( aTableObject, horIndex+1, verIndices[i]+1, zIndices[i]+1 );
-               if(VISU::Curve_i* aCurve = dynamic_cast<VISU::Curve_i*>(VISU::GetServant(aCurveObject).in())){
-                 bool isAuto;
-                 int  marker, line, lineWidth;
-                 QColor color;
-                 if ( aDlg->getCurveAttributes(verIndices[i], isAuto, marker,
-                                               line, lineWidth, color) && !isAuto )
-                 {
-                   SALOMEDS::Color c;
-                   c.R = color.red()/255.;
-                   c.G = color.green()/255.;
-                   c.B = color.blue()/255.;
-                   aCurve->SetColor( c );
-                   aCurve->SetMarker( ( VISU::Curve::MarkerType )marker );
-                   aCurve->SetLine( ( VISU::Curve::LineType )line, lineWidth );
-                 }
-                 aContainerObject->AddCurve(aCurveObject);
-               }
-             }
-             UpdateObjBrowser(this);
-             PlotContainer( this, aContainer, VISU::eDisplay );
-           }
-         }
+              for ( int i = 0; i < verIndices.count(); i++ ) {
+                bool isV2 = ver2Indices.contains(verIndices[i]);
+                VISU::Curve_var aCurveObject = GetVisuGen(this)->CreateCurveWithZExt
+                  ( aTableObject, horIndex+1, verIndices[i]+1, zIndices[i]+1, isV2 );
+                if(VISU::Curve_i* aCurve = dynamic_cast<VISU::Curve_i*>(VISU::GetServant(aCurveObject).in())){
+                  bool isAuto;
+                  int  marker, line, lineWidth;
+                  QColor color;
+                  if ( aDlg->getCurveAttributes(verIndices[i], isAuto, marker,
+                                                line, lineWidth, color) && !isAuto )
+                  {
+                    SALOMEDS::Color c;
+                    c.R = color.red()/255.;
+                    c.G = color.green()/255.;
+                    c.B = color.blue()/255.;
+                    aCurve->SetColor( c );
+                    aCurve->SetMarker( ( VISU::Curve::MarkerType )marker );
+                    aCurve->SetLine( ( VISU::Curve::LineType )line, lineWidth );
+                  }
+                  aContainerObject->AddCurve(aCurveObject);
+                }
+              }
+              UpdateObjBrowser(this);
+              PlotContainer( this, aContainer, VISU::eDisplay );
+            }
+          }
         } else {
-         // get name of SObject
-         QString aSObjectName;
-         _PTR(GenericAttribute) anAttr;
-         if(aSObject->FindAttribute(anAttr, "AttributeName")){
-           _PTR(AttributeName) aName = anAttr;
-           aSObjectName = QString( aName->Value().c_str() );
-         }
+          // get name of SObject
+          QString aSObjectName;
+          _PTR(GenericAttribute) anAttr;
+          if(aSObject->FindAttribute(anAttr, "AttributeName")){
+            _PTR(AttributeName) aName = anAttr;
+            aSObjectName = QString( aName->Value().c_str() );
+          }
           // if study is locked just get curves info and plot them
           QList<Plot2d_Curve*> container;
           aDlg->getCurves( container );
@@ -1739,6 +2054,44 @@ VisuGUI
   }
 }
 
+//----------------------------------------------------------------------------
+void
+VisuGUI
+::OnCurveScale()
+{
+  if(IsStudyLocked(GetCStudy(GetAppStudy(this))))
+    return;
+
+  VISU::TSelectionInfo aSelectionInfo = VISU::GetSelectedObjects( this );
+  int nbSel = aSelectionInfo.size();
+  QList<VISU::Curve_i*> curList;
+  bool isValuesEquals = true;                  
+  double value;
+
+  for (int i = 0; i < nbSel; i++ ) {
+    VISU::TSelectionItem aSelectionItem = aSelectionInfo[i];
+    VISU::Base_i* aBase = aSelectionItem.myObjectInfo.myBase;
+    if(!aBase)
+      continue;
+
+    if(aBase->GetType() == VISU::TCURVE) 
+      // Curve object
+      if(VISU::Curve_i* aCurve = dynamic_cast<VISU::Curve_i*>(aBase)) {
+        curList.append(aCurve);
+        if( i>0 && isValuesEquals )
+          isValuesEquals = (value == aCurve->GetScale());
+         value = aCurve->GetScale();
+      }
+  }
+
+  Plot2d_SetupCurveScaleDlg aDlg(GetDesktop( this ));
+  if( isValuesEquals )
+     aDlg.setScale(value);
+
+  if( aDlg.exec() == QDialog::Accepted )
+       for ( int i = 0; i < curList.size(); ++i )
+         curList.at(i)->SetScale( aDlg.getScale() );
+}
 //----------------------------------------------------------------------------
 void
 VisuGUI
@@ -1762,6 +2115,7 @@ VisuGUI
     if(VISU::Container_i* aContainer = dynamic_cast<VISU::Container_i*>(aBase)){
       if(aContainer && aContainer->GetNbCurves() > 0){
         aContainer->Clear();
+       VISU::updateContainerVisibility(aContainer);
         UpdateObjBrowser(this);
       }
     }
@@ -1791,8 +2145,9 @@ VisuGUI
   if (aDlg->exec()) {
     aDlg->storeToPrsObject(aContainer);
     UpdateObjBrowser(this, true);
+    delete aDlg;
+    VISU::updateContainerVisibility(aContainer);
   }
-  delete aDlg;
 }
 
 //----------------------------------------------------------------------------
@@ -1846,109 +2201,6 @@ VisuGUI
     VISU::View3D_i::RestoreViewParams(aViewMgr, aSObj->GetName().c_str());//jfa tmp
 }
 
-//----------------------------------------------------------------------------
-void
-VisuGUI
-::OnRename()
-{
-  _PTR(Study) aCStudy = GetCStudy(GetAppStudy(this));
-  if (CheckLock(aCStudy,GetDesktop(this)))
-    return;
-
-  VISU::TSelectionInfo aSelectionInfo = VISU::GetSelectedObjects(this);
-  if (aSelectionInfo.empty())
-    return;
-
-  VisuGUI_Selection aSel (this);
-  aSel.init("", getApp()->selectionMgr());
-  if (aSel.count() < 1) return;
-
-  bool isAny = false; // is there any appropriate object selected
-  for (int i = 0; i < aSelectionInfo.size(); i++) {
-    VISU::TSelectionItem aSelectionItem = aSelectionInfo[i];
-    VISU::TObjectInfo anObjectInfo = aSelectionItem.myObjectInfo;
-
-    _PTR(SObject) aSObject = anObjectInfo.mySObject;
-    if (!aSObject)
-      continue;
-
-    // Check, if the selected object can be renamed
-    QString aStr = aSel.parameter(i, "type" ).toString();
-    if (aStr == "VISU::TSCALARMAP" || aStr == "VISU::TISOSURFACES" ||
-        aStr == "VISU::TDEFORMEDSHAPE" || aStr == "VISU::TCUTPLANES" ||
-        aStr == "VISU::TCUTLINES" || aStr == "VISU::TVECTORS" ||
-        aStr == "VISU::TSTREAMLINES" || aStr == "VISU::TPLOT3D" ||
-        aStr == "VISU::TSCALARMAPONDEFORMEDSHAPE" || aStr == "VISU::TCOLOREDPRS3DHOLDER" ||
-        aStr == "VISU::TTABLE" || aStr == "VISU::TCURVE" || aStr == "VISU::TCONTAINER" ||
-        aStr == "VISU::POINTMAP3D" || aStr == "VISU::TVIEW3D" ||
-        aStr == "VISU::TMESH" || aStr == "VISU::TPOINTMAP3D" || aStr == "VISU::TGAUSSPOINTS")
-    {
-      _PTR(GenericAttribute) anAttr;
-      if (aSObject->FindAttribute(anAttr, "AttributeName")) {
-        isAny = true;
-        _PTR(AttributeName) aName (anAttr);
-        QString Name = VisuGUI_NameDlg::getName( GetDesktop( this ), aName->Value().c_str() );
-        if (!Name.isEmpty()) {
-          QApplication::setOverrideCursor(Qt::WaitCursor);
-
-          // rename specific objects
-          if (VISU::Base_i* aBase = anObjectInfo.myBase) {
-            switch (aBase->GetType()) {
-            case VISU::TCURVE: { // Curve object
-              if (VISU::Curve_i* aCurve = dynamic_cast<VISU::Curve_i*>(aBase))
-                aCurve->SetName(Name.toLatin1().constData(), true);
-              break;
-            }
-            case VISU::TTABLE: { // Table object
-              if (VISU::Table_i* aTable = dynamic_cast<VISU::Table_i*>(aBase))
-                aTable->SetName(Name.toLatin1().constData(), true);
-              break;
-            }
-            case VISU::TPOINTMAP3D: { // Table object
-              if (VISU::PointMap3d_i* aTable3d = dynamic_cast<VISU::PointMap3d_i*>(aBase)) {
-                aTable3d->SetTitle(Name.toLatin1().constData());
-                aTable3d->UpdateActors();
-              }
-              break;
-            }
-            case VISU::TCONTAINER: { // Container object
-              if (VISU::Container_i* aContainer = dynamic_cast<VISU::Container_i*>(aBase))
-                aContainer->SetName(Name.toLatin1().constData(), true);
-              break;
-            }
-            default: {
-            }}
-          }
-
-          // rename the study object
-          Handle(SALOME_InteractiveObject) anIO = aSelectionItem.myIO;
-          aName->SetValue(Name.toLatin1().constData()); // rename the SObject
-          anIO->setName(Name.toLatin1().constData()); // rename the InteractiveObject
-
-          ViewManagerList aViewManagerList;
-          getApp()->viewManagers(SPlot2d_Viewer::Type(), aViewManagerList);
-          SUIT_ViewManager* aViewManager;
-         foreach( aViewManager, aViewManagerList ) {
-            if (Plot2d_ViewManager* aManager = dynamic_cast<Plot2d_ViewManager*>(aViewManager)) {
-              if (SPlot2d_Viewer* aViewer = dynamic_cast<SPlot2d_Viewer*>(aManager->getViewModel()))
-                aViewer->renameAll( anIO, Name.toLatin1().constData() );
-            }
-          }
-
-          UpdateObjBrowser(this, false);
-          QApplication::restoreOverrideCursor();
-        }
-      }
-    }
-  } // for
-
-  if (!isAny) {
-    SUIT_MessageBox::warning(GetDesktop(this),
-                            QObject::tr("WRN_VISU"),
-                            QObject::tr("WRN_NO_APPROPRIATE_SELECTION"));
-  }
-}
-
 //----------------------------------------------------------------------------
 void
 VisuGUI
@@ -2012,40 +2264,96 @@ void
 VisuGUI::
 OnSucccessiveTimeAnimation()
 {
-  OnTimeAnimation(VISU::Animation::SUCCESSIVE);
+  OnTimeAnimation(VISU::Animation::SUCCESSIVE);
+}
+
+//----------------------------------------------------------------------------
+void
+VisuGUI
+::OnShowAnimation()
+{
+  if (!VISU::GetActiveViewWindow<SVTK_ViewWindow>(this))
+    return;
+
+  LightApp_SelectionMgr* aSelectionMgr = GetSelectionMgr(this);
+  SALOME_ListIO aListIO;
+  aSelectionMgr->selectedObjects(aListIO);
+
+  if (aListIO.Extent() != 1)
+    return;
+
+  const Handle(SALOME_InteractiveObject)& anIO = aListIO.First();
+
+  _PTR(Study) aCStudy = GetCStudy(GetAppStudy(this));
+
+  _PTR(SObject) aSObj = aCStudy->FindObjectID(anIO->getEntry());
+  if (!aSObj)
+    return;
+
+  VISU::VISUType aType = VISU::Storable::SObject2Type( aSObj );
+  if (aType != VISU::TANIMATION)
+    return;
+
+  VisuGUI_TimeAnimationDlg* aAnimationDlg =
+    new VisuGUI_TimeAnimationDlg(this, aCStudy);
+  aAnimationDlg->restoreFromStudy(aSObj);
+  aAnimationDlg->show();
+}
+
+//----------------------------------------------------------------------------
+void
+VisuGUI
+::OnPointEvolution()
+{
+  _PTR(Study) aCStudy = GetCStudy( GetAppStudy( this ) );
+  VisuGUI_EvolutionDlg* aDlg = new VisuGUI_EvolutionDlg( this, aCStudy );
+
+  LightApp_SelectionMgr* aSelectionMgr = GetSelectionMgr( this );
+  SALOME_ListIO aListIO;
+  aSelectionMgr->selectedObjects( aListIO );
+
+  SALOME_ListIteratorOfListIO It( aListIO );
+  for( ; It.More(); It.Next() )
+  {
+    _PTR(SObject) aSObject = aCStudy->FindObjectID( It.Value()->getEntry() );
+    if( !aDlg->setField( aSObject ) )
+    {
+      SUIT_MessageBox::warning( GetDesktop( this ),
+                                tr( "WRN_VISU" ),
+                                tr( "ERR_CANT_CREATE_EVOLUTION" ) );
+      delete aDlg;
+      return;
+    }
+  }
+  aDlg->show();
 }
 
 //----------------------------------------------------------------------------
 void
 VisuGUI
-::OnShowAnimation()
+::OnShowEvolution()
 {
-  if (!VISU::GetActiveViewWindow<SVTK_ViewWindow>(this))
-    return;
-
-  LightApp_SelectionMgr* aSelectionMgr = GetSelectionMgr(this);
+  LightApp_SelectionMgr* aSelectionMgr = GetSelectionMgr( this );
   SALOME_ListIO aListIO;
-  aSelectionMgr->selectedObjects(aListIO);
+  aSelectionMgr->selectedObjects( aListIO );
 
-  if (aListIO.Extent() != 1)
+  if( aListIO.Extent() != 1 )
     return;
 
   const Handle(SALOME_InteractiveObject)& anIO = aListIO.First();
 
-  _PTR(Study) aCStudy = GetCStudy(GetAppStudy(this));
-
-  _PTR(SObject) aSObj = aCStudy->FindObjectID(anIO->getEntry());
-  if (!aSObj)
+  _PTR(Study) aCStudy = GetCStudy( GetAppStudy( this ) );
+  _PTR(SObject) aSObj = aCStudy->FindObjectID( anIO->getEntry() );
+  if( !aSObj )
     return;
 
   VISU::VISUType aType = VISU::Storable::SObject2Type( aSObj );
-  if (aType != VISU::TANIMATION)
+  if( aType != VISU::TEVOLUTION )
     return;
 
-  VisuGUI_TimeAnimationDlg* aAnimationDlg =
-    new VisuGUI_TimeAnimationDlg(this, aCStudy);
-  aAnimationDlg->restoreFromStudy(aSObj);
-  aAnimationDlg->show();
+  VisuGUI_EvolutionDlg* aDlg = new VisuGUI_EvolutionDlg( this, aCStudy );
+  aDlg->restoreFromStudy( aSObj );
+  aDlg->show();
 }
 
 //----------------------------------------------------------------------------
@@ -2089,6 +2397,9 @@ VisuGUI
     case VISU::TCUTLINES:
       TSameAsFactory<VISU::TCUTLINES>().Create(aColoredPrs3d, ColoredPrs3d_i::EPublishUnderTimeStamp, false);
       break;
+    case VISU::TCUTSEGMENT:
+      TSameAsFactory<VISU::TCUTSEGMENT>().Create(aColoredPrs3d, ColoredPrs3d_i::EPublishUnderTimeStamp, false);
+      break;
     case VISU::TISOSURFACES:
       TSameAsFactory<VISU::TISOSURFACES>().Create(aColoredPrs3d, ColoredPrs3d_i::EPublishUnderTimeStamp, false);
       break;
@@ -2116,12 +2427,12 @@ VisuGUI
     if( myPanels.find( SelectionPanelId ) != myPanels.end() )
     {
       if( VisuGUI_SelectionPanel* aSelectionPanel =
-         dynamic_cast<VisuGUI_SelectionPanel*>( myPanels[ SelectionPanelId ] ) )
+          dynamic_cast<VisuGUI_SelectionPanel*>( myPanels[ SelectionPanelId ] ) )
       {
-       if( aSelectionPanel->isVisible() )
-         aSelectionPanel->hide();
-       else
-         aSelectionPanel->show();
+        if( aSelectionPanel->isVisible() )
+          aSelectionPanel->hide();
+        else
+          aSelectionPanel->show();
       }
     }
   }
@@ -2150,8 +2461,8 @@ VisuGUI
     else if( myPanels.find( SelectionPanelId ) != myPanels.end() )
     {
       if( VisuGUI_SelectionPanel* aSelectionPanel =
-         dynamic_cast<VisuGUI_SelectionPanel*>( myPanels[ SelectionPanelId ] ) )
-       aSelectionPanel->setSelectionMode( anId - VISU_ACTOR_SELECTION );
+          dynamic_cast<VisuGUI_SelectionPanel*>( myPanels[ SelectionPanelId ] ) )
+        aSelectionPanel->setSelectionMode( anId - VISU_ACTOR_SELECTION );
     }
   }
   // At least one action must be checked
@@ -2328,6 +2639,10 @@ VisuGUI
                 tr("MEN_IMPORT_FROM_FILE"), "", (Qt::CTRL + Qt::Key_I), aParent, false,
                 this, SLOT(OnImportFromFile()));
 
+  createAction( VISU_IMPORT_SAUV, "", QIcon(),
+                tr("MEN_IMPORT_SAUV"), "", 0, aParent, false,
+                this, SLOT(OnImportFromSauvFile()));
+
   createAction( VISU_IMPORT_TABLE, "", QIcon(),
                 tr("MEN_IMPORT_TABLE"), "", 0, aParent, false,
                 this, SLOT(OnImportTableFromFile()));
@@ -2372,6 +2687,11 @@ VisuGUI
                 tr("MEN_CUT_LINES"), "", 0, aParent, false,
                 this, SLOT(OnCreateCutLines()));
 
+  aPixmap = aResourceMgr->loadPixmap("VISU",tr("ICON_CUT_SEGMENT"));
+  createAction( VISU_CUT_SEGMENT, tr("MEN_CUT_SEGMENT"), QIcon(aPixmap),
+                tr("MEN_CUT_SEGMENT"), "", 0, aParent, false,
+                this, SLOT(OnCreateCutSegment()));
+
   aPixmap = aResourceMgr->loadPixmap("VISU",tr("ICON_PLOT_3D"));
   createAction( VISU_PLOT_3D, tr("MEN_PLOT_3D"), QIcon(aPixmap),
                 tr("MEN_PLOT_3D"), "", 0, aParent, false,
@@ -2466,9 +2786,9 @@ VisuGUI
                 tr("MEN_CURVE_PROPS"), "", 0, aParent, false,
                 this, SLOT(OnCurveProperties()));
 
-  createAction( VISU_RENAME, tr("MEN_RENAME"), QIcon(),
-                tr("MEN_RENAME"), "", Qt::Key_F2, aParent, false,
-                this, SLOT(OnRename()));
+  createAction( VISU_CURVE_SCALE, tr("MEN_CURVE_SCALE"), QIcon(),
+                tr("MEN_CURVE_SCALE"), "", 0, aParent, false,
+                this, SLOT(OnCurveScale()));
 
   createAction( VISU_EDIT_CONTAINER, tr("MEN_EDIT_CONTAINER"), QIcon(),
                 tr("MEN_EDIT_CONTAINER"), "", 0, aParent, false,
@@ -2552,14 +2872,22 @@ VisuGUI
                 tr("MEN_EDGE_COLOR"), "", 0, aParent, false,
                 this, SLOT(OnChangeWireframeColor()));
 
-  createAction( VISU_OPACITY, tr("MEN_OPACITY"), QIcon(),
-                tr("MEN_OPACITY"), "", 0, aParent, false,
+  createAction( VISU_OPACITY, tr("MEN_TRANSPARENCY"), QIcon(),
+                tr("MEN_TRANSPARENCY"), "", 0, aParent, false,
                 this, SLOT(OnChangeOpacity()));
 
   createAction( VISU_LINE_WIDTH, tr("MEN_LINE_WIDTH"), QIcon(),
                 tr("MEN_LINE_WIDTH"), "", 0, aParent, false,
                 this, SLOT(OnChangeLines()));
 
+  createAction( VISU_POINT_MARKER, tr("MEN_POINT_MARKER"), QIcon(),
+                tr("MEN_POINT_MARKER"), "", 0, aParent, false,
+                this, SLOT(OnChangePointMarker()));
+
+  createAction( VISU_SHRINK_FACTOR, tr("MEN_SHRINK_FACTOR"), QIcon(),
+                tr("MEN_SHRINK_FACTOR"), "", 0, aParent, false,
+                this, SLOT(OnChangeShrinkFactor()));
+
 
   createAction( VISU_EDIT_SCALARMAP, tr("MEN_EDIT_PRS"), QIcon(),
                 tr("MEN_EDIT_PRS"), "", 0, aParent, false,
@@ -2577,6 +2905,10 @@ VisuGUI
                 tr("MEN_EDIT_PRS"), "", 0, aParent, false,
                 this, SLOT(OnEditCutLines()));
 
+  createAction( VISU_EDIT_CUTSEGMENT, tr("MEN_EDIT_PRS"), QIcon(),
+                tr("MEN_EDIT_PRS"), "", 0, aParent, false,
+                this, SLOT(OnEditCutSegment()));
+
   createAction( VISU_EDIT_ISOSURFACES, tr("MEN_EDIT_PRS"), QIcon(),
                 tr("MEN_EDIT_PRS"), "", 0, aParent, false,
                 this, SLOT(OnEditIsoSurfaces()));
@@ -2620,6 +2952,10 @@ VisuGUI
                 tr("MEN_SUCCCESSIVE_ANIMATION"), "", 0, aParent, false,
                 this, SLOT(OnSucccessiveTimeAnimation()));
 
+  createAction( VISU_POINT_EVOLUTION, tr("MEN_POINT_EVOLUTION"), QIcon(),
+                tr("MEN_POINT_EVOLUTION"), "", 0, aParent, false,
+                this, SLOT(OnPointEvolution()));
+
   aPixmap = aResourceMgr->loadPixmap("VISU",tr("ICON_ERASE_ALL"));
   createAction( VISU_ERASE_ALL, tr("MEN_ERASE_ALL"), QIcon(aPixmap),
                 tr("MEN_ERASE_ALL"), "", 0, aParent, false,
@@ -2650,7 +2986,7 @@ VisuGUI
                 tr("MEN_GAUSS_POINT_SELECTION"), "", 0, aParent, true,
                 this, SLOT(OnSwitchSelectionMode()));
 
-  // Defenition of the actions for the "Navigation" tool bar
+  // Definition of the actions for the "Navigation" tool bar
   registerAction( VISU_SLIDER_PANEL, mySlider->toggleViewAction() );
   registerAction( VISU_SWEEP_PANEL, mySweep->toggleViewAction() );
 
@@ -2658,6 +2994,10 @@ VisuGUI
                 tr("MEN_SHOW_ANIMATION"), "", 0, aParent, false,
                 this, SLOT(OnShowAnimation()));
 
+  createAction( VISU_SHOW_EVOLUTION, tr("MEN_SHOW_EVOLUTION"), QIcon(),
+                tr("MEN_SHOW_EVOLUTION"), "", 0, aParent, false,
+                this, SLOT(OnShowEvolution()));
+
   aPixmap = aResourceMgr->loadPixmap("VISU",tr("ICON_PLOT_3D"));
   createAction( VISU_PLOT3D_FROM_CUTPLANE, tr("MEN_PLOT3D_FROM_CUTPLANE"), QIcon(aPixmap),
                 tr("MEN_PLOT3D_FROM_CUTPLANE"), "", 0, aParent, false,
@@ -2691,21 +3031,33 @@ VisuGUI
                 tr("MEN_FILE_INFO"), "", 0, aParent, false,
                 this, SLOT(OnFileInfo()));
 
-  createAction( VISU_EXPORT_MED, tr("MEN_EXPORT_MED"), QIcon(),
-                tr("MEN_EXPORT_MED"), "", 0, aParent, false,
+  createAction( VISU_EXPORT_MED, tr("VISU_MEN_EXPORT_MED"), QIcon(),
+                tr("VISU_MEN_EXPORT_MED"), "", 0, aParent, false,
                 this, SLOT(OnExportMED()));
 
   createAction( VISU_FILTERSCALARS, tr("MEN_FILTER_SCALARS"), QIcon(),
                 tr("MEN_FILTER_SCALARS"), "", 0, aParent, false,
                 this, SLOT(OnFilterScalars()));
-                
+
   createAction( VISU_VALUES_LABELING, tr("MEN_VALUES_LABELING"), QIcon(),
                 tr("MEN_VALUES_LABELING"), "", 0, aParent, true,
-                this, SLOT(OnValuesLabeling())); 
+                this, SLOT(OnValuesLabeling()));
 
   createAction( VISU_VALUES_LABELING_PARAMS, tr("VISU_VALUES_LABELING_PARAMS"), QIcon(),
                 tr("VISU_VALUES_LABELING_PARAMS"), "", 0, aParent, false,
-                this, SLOT(OnValuesLabelingParams())); 
+                this, SLOT(OnValuesLabelingParams()));
+
+  createAction(VISU_ARCQUAD_MODE, tr("MEN_VISU_ARCQUAD_MODE"), QIcon(),
+               tr("MEN_VISU_ARCQUAD_MODE"), "",0, aParent, true,
+               this, SLOT(OnArcQuadMode()));
+
+  createAction(VISU_LINEQUAD_MODE, tr("MEN_VISU_LINEQUAD_MODE"),QIcon(),
+               tr("MEN_VISU_LINEQUAD_MODE"), "",0, aParent, true,
+               this, SLOT(OnLineQuadMode()));
+
+  createAction(VISU_SHOW_DEVIATION, tr("MEN_VISU_SHOW_DEVIATION"),QIcon(),
+               tr("MEN_VISU_SHOW_DEVIATION"), "",0, aParent, true,
+               this, SLOT(OnShowDeviation()));
 
 }
 
@@ -2720,6 +3072,7 @@ VisuGUI
 
   int anImportId = createMenu( tr( "MEN_IMPORT" ), aMenuId, -1, 10 );
   createMenu( VISU_IMPORT_FROM_FILE, anImportId ); // import from file
+  createMenu( VISU_IMPORT_SAUV, anImportId ); // import sauv file
   createMenu( VISU_IMPORT_TABLE, anImportId ); // import table
 
   aMenuId = createMenu( tr( "MEN_VISUALIZATION" ), -1, -1, 30 );
@@ -2729,6 +3082,7 @@ VisuGUI
   createMenu( VISU_ISO_SURFACES, aMenuId, 10 ); // iso surfaces
   createMenu( VISU_CUT_PLANES, aMenuId, 10 ); // cut planes
   createMenu( VISU_CUT_LINES, aMenuId, 10 ); // cut lines
+  createMenu( VISU_CUT_SEGMENT, aMenuId, 10 ); // cut segment
   createMenu( VISU_STREAM_LINES, aMenuId, 10 ); // stream lines
   createMenu( VISU_PLOT_3D, aMenuId, 10 ); // Plot3d
   createMenu( VISU_DEFORMED_SHAPE_AND_SCALAR_MAP, aMenuId, 10 ); // scalar map on deformed shape
@@ -2740,6 +3094,11 @@ VisuGUI
   createMenu( VISU_WIREFRAME, parentId, 10 ); //   wireframe
   createMenu( VISU_SURFACE, parentId, 10 ); //   surface
   createMenu( VISU_ERASE_ALL, aMenuId, 10 ); // erase all
+
+  parentId = createMenu( tr( "MEN_2D_QUADRATIC_MODE" ), aMenuId, 10 ); // 2D quadratic mode
+  createMenu( VISU_LINEQUAD_MODE, parentId, 10 ); //   lines
+  createMenu( VISU_ARCQUAD_MODE, parentId, 10 ); //   arcs
+
 }
 
 void
@@ -2756,6 +3115,7 @@ VisuGUI
   createTool( VISU_ISO_SURFACES, aToolId );
   createTool( VISU_CUT_PLANES, aToolId );
   createTool( VISU_CUT_LINES, aToolId );
+  createTool( VISU_CUT_SEGMENT, aToolId );
   createTool( VISU_STREAM_LINES, aToolId );
   createTool( VISU_PLOT_3D, aToolId );
   createTool( VISU_DEFORMED_SHAPE_AND_SCALAR_MAP, aToolId );
@@ -2789,6 +3149,7 @@ VisuGUI
 
   // VISU root commands
   mgr->insert( action( VISU_IMPORT_FROM_FILE ), -1, -1, -1 ); // import MED file
+  mgr->insert( action( VISU_IMPORT_SAUV ), -1, -1, -1 ); // import SAUV file
   mgr->insert( action( VISU_IMPORT_TABLE ), -1, -1, -1 ); // import tables from file
   mgr->insert( action( VISU_PLOT2D ), -1, -1, -1 ); // create Plot2d View
 
@@ -2799,6 +3160,7 @@ VisuGUI
   mgr->insert( action( VISU_ISO_SURFACES ), -1, -1, -1 ); // iso surface
   mgr->insert( action( VISU_CUT_PLANES ), -1, -1, -1 ); // cut planes
   mgr->insert( action( VISU_CUT_LINES ), -1, -1, -1 ); // cut lines
+  mgr->insert( action( VISU_CUT_SEGMENT ), -1, -1, -1 ); // cut segment
   mgr->insert( action( VISU_DEFORMED_SHAPE ), -1, -1, -1 ); // deformed shape
   mgr->insert( action( VISU_VECTORS ), -1, -1, -1 ); // vectors
   mgr->insert( action( VISU_STREAM_LINES ), -1, -1, -1 ); // stream lines
@@ -2815,6 +3177,7 @@ VisuGUI
   mgr->insert( action( VISU_EDIT_DEFORMEDSHAPE ), -1, -1, -1 );
   mgr->insert( action( VISU_EDIT_CUTPLANES ), -1, -1, -1 );
   mgr->insert( action( VISU_EDIT_CUTLINES ), -1, -1, -1 );
+  mgr->insert( action( VISU_EDIT_CUTSEGMENT ), -1, -1, -1 );
   mgr->insert( action( VISU_EDIT_ISOSURFACES ), -1, -1, -1 );
   mgr->insert( action( VISU_EDIT_VECTORS ), -1, -1, -1 );
   mgr->insert( action( VISU_EDIT_STREAMLINES ), -1, -1, -1 );
@@ -2825,15 +3188,12 @@ VisuGUI
 
   mgr->insert( action( VISU_FILTERSCALARS ), -1, -1, -1 );
 
-  // rename
-  mgr->insert( action( VISU_RENAME ), -1, -1, -1 );
-
   // copy
   mgr->insert( action( VISU_COPY_PRS ), -1, -1, -1 );
 
   // delete
   mgr->insert( action( VISU_CLEAR_CONTAINER ), -1, -1, -1 );
-  
+
   // labeling
   mgr->insert( separator(), -1, -1, -1 );
   mgr->insert( action( VISU_VALUES_LABELING ), -1, -1, -1 );
@@ -2868,13 +3228,20 @@ VisuGUI
   mgr->insert( action( VISU_SHADING )     , parentId, -1, -1 ); // shading
   mgr->insert( action( VISU_NOSHADING )   , parentId, -1, -1 ); // noshading
 
+  //"2D Quadratic" submenu
+  parentId = mgr->insert( tr( "MEN_2D_QUADRATIC_MODE" ), -1, -1 );
+  mgr->insert( action( VISU_LINEQUAD_MODE ), parentId, -1, -1 ); // line representation
+  mgr->insert( action( VISU_ARCQUAD_MODE ), parentId, -1, -1 ); // arc representation
+
   // "Properties" submenu
   parentId = mgr->insert( tr( "MEN_PROPERTIES" ), -1, -1 );
-  mgr->insert( action( VISU_CELL_COLOR ), parentId, -1, -1 ); // cell color
-  mgr->insert( action( VISU_EDGE_COLOR ), parentId, -1, -1 ); // edge color
-  mgr->insert( action( VISU_COLOR )     , parentId, -1, -1 ); // color
-  mgr->insert( action( VISU_OPACITY )   , parentId, -1, -1 ); // opacity
-  mgr->insert( action( VISU_LINE_WIDTH ), parentId, -1, -1 ); // line width
+  mgr->insert( action( VISU_CELL_COLOR ),    parentId, -1, -1 ); // cell color
+  mgr->insert( action( VISU_EDGE_COLOR ),    parentId, -1, -1 ); // edge color
+  mgr->insert( action( VISU_COLOR )     ,    parentId, -1, -1 ); // color
+  mgr->insert( action( VISU_OPACITY )   ,    parentId, -1, -1 ); // opacity
+  mgr->insert( action( VISU_LINE_WIDTH ),    parentId, -1, -1 ); // line width
+  mgr->insert( action( VISU_POINT_MARKER ),  parentId, -1, -1 ); // point marker
+  mgr->insert( action( VISU_SHRINK_FACTOR ), parentId, -1, -1 ); // shrink factor
 
   mgr->insert( separator(), -1, -1, -1 );
 
@@ -2891,6 +3258,10 @@ VisuGUI
 
   mgr->insert( separator(), -1, -1, -1 );
 
+  mgr->insert( action( VISU_POINT_EVOLUTION ), -1, -1, -1 );
+
+  mgr->insert( separator(), -1, -1, -1 );
+
   // view parameters commands
   mgr->insert( action( VISU_SAVE_VIEW_PARAMS ), -1, -1, -1 ); // save view params
   mgr->insert( action( VISU_SAVE_VIEW_PARAMS_1 ), -1, -1, -1 ); // save view params
@@ -2900,6 +3271,9 @@ VisuGUI
   mgr->insert( action( VISU_ARRANGE_ACTORS ), -1, -1, -1 ); // arrange actors
 
   mgr->insert( action( VISU_CURVE_PROPS ), -1, -1, -1 ); // curve properties
+  mgr->insert( action( VISU_CURVE_SCALE ), -1, -1, -1 ); // curve scale
+  //Show deviation command on curve
+  mgr->insert( action( VISU_SHOW_DEVIATION ), -1, -1, -1 ); // deviation
 
   mgr->insert( action( VISU_MULTIPR_FULL_RES ), -1, -1, -1 );
   mgr->insert( action( VISU_MULTIPR_MED_RES ), -1, -1, -1 );
@@ -2912,15 +3286,16 @@ VisuGUI
   // Rules
 
   QString aPrsAll ("'VISU::TSCALARMAP' 'VISU::TISOSURFACES' 'VISU::TDEFORMEDSHAPE' 'VISU::TCUTPLANES' "
-                   "'VISU::TCUTLINES' 'VISU::TVECTORS' 'VISU::TSTREAMLINES' 'VISU::TPLOT3D' "
-                  "'VISU::TSCALARMAPONDEFORMEDSHAPE' 'VISU::TDEFORMEDSHAPEANDSCALARMAP' 'VISU::TCOLOREDPRS3DHOLDER'");
+                   "'VISU::TCUTLINES' 'VISU::TCUTSEGMENT' 'VISU::TVECTORS' 'VISU::TSTREAMLINES' 'VISU::TPLOT3D' "
+                   "'VISU::TSCALARMAPONDEFORMEDSHAPE' 'VISU::TDEFORMEDSHAPEANDSCALARMAP' 'VISU::TCOLOREDPRS3DHOLDER'");
   QString aSimplePrsAll ("'VISU::TSCALARMAP' 'VISU::TISOSURFACES' 'VISU::TDEFORMEDSHAPE' 'VISU::TCUTPLANES' "
-                        "'VISU::TCUTLINES' 'VISU::TVECTORS' 'VISU::TSTREAMLINES' 'VISU::TPLOT3D' "
-                        "'VISU::TSCALARMAPONDEFORMEDSHAPE'");
+                         "'VISU::TCUTLINES' 'VISU::TCUTSEGMENT' 'VISU::TVECTORS' 'VISU::TSTREAMLINES' 'VISU::TPLOT3D' "
+                         "'VISU::TSCALARMAPONDEFORMEDSHAPE'");
 
   // VISU root commands
   QString aRule = "client='ObjectBrowser' and selcount=1 and type='VISU::TVISUGEN'";
   mgr->setRule( action( VISU_IMPORT_FROM_FILE ), aRule );
+  mgr->setRule( action( VISU_IMPORT_SAUV ), aRule );
   mgr->setRule( action( VISU_IMPORT_TABLE ), aRule );
   mgr->setRule( action( VISU_PLOT2D ), aRule );
 
@@ -2930,6 +3305,7 @@ VisuGUI
   mgr->setRule( action( VISU_ISO_SURFACES ), aRule );
   mgr->setRule( action( VISU_CUT_PLANES ), aRule );
   mgr->setRule( action( VISU_CUT_LINES ), aRule );
+  mgr->setRule( action( VISU_CUT_SEGMENT ), aRule );
   mgr->setRule( action( VISU_PLOT_3D ), aRule );
   aRule += " and nbComponents>1";
   mgr->setRule( action( VISU_DEFORMED_SHAPE ), aRule );
@@ -2943,22 +3319,22 @@ VisuGUI
   QString aTableOrContShow = "(($type in {'VISU::TTABLE' 'VISU::TPOINTMAP3D' 'VISU::TCONTAINER'}) and isPlot2dViewer and hasCurves and isThereAreHiddenCurves)";
   QString orCurveVisible   = "or (type='VISU::TCURVE' and isVisible)";
   QString orCurveInvisible = "or (type='VISU::TCURVE'" + andInvisible + ")";
-  QString aPrsVisible   = "(($type in {'VISU::TMESH' 'VISU::TPOINTMAP3D'" + aPrsAll + "}) and isVisible and (not isPlot2dViewer))";
-  QString aPrsInvisible = "(($type in {'VISU::TMESH' 'VISU::TPOINTMAP3D'" + aPrsAll + "})" + andInvisible + " and (not isPlot2dViewer))";
+  QString aPrsVisible   = "(($type in {'VISU::TMESH' 'VISU::TPOINTMAP3D' 'VISU::TGAUSSPOINTS'" + aPrsAll + "}) and isVisible and (not isPlot2dViewer))";
+  QString aPrsInvisible = "(($type in {'VISU::TMESH' 'VISU::TPOINTMAP3D' 'VISU::TGAUSSPOINTS'" + aPrsAll + "})" + andInvisible + " and (not isPlot2dViewer))";
   QString aComponent = "( selcount=1 and canBeDisplayed and isVisuComponent )";
 
-  QString anEraseRule = "( selcount>0 and ({true} in $canBeDisplayed) and (" + aPrsVisible +
-    " or (client='ObjectBrowser' and (" + aTableOrContHide + orCurveVisible + "))) ) or " + aComponent;
+  QString anEraseRule = "( selcount>0 and ({true} in $canBeDisplayed or type in {'VISU::TCONTAINER' 'VISU::TCURVE'}) and (" + aPrsVisible +
+    " or (   (" + aTableOrContHide + orCurveVisible + "))) ) or " + aComponent;
 
-  QString aDisplayRule = "( selcount>0 and ({true} in $canBeDisplayed) and (" + aPrsInvisible +
-    " or (client='ObjectBrowser' and (" + aTableOrContShow + orCurveInvisible + "))) ) or " + aComponent;
+  QString aDisplayRule = "( selcount>0 and ({true} in $canBeDisplayed or type in {'VISU::TCONTAINER' 'VISU::TCURVE'}) and (" + aPrsInvisible +
+    " or (   (" + aTableOrContShow + orCurveInvisible + "))) ) or " + aComponent;
 
-  QString aDOnlyRule = "( selcount>0 and ({true} in $canBeDisplayed) and (($type in {'VISU::TMESH' 'VISU::TPOINTMAP3D'" + aPrsAll + "})"
-    " or (client='ObjectBrowser' and ((type='VISU::TTABLE' and nbChildren>0) or"
-    " ($type in {'VISU::TCURVE' 'VISU::TCONTAINER'})))) ) or" + aComponent;
+  QString aDOnlyRule = "( selcount>0 and ({true} in $canBeDisplayed or type in {'VISU::TCONTAINER' 'VISU::TCURVE'}) and (($type in {'VISU::TMESH' 'VISU::TPOINTMAP3D' 'VISU::TGAUSSPOINTS'" + aPrsAll + "})"
+    " or (   ((type='VISU::TTABLE' and nbChildren>0) or (type='VISU::TCONTAINER' and hasCurves) or"
+    " (type='VISU::TCURVE')))) ) or" + aComponent;
 
-  QString aScalarBarHideRule = "( selcount>0 and ($type in {'VISU::TMESH' 'VISU::TPOINTMAP3D'" + aPrsAll + "}) and isScalarMapAct=1 and " + aPrsVisible + " and isScalarBarVisible )";
-  QString aScalarBarShowRule = "( selcount>0 and ($type in {'VISU::TMESH' 'VISU::TPOINTMAP3D'" + aPrsAll + "}) and isScalarMapAct=1 and " + aPrsVisible + " and (not isScalarBarVisible) )";
+  QString aScalarBarHideRule = "( selcount>0 and ($type in {'VISU::TMESH' 'VISU::TPOINTMAP3D' 'VISU::TGAUSSPOINTS'" + aPrsAll + "}) and (isScalarMapAct=1  or isGaussPtsAct=1 ) and " + aPrsVisible + " and isScalarBarVisible )";
+  QString aScalarBarShowRule = "( selcount>0 and ($type in {'VISU::TMESH' 'VISU::TPOINTMAP3D' 'VISU::TGAUSSPOINTS'" + aPrsAll + "}) and ( isScalarMapAct=1 or isGaussPtsAct=1 ) and " + aPrsVisible + " and (not isScalarBarVisible) )";
 
   mgr->setRule( action( VISU_ERASE ), anEraseRule );
   mgr->setRule( action( VISU_DISPLAY ), aDisplayRule );
@@ -2976,7 +3352,7 @@ VisuGUI
 
   aRule = "selcount=1 and $type in { " + aSimplePrsAll + "}";
   mgr->setRule( action( VISU_FILTERSCALARS ), aRule );
-  
+
   // labeling
 
   aRule = "hasActor=1 and selcount=1 and $type in { 'VISU::TGAUSSPOINTS'"  + aPrsAll + " }";
@@ -2984,6 +3360,15 @@ VisuGUI
   mgr->setRule( action( VISU_VALUES_LABELING ), "{true} in $isValuesLabeled", QtxPopupMgr::ToggleRule );
   mgr->setRule( action( VISU_VALUES_LABELING_PARAMS ), aRule, QtxPopupMgr::VisibleRule );
 
+  //2D quadratic
+  aRule = "isVisible and hasActor=1 and selcount=1 and $type in {'VISU::TMESH' 'VISU::TSCALARMAP' 'VISU::TDEFORMEDSHAPE' 'VISU::TSCALARMAPONDEFORMEDSHAPE' 'VISU::TDEFORMEDSHAPEANDSCALARMAP'}";
+  mgr->setRule (action(VISU_ARCQUAD_MODE), aRule , QtxPopupMgr::VisibleRule);
+  mgr->setRule (action(VISU_LINEQUAD_MODE),aRule , QtxPopupMgr::VisibleRule);
+
+  mgr->setRule (action(VISU_ARCQUAD_MODE), aRule + " and quadratic2DMode='VISU::ARCS'", QtxPopupMgr::ToggleRule);
+  mgr->setRule (action(VISU_LINEQUAD_MODE),aRule + " and quadratic2DMode='VISU::LINES'", QtxPopupMgr::ToggleRule);
+
+
   // view parameters
   aRule = "selcount=1 and type='VISU::TVIEW3D' and activeView='VTKViewer'";
   mgr->setRule( action( VISU_SAVE_VIEW_PARAMS_1 ), aRule );
@@ -3004,7 +3389,7 @@ VisuGUI
                         " 'VISU::TPLOT3D' 'VISU::TSCALARMAPONDEFORMEDSHAPE' 'VISU::TDEFORMEDSHAPEANDSCALARMAP' 'VISU::TPOINTMAP3D'}";
   QString aShrinkType = " and $type in {'VISU::TMESH' 'VISU::TSCALARMAP' 'VISU::TDEFORMEDSHAPE' 'VISU::TSCALARMAPONDEFORMEDSHAPE' 'VISU::TDEFORMEDSHAPEANDSCALARMAP' 'VISU::TPOINTMAP3D'}";
   QString aLineType   = " and $type in {'VISU::TMESH' 'VISU::TSCALARMAP' 'VISU::TSCALARMAP' 'VISU::TISOSURFACES' 'VISU::TDEFORMEDSHAPE' "
-                        "'VISU::TCUTPLANES' 'VISU::TCUTLINES' 'VISU::TSTREAMLINES' 'VISU::TPLOT3D' 'VISU::TSCALARMAPONDEFORMEDSHAPE' 'VISU::TDEFORMEDSHAPEANDSCALARMAP' 'VISU::TPOINTMAP3D'}";
+                        "'VISU::TCUTPLANES' 'VISU::TCUTLINES' 'VISU::TCUTSEGMENT' 'VISU::TSTREAMLINES' 'VISU::TPLOT3D' 'VISU::TSCALARMAPONDEFORMEDSHAPE' 'VISU::TDEFORMEDSHAPEANDSCALARMAP' 'VISU::TPOINTMAP3D'}";
 
   QString aFeatureEdgesType =  " and $type in {'VISU::TMESH' 'VISU::TSCALARMAP''VISU::TDEFORMEDSHAPE' 'VISU::TSCALARMAPONDEFORMEDSHAPE'}";
 
@@ -3035,19 +3420,17 @@ VisuGUI
 
   // "Properties" submenu
   mgr->setRule( action( VISU_CELL_COLOR ), aRule + " and type='VISU::TMESH' and representation='VISU::SURFACEFRAME'" );
-  mgr->setRule( action( VISU_EDGE_COLOR ), aRule + " and type='VISU::TMESH' and representation='VISU::SURFACEFRAME'" );
+  mgr->setRule( action( VISU_EDGE_COLOR ), aRule + aSurfFrameType + " and representation='VISU::SURFACEFRAME'" );
   mgr->setRule( action( VISU_COLOR ), aRule + " and ((type='VISU::TMESH'"
-               " and $representation in {'VISU::POINT' 'VISU::WIREFRAME' 'VISU::SHADED' 'VISU::INSIDEFRAME'}) "
+               " and $representation in {'VISU::POINT' 'VISU::WIREFRAME' 'VISU::SHADED' 'VISU::INSIDEFRAME' 'VISU::FEATURE_EDGES'}) "
                "or (type='VISU::TDEFORMEDSHAPE' and hasActor=1))" );
   mgr->setRule( action( VISU_OPACITY ), aRule + " and hasActor=1" );
-  mgr->setRule( action( VISU_LINE_WIDTH ), aRule + aLineType + " and hasActor=1" );
+  mgr->setRule( action( VISU_LINE_WIDTH ), aRule + aLineType + " and hasActor=1 and representation!='VISU::POINT'" );
+  mgr->setRule( action( VISU_POINT_MARKER ), aRule + aLineType + " and hasActor=1 and representation='VISU::POINT'" );
+  mgr->setRule( action( VISU_SHRINK_FACTOR ), aRule + aShrinkType + " and isShrunk=1" );
 
-  // rename command
   QString aCurveAll = "'VISU::TTABLE' 'VISU::TCURVE' 'VISU::TCONTAINER' 'VISU::POINTMAP3D'";
 
-  aRule = "selcount=1 and ($type in {'VISU::TVIEW3D' 'VISU::TMESH' 'VISU::TPOINTMAP3D' " + aCurveAll + " " + aPrsAll + "})";
-  mgr->setRule( action( VISU_RENAME ), aRule );
-
   // copy presentation command
   aRule = "selcount=1 and ($type in {" + aPrsAll + "})";
   mgr->setRule( action( VISU_COPY_PRS ), aRule );
@@ -3055,6 +3438,7 @@ VisuGUI
   // Curve commands
   aRule = "selcount=1 and type='VISU::TCURVE'";
   mgr->setRule( action( VISU_CURVE_PROPS ), aRule );
+  mgr->setRule( action( VISU_CURVE_SCALE ), "selcount > 0 and type='VISU::TCURVE'");
 
   // Table Commands
   aRule = "selcount=1 and ( type='VISU::TPOINTMAP3D' or type='VISU::TTABLE')";
@@ -3068,30 +3452,32 @@ VisuGUI
   mgr->setRule( action( VISU_CLEAR_CONTAINER ), aRule );
 
   mgr->setRule( action( VISU_EDIT_SCALARMAP ),
-               "selcount=1 and type='VISU::TSCALARMAP'" );
+                "selcount=1 and type='VISU::TSCALARMAP'" );
   mgr->setRule( action( VISU_EDIT_DEFORMEDSHAPE ),
-               "selcount=1 and type='VISU::TDEFORMEDSHAPE'" );
+                "selcount=1 and type='VISU::TDEFORMEDSHAPE'" );
   mgr->setRule( action( VISU_EDIT_DEFORMEDSHAPEANDSCALARMAP ),
-               "selcount=1 and $type in {'VISU::TSCALARMAPONDEFORMEDSHAPE' 'VISU::TDEFORMEDSHAPEANDSCALARMAP'}" );
+                "selcount=1 and $type in {'VISU::TSCALARMAPONDEFORMEDSHAPE' 'VISU::TDEFORMEDSHAPEANDSCALARMAP'}" );
   mgr->setRule( action( VISU_EDIT_CUTPLANES ),
-               "selcount=1 and type='VISU::TCUTPLANES'" );
+                "selcount=1 and type='VISU::TCUTPLANES'" );
   mgr->setRule( action( VISU_EDIT_CUTLINES ),
-               "selcount=1 and type='VISU::TCUTLINES'" );
+                "selcount=1 and type='VISU::TCUTLINES'" );
+  mgr->setRule( action( VISU_EDIT_CUTSEGMENT ),
+                "selcount=1 and type='VISU::TCUTSEGMENT'" );
   mgr->setRule( action( VISU_EDIT_ISOSURFACES ),
-               "selcount=1 and type='VISU::TISOSURFACES'" );
+                "selcount=1 and type='VISU::TISOSURFACES'" );
   mgr->setRule( action( VISU_EDIT_VECTORS ),
-               "selcount=1 and type='VISU::TVECTORS'" );
+                "selcount=1 and type='VISU::TVECTORS'" );
   mgr->setRule( action( VISU_EDIT_STREAMLINES ),
-               "selcount=1 and type='VISU::TSTREAMLINES'" );
+                "selcount=1 and type='VISU::TSTREAMLINES'" );
   mgr->setRule( action( VISU_EDIT_PLOT3D ),
-               "selcount=1 and type='VISU::TPLOT3D'" );
+                "selcount=1 and type='VISU::TPLOT3D'" );
   mgr->setRule( action( VISU_EDIT_POINTMAP3D ),
-               "selcount=1 and type='VISU::TPOINTMAP3D'" );
+                "selcount=1 and type='VISU::TPOINTMAP3D'" );
 
-  aRule = "selcount=1 and type='VISU::TCUTLINES' and nbNamedChildren=0";
+  aRule = "selcount=1 and $type in {'VISU::TCUTLINES' 'VISU::TCUTSEGMENT'} and nbNamedChildren=0";
   mgr->setRule( action( VISU_CREATE_TABLE ), aRule );
 
-  aRule = "selcount=1 and ($type in {" + aSimplePrsAll + "})";
+  aRule = "selcount=1 and ($type in {" + aSimplePrsAll + "}) and isFieldPrs=0";
   mgr->setRule( action( VISU_SWEEP ), aRule );
 
   aRule = "client='ObjectBrowser' and selcount>0";
@@ -3106,11 +3492,17 @@ VisuGUI
   aRule += " and activeView in {'VTKViewer' 'SVTK'}";
   mgr->setRule( action( VISU_SUCCCESSIVEANIMATION ), aRule );
 
+  aRule = "client='ObjectBrowser' and selcount>0";
+  aRule += " and $type in {'VISU::TFIELD'}";
+  aRule += " and medEntity='NODE_ENTITY'";
+  aRule += " and nbTimeStamps>1";
+  mgr->setRule( action( VISU_POINT_EVOLUTION ), aRule );
+
   aRule = "client='ObjectBrowser' and $type in {'VISU::TENTITY' 'VISU::TFAMILY' 'VISU::TGROUP'}";
   mgr->setRule( action( VISU_CREATE_PRS ), aRule + " and selcount=1" );
   mgr->setRule( action( VISU_CREATE_MANY_PRS ), aRule + " and selcount>1" );
   mgr->setRule( action( VISU_EDIT_PLOT3D ),
-               "selcount=1 and type='VISU::TPLOT3D'" );
+                "selcount=1 and type='VISU::TPLOT3D'" );
 
   //aRule = "client='ObjectBrowser' and type='MEDFIELD'";
   //mgr->setRule( action( VISU_IMPORT_MED ), aRule, true );
@@ -3135,22 +3527,23 @@ VisuGUI
 
   mgr->setRule( action( VISU_FILE_INFO ), "selcount=1 and type in {'VISU::TRESULT'}" );
   mgr->setRule( action( VISU_EXPORT_MED ), "selcount=1 and type in {'VISU::TRESULT'}" );
+
+  aRule = "isPlot2dViewer and isVisible and selcount > 0 and type='VISU::TCURVE' and hasDeviation";
+  mgr->setRule (action(VISU_SHOW_DEVIATION), aRule , QtxPopupMgr::VisibleRule);
+  aRule = "isPlot2dViewer and isVisible and selcount > 0 and type='VISU::TCURVE' and hasDeviation and isDeviationDisplayed";
+  mgr->setRule (action(VISU_SHOW_DEVIATION), aRule , QtxPopupMgr::ToggleRule);
 }
 
 void VisuGUI::createPanels()
 {
-  myPanels.insert( SelectionPanelId,    new VisuGUI_SelectionPanel( this ) );
-  myPanels.insert( FeatureEdgesPanelId, new VisuGUI_FeatureEdgesPanel( this ) );
-  myPanels.insert( ClippingPlanesPanelId, new VisuGUI_ClippingPanel( this ) );
-
-  QMap< PanelId, VisuGUI_Panel* >::iterator it = myPanels.begin(), itEnd = myPanels.end();
-  for( ; it != itEnd; ++it )
-  {
-    if( VisuGUI_Panel* aPanel = it.value() )
-    {
-      aPanel->hide();
-      GetDesktop(this)->addDockWidget( Qt::RightDockWidgetArea, aPanel );
-    }
+  myPanels[SelectionPanelId]      = new VisuGUI_SelectionPanel( this );
+  myPanels[FeatureEdgesPanelId]   = new VisuGUI_FeatureEdgesPanel( this );
+  myPanels[ClippingPlanesPanelId] = new VisuGUI_ClippingPanel( this );
+
+  VisuGUI_Panel* aPanel;
+  foreach( aPanel, myPanels ) {
+    getApp()->desktop()->addDockWidget( Qt::RightDockWidgetArea, aPanel );
+    aPanel->setVisible( false );
   }
 }
 
@@ -3180,29 +3573,29 @@ void VisuGUI::contextMenuPopup( const QString& theClient, QMenu* theMenu, QStrin
     if (!anIO.IsNull() && anIO->hasEntry()) {
       _PTR(SObject) aSObject = aCStudy->FindObjectID(anIO->getEntry());
       if ( !aSObject )
-       continue;
+        continue;
 
       if ( !isOBClient ) {
-       QString aName = QString( aSObject->GetName().c_str() );
-       while ( aName.at( aName.length() - 1 ) == ' ' ) // Remove extraspaces in Name of popup
-         aName.remove( (aName.length() - 1), 1 );
-       theTitle = aName;
+        QString aName = QString( aSObject->GetName().c_str() );
+        while ( aName.at( aName.length() - 1 ) == ' ' ) // Remove extraspaces in Name of popup
+          aName.remove( (aName.length() - 1), 1 );
+        theTitle = aName;
       }
 
       CORBA::Object_var aCORBAObject = VISU::ClientSObjectToObject(aSObject);
       if (CORBA::is_nil(aCORBAObject)) {
-       VISU::VISUType aType = VISU::Storable::SObject2Type( aSObject );
-       if (aType == VISU::TTIMESTAMP) {
-         _PTR(ChildIterator) anIter = aCStudy->NewChildIterator(aSObject);
-         _PTR(SObject) aPrs;
-         for (; anIter->More(); anIter->Next()) {
-           aPrs = anIter->Value();
-           if (!aPrs)
-             continue;
-           std::vector<VISU::Prs3d_i*> aSubList = GetPrs3dList(this, aPrs);
-           nbPrs += aSubList.size();
-         }
-       }
+        VISU::VISUType aType = VISU::Storable::SObject2Type( aSObject );
+        if (aType == VISU::TTIMESTAMP) {
+          _PTR(ChildIterator) anIter = aCStudy->NewChildIterator(aSObject);
+          _PTR(SObject) aPrs;
+          for (; anIter->More(); anIter->Next()) {
+            aPrs = anIter->Value();
+            if (!aPrs)
+              continue;
+            std::vector<VISU::Prs3d_i*> aSubList = GetPrs3dList(this, aPrs);
+            nbPrs += aSubList.size();
+          }
+        }
       }
     }
   }
@@ -3221,18 +3614,18 @@ void VisuGUI::contextMenuPopup( const QString& theClient, QMenu* theMenu, QStrin
     if (!anIO.IsNull() && anIO->hasEntry()) {
       _PTR(SObject) aSObject = aCStudy->FindObjectID(anIO->getEntry());
       if ( !aSObject )
-       continue;
+        continue;
       VISU::VISUType aType = VISU::Storable::SObject2Type( aSObject );
       if (aType == VISU::TCURVE) {
-       isCurves = true;
+        isCurves = true;
       }  else {
-       VISU::TObjectInfo anObjectInfo = VISU::GetObjectByEntry(GetAppStudy(this), anIO->getEntry());
-       if(VISU::Prs3d_i* aPrsObject = VISU::GetPrs3dFromBase(anObjectInfo.myBase)){
-         if (aPrsObject->GetType() == VISU::TCUTPLANES) {
-           if (VISU::CutPlanes_i* aCutPrs = dynamic_cast<VISU::CutPlanes_i*>(aPrsObject))
-             isOneCutPlane = aCutPrs->GetNbPlanes() == 1;
-         }
-       }
+        VISU::TObjectInfo anObjectInfo = VISU::GetObjectByEntry(GetAppStudy(this), anIO->getEntry());
+        if(VISU::Prs3d_i* aPrsObject = VISU::GetPrs3dFromBase(anObjectInfo.myBase)){
+          if (aPrsObject->GetType() == VISU::TCUTPLANES) {
+            if (VISU::CutPlanes_i* aCutPrs = dynamic_cast<VISU::CutPlanes_i*>(aPrsObject))
+              isOneCutPlane = aCutPrs->GetNbPlanes() == 1;
+          }
+        }
       }
     }
   }
@@ -3283,6 +3676,8 @@ void VisuGUI::contextMenuPopup( const QString& theClient, QMenu* theMenu, QStrin
   VISU::VISUType aType = VISU::Storable::RestoringMap2Type( aMap );
   if (aType == VISU::TANIMATION) {
     theMenu->addAction( action( VISU_SHOW_ANIMATION ) );
+  } else if (aType == VISU::TEVOLUTION) {
+    theMenu->addAction( action( VISU_SHOW_EVOLUTION ) );
   } else if (isOBClient) {
     if (IsSObjectTable(aSObject)) {
       /*      action( VISU_SHOW_TABLE )->addTo(theMenu);
@@ -3306,7 +3701,7 @@ void VisuGUI::contextMenuPopup( const QString& theClient, QMenu* theMenu, QStrin
         if (aSFather1) {
           std::string aValue = aSFather1->GetName();
           if (strcmp(aValue.c_str(), "MEDFIELD") == 0) {
-           theMenu->addAction( action( VISU_IMPORT_MED_FIELD ) ); // "Import Field"
+            theMenu->addAction( action( VISU_IMPORT_MED_FIELD ) ); // "Import Field"
           }
         }
       }
@@ -3359,16 +3754,30 @@ VisuGUI
   setMenuShown( true );
   setToolShown( true );
 
+  // import Python module that manages VISU plugins (need to be here because SalomePyQt API uses active module)
+  PyGILState_STATE gstate = PyGILState_Ensure();
+  PyObject* pluginsmanager=PyImport_ImportModuleNoBlock((char*)"salome_pluginsmanager");
+  if(pluginsmanager==NULL)
+    PyErr_Print();
+  else
+    {
+      PyObject* result=PyObject_CallMethod( pluginsmanager, (char*)"initialize", (char*)"isss",1,"visu",tr("MEN_VISUALIZATION").toStdString().c_str(),tr("VISU_PLUGINS_OTHER").toStdString().c_str());
+      if(result==NULL)
+        PyErr_Print();
+      Py_XDECREF(result);
+    }
+  PyGILState_Release(gstate);
+  // end of GEOM plugins loading
+
   // Reset actions accelerator keys
   QList<QKeySequence> shortcuts;
   shortcuts.append( QKeySequence(Qt::CTRL + Qt::Key_I) );
   action(VISU_IMPORT_FROM_FILE)->setShortcuts(shortcuts);
 
   action(VISU_DELETE_OBJS)->setEnabled(true); // Delete: Key_Delete
-  action(VISU_RENAME     )->setEnabled(true); // Rename: Key_F2
 
   ((VisuGUI_ClippingPanel*) myPanels[ClippingPlanesPanelId])->init();
-
+  GetVisuGen( this )->GetClippingPlaneMgr().SetStudy(GetCStudy(dynamic_cast<SalomeApp_Study*>(theStudy)),true);
   emit moduleActivated();
 
   return aResult;
@@ -3382,21 +3791,13 @@ VisuGUI
   setMenuShown( false );
   setToolShown( false );
 
-  QMap< PanelId, VisuGUI_Panel* >::iterator it = myPanels.begin(), itEnd = myPanels.end();
-  for( ; it != itEnd; ++it )
-  {
-    if( VisuGUI_Panel* aPanel = it.value() )
-      aPanel->hide();
-  }
-
   // Unset actions accelerator keys
   action(VISU_IMPORT_FROM_FILE)->setShortcuts(QKeySequence::UnknownKey); // Import: CTRL + Key_I
 
   action(VISU_DELETE_OBJS)->setEnabled(false); // Delete: Key_Delete
-  action(VISU_RENAME     )->setEnabled(false); // Rename: Key_F2
 
   bool aResult = SalomeApp_Module::deactivateModule( theStudy );
-  
+
   emit moduleDeactivated();
 
   return aResult;
@@ -3409,11 +3810,30 @@ VisuGUI
   return new VisuGUI_Selection( (SalomeApp_Module*)this );
 }
 
+void
+VisuGUI
+::processPresentationCreated( VISU::Prs3d_i* thePrs )
+{
+  if( thePrs )
+  {
+    QString anEntry = thePrs->GetEntry().c_str();
+    if( anEntry.isEmpty() )
+      if( VISU::ColoredPrs3d_i* aColoredPrs = dynamic_cast<VISU::ColoredPrs3d_i*>( thePrs ) )
+        anEntry = aColoredPrs->GetHolderEntry().c_str();
+
+    QStringList anEntryList( anEntry );
+    if( getApp() )
+      getApp()->browseObjects( anEntryList );
+
+    emit presentationCreated( thePrs );
+  }
+}
+
 //******************************************************************
 void VisuGUI::studyActivated()
 {
   GetVisuGen(this)->SetCurrentStudy(GetDSStudy(GetCStudy(GetAppStudy(this))));
-  
+
 }
 
 /*
@@ -3428,6 +3848,43 @@ extern "C" {
 
 void VisuGUI::createPreferences()
 {
+  SUIT_ResourceMgr* aResourceMgr = VISU::GetResourceMgr();
+
+  // TAB: General
+  int genTab   = addPreference( tr( "VISU_PREF_GENERAL" ) );
+  // Quantities with individual precision settings
+  int precGroup = addPreference( tr( "VISU_PREF_GROUP_PRECISION" ), genTab );
+  setPreferenceProperty( precGroup, "columns", 2 );
+
+  // Default precision used by some input fieklds and data visualization code
+  // Moved here from "Representation" tab to have all precisions in the same place
+  int point_precision = addPreference( tr( "VISU_PREF_visual_data_precision" ), precGroup,
+                                       LightApp_Preferences::IntSpin, "VISU", "visual_data_precision" );
+  setPreferenceProperty( point_precision, "min", -16 );
+  setPreferenceProperty( point_precision, "max", 16 );
+  setPreferenceProperty( point_precision, "step", 1 );
+  
+  const int nbQuantities = 5;
+  int precs[nbQuantities], ii = 0;
+  precs[ii++] = addPreference( tr( "VISU_PREF_length_precision" ), precGroup,
+                            LightApp_Preferences::IntSpin, "VISU", "length_precision" );  
+  precs[ii++] = addPreference( tr( "VISU_PREF_angle_precision" ), precGroup,
+                            LightApp_Preferences::IntSpin, "VISU", "angle_precision" );
+  precs[ii++] = addPreference( tr( "VISU_PREF_len_tol_precision" ), precGroup,
+                            LightApp_Preferences::IntSpin, "VISU", "len_tol_precision" );
+  precs[ii++] = addPreference( tr( "VISU_PREF_parametric_precision" ), precGroup,
+                            LightApp_Preferences::IntSpin, "VISU", "parametric_precision" );
+  precs[ii  ] = addPreference( tr( "VISU_PREF_memory_precision" ), precGroup,
+                            LightApp_Preferences::IntSpin, "VISU", "memory_precision" );
+  
+  // Set property for precision value for spinboxes
+  for ( ii = 0; ii < nbQuantities; ii++ ){
+    setPreferenceProperty( precs[ii], "min", ii == 2 ? 0 : -14 );
+    setPreferenceProperty( precs[ii], "max", ii == 2 ? 3 : 14 );
+    setPreferenceProperty( precs[ii], "precision", 2 );
+  }   
+
+
   // TAB: "MED import"
   int importTab = addPreference( tr( "MED import" ) );
   //printf( "++++++++++++++++++ Tab index %d\n", importTab );
@@ -3468,6 +3925,8 @@ void VisuGUI::createPreferences()
   setPreferenceProperty( mode, "strings", modes );
   setPreferenceProperty( mode, "indexes", indices );
 
+  addPreference( tr( "VISU_LOGARITHMIC_SCALING" ), rangeGr, LightApp_Preferences::Bool, "VISU", "scalar_bar_logarithmic" );
+
   int rangetype = addPreference( tr( "VISU_RANGE_TO_USE" ), rangeGr, LightApp_Preferences::Selector, "VISU", "scalar_range_type" );
   QStringList types;
   types.append( tr( "VISU_FIELD_RANGE" ) );
@@ -3478,15 +3937,25 @@ void VisuGUI::createPreferences()
   setPreferenceProperty( rangetype, "strings", types );
   setPreferenceProperty( rangetype, "indexes", indices );
 
-  addPreference( tr( "VISU_LOGARITHMIC_SCALING" ), rangeGr, LightApp_Preferences::Bool, "VISU", "scalar_bar_logarithmic" );
+  int gaussMetric = addPreference( tr( "VISU_GAUSS_METRIC" ), rangeGr, LightApp_Preferences::Selector, "VISU", "scalar_gauss_metric" );
+  QStringList metrics;
+  metrics.append( tr( "VISU_GAUSS_METRIC_AVERAGE" ) );
+  metrics.append( tr( "VISU_GAUSS_METRIC_MINIMUM" ) );
+  metrics.append( tr( "VISU_GAUSS_METRIC_MAXIMUM" ) );
+  indices.clear();
+  indices.append( 0 );
+  indices.append( 1 );
+  indices.append( 2 );
+  setPreferenceProperty( gaussMetric, "strings", metrics );
+  setPreferenceProperty( gaussMetric, "indexes", indices );
 
   int imposedGr = addPreference( tr( "VISU_MINMAX_IMPOSED_RANGE" ), sbarTab );
   setPreferenceProperty( imposedGr, "columns", 4 );
 
-  int min = addPreference( tr( "VISU_MIN" ), imposedGr, LightApp_Preferences::DblSpin, "VISU", "scalar_range_min" );
-  int max = addPreference( tr( "VISU_MAX" ), imposedGr, LightApp_Preferences::DblSpin, "VISU", "scalar_range_max" );
-  setPreferenceProperty( min, "step", 0.1 );
-  setPreferenceProperty( max, "step", 0.1 );
+  int min = addPreference( tr( "VISU_MIN" ), imposedGr, LightApp_Preferences::Double, "VISU", "scalar_range_min" );
+  int max = addPreference( tr( "VISU_MAX" ), imposedGr, LightApp_Preferences::Double, "VISU", "scalar_range_max" );
+  setPreferenceProperty( min, "decimals", qAbs( aResourceMgr->integerValue( "VISU", "visual_data_precision", 0 ) ) );
+  setPreferenceProperty( max, "decimals", qAbs( aResourceMgr->integerValue( "VISU", "visual_data_precision", 0 ) ) );
 
   // group: "Font"
   int fontGr = addPreference( tr( "VISU_FONT" ), sbarTab );
@@ -3508,7 +3977,7 @@ void VisuGUI::createPreferences()
   setPreferenceProperty( numcol, "max", 256 );
 
   addPreference( tr( "VISU_IS_UNITS" ), colorsLabelsGr,
-                LightApp_Preferences::Bool, "VISU", "scalar_bar_display_units" );
+                 LightApp_Preferences::Bool, "VISU", "scalar_bar_display_units" );
 
   int numlab = addPreference( tr( "VISU_NB_LABELS" ), colorsLabelsGr,
                               LightApp_Preferences::IntSpin, "VISU", "scalar_bar_num_labels" );
@@ -3520,9 +3989,10 @@ void VisuGUI::createPreferences()
 
   setPreferenceProperty( lPrec, "min", 1 );
   setPreferenceProperty( lPrec, "max", 100 );
-  
+
   int frame = addPreference( "", sbarTab, LightApp_Preferences::Frame, "", "" );
-  setPreferenceProperty( frame, "orientation", "horizontal" );
+  //setPreferenceProperty( frame, "orientation", "vertical" );
+  setPreferenceProperty( frame, "columns", "2" );
 
   // group: "Orientation"
   int orientGr = addPreference( tr( "VISU_ORIENTATION" ), frame, LightApp_Preferences::GroupBox );
@@ -3544,11 +4014,12 @@ void VisuGUI::createPreferences()
 
 
   // group: "Origin & Size Vertical"
-  int psSzFrame = addPreference( "", sbarTab, LightApp_Preferences::Frame, "", "" );
-  setPreferenceProperty( psSzFrame, "orientation", "horizontal" );
+  //int psSzFrame = addPreference( "", sbarTab, LightApp_Preferences::Frame, "", "" );
+  //setPreferenceProperty( psSzFrame, "orientation", "horizontal" );
+  //setPreferenceProperty( psSzFrame, "columns", "2" );
 
   int posVSizeGr = addPreference( tr( "VISU_ORIGIN_AND_SIZE" ) + " " + tr( "VISU_VERTICAL" ),
-                                 psSzFrame, LightApp_Preferences::GroupBox );
+                                  frame, LightApp_Preferences::GroupBox );
   setPreferenceProperty( posVSizeGr, "columns", 2 );
   int xv = addPreference( tr( "VISU_X" ), posVSizeGr,
                           LightApp_Preferences::DblSpin, "VISU", "scalar_bar_vertical_x" );
@@ -3562,10 +4033,10 @@ void VisuGUI::createPreferences()
 
   int twv = addPreference( tr( "VISU_TITLE_SIZE" ), posVSizeGr,
                           LightApp_Preferences::IntSpin, "VISU", "scalar_bar_vertical_title_size" );
-  
+
   int lwv = addPreference( tr( "VISU_LABEL_SIZE" ), posVSizeGr,
                           LightApp_Preferences::IntSpin, "VISU", "scalar_bar_vertical_label_size" );
-  
+
   int bwv = addPreference( tr( "VISU_BAR_WIDTH" ), posVSizeGr,
                           LightApp_Preferences::IntSpin, "VISU", "scalar_bar_vertical_bar_width" );
   int bhv = addPreference( tr( "VISU_BAR_HEIGHT" ), posVSizeGr,
@@ -3598,7 +4069,7 @@ void VisuGUI::createPreferences()
 
   // group: "Origin & Size Horizontal"
   int posHSizeGr = addPreference( tr( "VISU_ORIGIN_AND_SIZE" ) + " " + tr( "VISU_HORIZONTAL" ),
-                                 psSzFrame, LightApp_Preferences::GroupBox );
+                                  frame, LightApp_Preferences::GroupBox );
   setPreferenceProperty( posHSizeGr, "columns", 2 );
 
   int xh = addPreference( tr( "VISU_X" ), posHSizeGr,
@@ -3613,10 +4084,10 @@ void VisuGUI::createPreferences()
 
   int twh = addPreference( tr( "VISU_TITLE_SIZE" ), posHSizeGr,
                           LightApp_Preferences::IntSpin, "VISU", "scalar_bar_horizontal_title_size" );
-  
+
   int lwh = addPreference( tr( "VISU_LABEL_SIZE" ), posHSizeGr,
                           LightApp_Preferences::IntSpin, "VISU", "scalar_bar_horizontal_label_size" );
-  
+
   int bwh = addPreference( tr( "VISU_BAR_WIDTH" ), posHSizeGr,
                           LightApp_Preferences::IntSpin, "VISU", "scalar_bar_horizontal_bar_width" );
   int bhh = addPreference( tr( "VISU_BAR_HEIGHT" ), posHSizeGr,
@@ -3648,10 +4119,10 @@ void VisuGUI::createPreferences()
   setPreferenceProperty( bhh, "max", 100 );
 
   // TAB: "CutLines"
-  int cutLineTab = addPreference( tr( "CutLines" ) );
+  int cutLineTab = addPreference( tr( "VISU_CUT_LINES_SEGMENT" ) );
 
   // group: "CutLines preferences"
-  int cutLineGr = addPreference( tr( "VISU_CUTLINE_PREF" ), cutLineTab );
+  int cutLineGr = addPreference( tr( "VISU_CUT_LINES_SEGMENT_PREF" ), cutLineTab );
   setPreferenceProperty( cutLineGr, "columns", 1 );
   addPreference( tr( "Show preview" ), cutLineGr, LightApp_Preferences::Bool, "VISU", "show_preview" );
   addPreference( tr( "Invert all curves" ), cutLineGr, LightApp_Preferences::Bool, "VISU", "invert_all_curves" );
@@ -3659,6 +4130,18 @@ void VisuGUI::createPreferences()
   addPreference( tr( "Generate data table" ), cutLineGr, LightApp_Preferences::Bool, "VISU", "generate_data_table" );
   addPreference( tr( "Generate curves" ), cutLineGr, LightApp_Preferences::Bool, "VISU", "generate_curves" );
 
+  // TAB: "StreamLines"
+  int streamLinesTab = addPreference( tr( "VISU_STREAM_LINES" ) );
+
+  // group: "StreamLines preferences"
+  int streamLinesGr = addPreference( tr( "VISU_STREAM_LINES_PREF" ), streamLinesTab );
+  setPreferenceProperty( cutLineGr, "columns", 1 );
+  int usedPoints = addPreference( tr( "VISU_STREAM_LINES_USED_POINTS" ), streamLinesGr,
+                                  LightApp_Preferences::DblSpin, "VISU", "stream_lines_used_points" );
+  setPreferenceProperty( usedPoints, "min",  0 );
+  setPreferenceProperty( usedPoints, "max",  1 );
+  setPreferenceProperty( usedPoints, "step", 0.1 );
+
   // TAB: "Sweep, Animation, 3D Cache"
   int animationTab = addPreference( tr( "Sweep, Animation" ) );
   {
@@ -3666,22 +4149,22 @@ void VisuGUI::createPreferences()
     {
       int cacheGroup = addPreference( tr( "VISU_3DCACHE_PREFERENCES" ), animationTab );
       setPreferenceProperty( cacheGroup, "columns", 2 );
-      
+
       int memory_mode = addPreference( tr( "VISU_MEMORY_MODE" ), cacheGroup,
-                                      LightApp_Preferences::Selector, "VISU", "cache_memory_mode" );
-      
+                                       LightApp_Preferences::Selector, "VISU", "cache_memory_mode" );
+
       modes.clear();
       modes.append( tr( "VISU_MINIMAL" ) );
       modes.append( tr( "VISU_LIMITED" ) );
       setPreferenceProperty( memory_mode, "strings", modes );
-      
+
       indices.clear();
       indices.append( 0 );
       indices.append( 1 );
       setPreferenceProperty( memory_mode, "indexes", indices );
-      
+
       int memory_limit = addPreference( tr( "VISU_MEMORY_LIMIT" ), cacheGroup,
-                                       LightApp_Preferences::IntSpin, "VISU", "cache_memory_limit" );
+                                        LightApp_Preferences::IntSpin, "VISU", "cache_memory_limit" );
       setPreferenceProperty( memory_limit, "min", 1 );
       setPreferenceProperty( memory_limit, "max", 5000 );
       setPreferenceProperty( memory_limit, "step", 10 );
@@ -3690,23 +4173,48 @@ void VisuGUI::createPreferences()
     // group: "Animation preferences"
     {
       int animationGroup = addPreference( tr( "VISU_ANIMATION_PREFERENCES" ), animationTab );
-      setPreferenceProperty( animationGroup, "columns", 3 );
-      
-      int speed = addPreference( tr( "Speed" ), animationGroup, LightApp_Preferences::IntSpin, "VISU", "speed" );
-      addPreference( tr( "Cycled animation" ), animationGroup, LightApp_Preferences::Bool, "VISU", "cycled_animation" );
-      addPreference( tr( "Use proportional timing" ), animationGroup, LightApp_Preferences::Bool, "VISU", "use_proportional_timing" );
-      addPreference( tr( "Clean memory at each frame" ), animationGroup, LightApp_Preferences::Bool, "VISU", "clean_memory_at_each_frame" );
-      
+      setPreferenceProperty( animationGroup, "columns", 1 );
+
+      int speed = addPreference( tr( "Speed" ), animationGroup,
+                                 LightApp_Preferences::IntSpin, "VISU", "speed" );
+      addPreference( tr( "Cycled animation" ), animationGroup,
+                     LightApp_Preferences::Bool, "VISU", "cycled_animation" );
+      addPreference( tr( "Use proportional timing" ), animationGroup,
+                     LightApp_Preferences::Bool, "VISU", "use_proportional_timing" );
+      addPreference( tr( "Clean memory at each frame" ), animationGroup,
+                     LightApp_Preferences::Bool, "VISU", "clean_memory_at_each_frame" );
+
       setPreferenceProperty( speed, "min", 1 );
       setPreferenceProperty( speed, "max", 99 );
+
+      int dump_mode = addPreference( tr( "VISU_DUMP_MODE" ), animationGroup,
+                                     LightApp_Preferences::Selector, "VISU", "dump_mode" );
+
+      modes.clear();
+      modes.append( tr( "VISU_NO_DUMP" ) );
+      modes.append( tr( "VISU_DUMP_PICTURES" ) );
+      modes.append( tr( "VISU_DUMP_VIDEO" ) );
+      setPreferenceProperty( dump_mode, "strings", modes );
+
+      indices.clear();
+      indices.append( 0 );
+      indices.append( 1 );
+      indices.append( 2 );
+      setPreferenceProperty( dump_mode, "indexes", indices );
+
+      int time_stamp_frequency = addPreference( tr( "VISU_TIME_STAMP_FREQUENCY" ), animationGroup,
+                                                LightApp_Preferences::IntSpin, "VISU", "time_stamp_frequency" );
+      setPreferenceProperty( time_stamp_frequency, "min", 1 );
+      setPreferenceProperty( time_stamp_frequency, "max", 100 );
     }
 
     // group: "Sweeping preferences"
     {
       int sweepGroup = addPreference( tr( "VISU_SWEEPING_PREF" ), animationTab );
       setPreferenceProperty( sweepGroup, "columns", 2 );
-      
-      int modeSw = addPreference( tr( "VISU_SWEEPING_MODES" ), sweepGroup, LightApp_Preferences::Selector, "VISU", "sweeping_modes" );
+
+      int modeSw = addPreference( tr( "VISU_SWEEPING_MODES" ), sweepGroup,
+                                  LightApp_Preferences::Selector, "VISU", "sweeping_modes" );
       QStringList sweep_modes;
       sweep_modes.append( tr( "VISU_LINEAR_SWEEP" ) );
       sweep_modes.append( tr( "VISU_COS_SWEEP" ) );
@@ -3717,13 +4225,13 @@ void VisuGUI::createPreferences()
       indices.append( 2 );
       setPreferenceProperty( modeSw, "strings", sweep_modes );
       setPreferenceProperty( modeSw, "indexes", indices );
-      
+
       int timestep   = addPreference( tr( "VISU_TIME_STEP" ), sweepGroup,
-                                     LightApp_Preferences::DblSpin, "VISU", "sweeping_time_step" );
+                                      LightApp_Preferences::DblSpin, "VISU", "sweeping_time_step" );
       /*    int nbcycles   = addPreference( tr( "VISU_NB_CYCLES" ), sweepGroup,
-           LightApp_Preferences::IntSpin, "VISU", "sweeping_number_cycles" );*/
+            LightApp_Preferences::IntSpin, "VISU", "sweeping_number_cycles" );*/
       int nbsteps    = addPreference( tr( "VISU_NB_STEPS" ),  sweepGroup,
-                                     LightApp_Preferences::IntSpin, "VISU", "sweeping_number_steps" );
+                                      LightApp_Preferences::IntSpin, "VISU", "sweeping_number_steps" );
       int rangeSw = addPreference( tr( "VISU_IS2PI" ), sweepGroup, LightApp_Preferences::Selector, "VISU", "sweeping_is2PI" );
       QStringList ranges;
       ranges.append( tr( "PERIOD_PI" ) );
@@ -3733,7 +4241,7 @@ void VisuGUI::createPreferences()
       indices.append( 1 );
       setPreferenceProperty( rangeSw, "strings", ranges );
       setPreferenceProperty( rangeSw, "indexes", indices );
-      
+
       setPreferenceProperty( timestep, "min",  0.1 );
       setPreferenceProperty( timestep, "step", 0.1 );
       setPreferenceProperty( timestep, "max",  1000 );
@@ -3749,12 +4257,12 @@ void VisuGUI::createPreferences()
   setPreferenceProperty( representGr, "columns", 2 );
 
   QStringList mesh_modes;
-  mesh_modes.append( "Points" );
-  mesh_modes.append( "Wireframe" );
-  mesh_modes.append( "Insideframe" );
-  mesh_modes.append( "Surfaceframe" );
-  mesh_modes.append( "Surface" );
-  mesh_modes.append( "Feature edges" );
+  mesh_modes.append( tr("MEN_POINTS") );
+  mesh_modes.append( tr("MEN_WIREFRAME") );
+  mesh_modes.append( tr("MEN_INSIDEFRAME") );
+  mesh_modes.append( tr("MEN_SURFACEFRAME") );
+  mesh_modes.append( tr("MEN_SURFACE") );
+  mesh_modes.append( tr("VISU_FEATURE_EDGES") );
   QList<QVariant> mesh_indices;
   mesh_indices.append( 0 );
   mesh_indices.append( 1 );
@@ -3795,15 +4303,15 @@ void VisuGUI::createPreferences()
   addPreference( tr( "VISU_SHRINK" ), representGr, LightApp_Preferences::Bool, "VISU", "scalar_map_shrink" );
 
   int iso_surfaces_represent = addPreference( tr( "VISU_ISO_SURFACES" ), representGr, LightApp_Preferences::Selector, "VISU", "iso_surfaces_represent" );
-  setPreferenceProperty( iso_surfaces_represent, "strings", modes2 );
-  setPreferenceProperty( iso_surfaces_represent, "indexes", indices2 );
+  setPreferenceProperty( iso_surfaces_represent, "strings", modes1 );
+  setPreferenceProperty( iso_surfaces_represent, "indexes", indices1 );
   int sp = addPreference( "", representGr, LightApp_Preferences::Space );
   setPreferenceProperty( sp, "hstretch", 0 );
   setPreferenceProperty( sp, "vstretch", 0 );
 
   int cut_planes_represent = addPreference( tr( "VISU_CUT_PLANES" ), representGr, LightApp_Preferences::Selector, "VISU", "cut_planes_represent" );
-  setPreferenceProperty( cut_planes_represent, "strings", modes2 );
-  setPreferenceProperty( cut_planes_represent, "indexes", indices2 );
+  setPreferenceProperty( cut_planes_represent, "strings", modes1 );
+  setPreferenceProperty( cut_planes_represent, "indexes", indices1 );
   addPreference( "", representGr, LightApp_Preferences::Space );
 
   int cut_lines_represent = addPreference( tr( "VISU_CUT_LINES" ), representGr, LightApp_Preferences::Selector, "VISU", "cut_lines_represent" );
@@ -3813,6 +4321,13 @@ void VisuGUI::createPreferences()
   setPreferenceProperty( sp, "hstretch", 0 );
   setPreferenceProperty( sp, "vstretch", 0 );
 
+  int cut_segment_represent = addPreference( tr( "VISU_CUT_SEGMENT" ), representGr, LightApp_Preferences::Selector, "VISU", "cut_segment_represent" );
+  setPreferenceProperty( cut_segment_represent, "strings", modes3 );
+  setPreferenceProperty( cut_segment_represent, "indexes", indices3 );
+  sp = addPreference( "", representGr, LightApp_Preferences::Space );
+  setPreferenceProperty( sp, "hstretch", 0 );
+  setPreferenceProperty( sp, "vstretch", 0 );
+
   int deformed_shape_represent = addPreference( tr( "VISU_DEFORMED_SHAPE" ), representGr, LightApp_Preferences::Selector, "VISU", "deformed_shape_represent" );
   setPreferenceProperty( deformed_shape_represent, "strings", modes0 );
   setPreferenceProperty( deformed_shape_represent, "indexes", indices0 );
@@ -3833,8 +4348,8 @@ void VisuGUI::createPreferences()
   setPreferenceProperty( sp, "vstretch", 0 );
 
   int plot3d_represent = addPreference( tr( "VISU_PLOT3D" ), representGr, LightApp_Preferences::Selector, "VISU", "plot3d_represent" );
-  setPreferenceProperty( plot3d_represent, "strings", modes2 );
-  setPreferenceProperty( plot3d_represent, "indexes", indices2 );
+  setPreferenceProperty( plot3d_represent, "strings", modes1 );
+  setPreferenceProperty( plot3d_represent, "indexes", indices1 );
   sp = addPreference( "", representGr, LightApp_Preferences::Space );
   setPreferenceProperty( sp, "hstretch", 0 );
   setPreferenceProperty( sp, "vstretch", 0 );
@@ -3844,13 +4359,62 @@ void VisuGUI::createPreferences()
   setPreferenceProperty( scalar_def_represent, "indexes", indices1 );
   addPreference( tr( "VISU_SHRINK" ), representGr, LightApp_Preferences::Bool, "VISU", "scalar_def_shrink" );
 
-  int point_precision = addPreference( tr( "VISU_FLOATING_POINT_PRECISION" ), representGr,
-                                      LightApp_Preferences::IntSpin, "VISU", "floating_point_precision" );
-  setPreferenceProperty( point_precision, "min", 1 );
-  setPreferenceProperty( point_precision, "max", 16 );
-  setPreferenceProperty( point_precision, "step", 1 );
+  int quadraticmode = addPreference( tr( "QUADRATIC_REPRESENT_MODE" ), representGr, LightApp_Preferences::Selector, "VISU", "quadratic_mode" );
+  QStringList quadraticModes;
+  quadraticModes.append("Lines");
+  quadraticModes.append("Arcs");
+  indices.clear();
+  indices.append( 0 );
+  indices.append( 1 );
+  setPreferenceProperty( quadraticmode, "strings", quadraticModes );
+  setPreferenceProperty( quadraticmode, "indexes", indices );
+
+  int maxAngle = addPreference( tr( "MAX_ARC_ANGLE" ), representGr, LightApp_Preferences::IntSpin,
+                              "VISU", "max_angle" );
+  setPreferenceProperty( maxAngle, "min", 1 );
+  setPreferenceProperty( maxAngle, "max", 90 );
+
+  int elem0DSize = addPreference( tr( "VISU_ELEM0D_SIZE" ), representGr, LightApp_Preferences::IntSpin, "VISU", "elem0d_size" );
+  setPreferenceProperty( elem0DSize, "min", 1 );
+  setPreferenceProperty( elem0DSize, "max", 10 );
+  addPreference( "", representGr, LightApp_Preferences::Space );
+
+  int shrFac = addPreference( tr( "VISU_SHRINK_FACTOR" ), representGr, LightApp_Preferences::IntSpin, "VISU", "shrink_factor" );
+  setPreferenceProperty( shrFac, "min", 20 );
+  setPreferenceProperty( shrFac, "max", 100 );
+  sp = addPreference( "", representGr, LightApp_Preferences::Space );
+  setPreferenceProperty( sp, "hstretch", 0 );
+  setPreferenceProperty( sp, "vstretch", 0 );
+
+  addPreference( tr( "VISU_EDGE_COLOR" ), representGr, LightApp_Preferences::Color, "VISU", "edge_color" );
   addPreference( "", representGr, LightApp_Preferences::Space );
 
+  int typeOfMarker = addPreference( tr( "VISU_TYPE_OF_MARKER" ), representGr, LightApp_Preferences::Selector, "VISU", "type_of_marker" );
+
+  QList<QVariant> aMarkerTypeIndicesList;
+  QList<QVariant> aMarkerTypeIconsList;
+  for ( int i = VTK::MT_POINT; i <= VTK::MT_O_X; i++ ) {
+    QString icoFile = QString( "ICON_VERTEX_MARKER_%1" ).arg( i );
+    QPixmap pixmap = aResourceMgr->loadPixmap( "VTKViewer", tr( qPrintable( icoFile ) ) );
+    aMarkerTypeIndicesList << i;
+    aMarkerTypeIconsList << pixmap;
+  }
+  aMarkerTypeIndicesList << VTK::MT_POINT_SPRITE;
+  aMarkerTypeIconsList << aResourceMgr->loadPixmap( "VISU", tr( "ICON_POINT_SPRITE" ) );
+  setPreferenceProperty( typeOfMarker, "indexes", aMarkerTypeIndicesList );
+  setPreferenceProperty( typeOfMarker, "icons",   aMarkerTypeIconsList );
+
+  int markerScale = addPreference( tr( "VISU_MARKER_SCALE" ), representGr, LightApp_Preferences::Selector, "VISU", "marker_scale" );
+
+  QList<QVariant> aMarkerScaleIndicesList;
+  QStringList     aMarkerScaleValuesList;
+  for ( int i = VISU::MS_10; i <= VISU::MS_70; i++ ) {
+    aMarkerScaleIndicesList << i;
+    aMarkerScaleValuesList  << QString::number( (i-(int)VISU::MS_10)*0.5 + 1.0 );
+  }
+  setPreferenceProperty( markerScale, "strings", aMarkerScaleValuesList );
+  setPreferenceProperty( markerScale, "indexes", aMarkerScaleIndicesList );
+
   addPreference( tr( "VISU_USE_SHADING" ), representGr, LightApp_Preferences::Bool, "VISU", "represent_shading" );
   sp = addPreference( "", representGr, LightApp_Preferences::Space );
   setPreferenceProperty( sp, "hstretch", 0 );
@@ -3862,6 +4426,30 @@ void VisuGUI::createPreferences()
   addPreference( tr( "VISU_AUTOMATIC_FIT_ALL" ), representGr,
                  LightApp_Preferences::Bool, "VISU", "automatic_fit_all" );
 
+  // TAB: Tables ; group: "Tables editing properties"
+  int tablesTab = addPreference( tr( "VISU_TABLES" ) );
+
+  int tablesGr = addPreference( tr( "VISU_TABLES_EDITING_PROPS" ), tablesTab );
+  setPreferenceProperty( tablesGr, "columns", 1 );
+
+  addPreference( tr( "VISU_TABLES_ENABLE_EDITING" ), tablesGr, LightApp_Preferences::Bool, "VISU", "tables_enable_editing" );
+
+  int sortPolicyPref = addPreference( tr( "VISU_TABLES_SORT_POLICY" ), tablesGr, LightApp_Preferences::Selector, "VISU", "tables_sort_policy" );
+  QStringList policies;
+  policies.append( tr( "VISU_TABLES_EMPTY_LOWEST" ) );
+  policies.append( tr( "VISU_TABLES_EMPTY_HIGHEST" ) );
+  policies.append( tr( "VISU_TABLES_EMPTY_FIRST" ) );
+  policies.append( tr( "VISU_TABLES_EMPTY_LAST" ) );
+  policies.append( tr( "VISU_TABLES_EMPTY_IGNORE" ) );
+  indices.clear();
+  indices.append( 0 );
+  indices.append( 1 );
+  indices.append( 2 );
+  indices.append( 3 );
+  indices.append( 4 );
+  setPreferenceProperty( sortPolicyPref, "strings", policies );
+  setPreferenceProperty( sortPolicyPref, "indexes", indices );
+
   // TAB: Feature edges ; group: "Feature edges properties"
   int featureEdgesTab = addPreference( tr( "VISU_FEATURE_EDGES" ) );
 
@@ -3869,7 +4457,7 @@ void VisuGUI::createPreferences()
   setPreferenceProperty( featureEdgesGr, "columns", 2 );
 
   int featureEdgesAnglePref = addPreference( tr( "VISU_FEATURE_EDGES_ANGLE" ), featureEdgesGr,
-                                            LightApp_Preferences::DblSpin, "VISU", "feature_edges_angle" );
+                                             LightApp_Preferences::DblSpin, "VISU", "feature_edges_angle" );
   setPreferenceProperty( featureEdgesAnglePref, "step", 10.0 );
   setPreferenceProperty( featureEdgesAnglePref, "min", 0.0 );
   setPreferenceProperty( featureEdgesAnglePref, "max", 90.0 );
@@ -3879,9 +4467,9 @@ void VisuGUI::createPreferences()
   addPreference( tr( "VISU_SHOW_MANIFOLD_EDGES" ), featureEdgesGr, LightApp_Preferences::Bool, "VISU", "show_manifold_edges" );
   addPreference( tr( "VISU_SHOW_NON_MANIFOLD_EDGES" ), featureEdgesGr, LightApp_Preferences::Bool, "VISU", "show_non_manifold_edges" );
   //addPreference( tr( "VISU_FEATURE_EDGES_COLORING" ), featureEdgesGr, LightApp_Preferences::Bool, "VISU", "feature_edges_coloring" );
-  
+
   // TAB: "Values labels"
-  
+
   int valLblTab = addPreference( tr( "VALUES_LABELING" ) );
 
   // "Font" group
@@ -3892,7 +4480,7 @@ void VisuGUI::createPreferences()
   addVtkFontPref( tr( "LABELS" ), valLblFontGr, "values_labeling_font", true );
 
   // color
-  addPreference( tr( "COLOR" ), valLblFontGr, 
+  addPreference( tr( "COLOR" ), valLblFontGr,
     LightApp_Preferences::Color, "VISU", "values_labeling_color" );
 
 }
@@ -3948,8 +4536,17 @@ void VisuGUI::preferencesChanged( const QString& a, const QString& b)
       aResourceMgr->setValue("VISU", "scalar_bar_horizontal_y", sbY1);
       aResourceMgr->setValue("VISU", "scalar_bar_horizontal_height",sbH);
     }
-  } 
-  
+  }
+  else if(b == "visual_data_precision") {
+    LightApp_Preferences* pref = preferences();
+    QtxPreferenceItem* min = pref->findItem( tr( "VISU_MIN" ), true );
+    QtxPreferenceItem* max = pref->findItem( tr( "VISU_MAX" ), true );
+    if ( min )
+      setPreferenceProperty( min->id(), "decimals", qAbs( aResourceMgr->integerValue( "VISU", "visual_data_precision", 0 ) ) );
+    if ( max )
+      setPreferenceProperty( max->id(), "decimals", qAbs( aResourceMgr->integerValue( "VISU", "visual_data_precision", 0 ) ) );
+  }
+
   if ( !aWarning.isEmpty() ){
     aWarning += "The default values are applied instead.";
     SUIT_MessageBox::warning(GetDesktop(this),
@@ -3961,7 +4558,7 @@ void VisuGUI::preferencesChanged( const QString& a, const QString& b)
 SUIT_ViewManager*
 VisuGUI
 ::getViewManager(const QString& theType,
-                const bool theIsCreate)
+                 const bool theIsCreate)
 {
   return getApp()->getViewManager(theType,theIsCreate);
 }
@@ -4005,13 +4602,13 @@ void VisuGUI::OnPlot3dFromCutPlane()
    if (!anIO.IsNull() && anIO->hasEntry()) {
      aSObject = aCStudy->FindObjectID(anIO->getEntry());
      if ( !aSObject )
-       continue;
+        continue;
      VISU::TObjectInfo anObjectInfo = VISU::GetObjectByEntry(GetAppStudy(this), anIO->getEntry());
      if(VISU::Prs3d_i* aPrsObject = VISU::GetPrs3dFromBase(anObjectInfo.myBase)){
        if (aPrsObject->GetType() == VISU::TCUTPLANES) {
-        aCutPrs = dynamic_cast<VISU::CutPlanes_i*>(aPrsObject);
-        if (aCutPrs)
-          break;
+         aCutPrs = dynamic_cast<VISU::CutPlanes_i*>(aPrsObject);
+         if (aCutPrs)
+           break;
        }
      }
    }
@@ -4026,7 +4623,7 @@ void VisuGUI::OnPlot3dFromCutPlane()
      Storable::TRestoringMap aRestoringMap = Storable::GetStorableMap(aTimeStampSObj);
      VISU::VISUType aType = VISU::Storable::RestoringMap2Type( aRestoringMap );
      if (aType != TTIMESTAMP )
-       return;
+        return;
 
      QString aMeshName = aRestoringMap["myMeshName"];
      QString anEntity = aRestoringMap["myEntityId"];
@@ -4036,51 +4633,50 @@ void VisuGUI::OnPlot3dFromCutPlane()
      int aPos;
      SUIT_ViewWindow* aViewWindow = 0;
 //      if (anIsVVTK) {
-//     aViewWindow = GetViewWindow<VVTK_Viewer>(this);
-//     aPos = GetFreePositionOfDefaultScalarBar(this, dynamic_cast<VVTK_ViewWindow*>(aViewWindow));
+//      aViewWindow = GetViewWindow<VVTK_Viewer>(this);
+//      aPos = GetFreePositionOfDefaultScalarBar(this, dynamic_cast<VVTK_ViewWindow*>(aViewWindow));
 //      } else {
-       aViewWindow = GetViewWindow<SVTK_Viewer>(this);
-       aPos = GetFreePositionOfDefaultScalarBar(this, dynamic_cast<SVTK_ViewWindow*>(GetViewWindow<SVTK_Viewer>(this)));
-       //     }
+        aViewWindow = GetViewWindow<SVTK_Viewer>(this);
+        aPos = GetFreePositionOfDefaultScalarBar(this, dynamic_cast<SVTK_ViewWindow*>(GetViewWindow<SVTK_Viewer>(this)));
+        //     }
      GetResourceMgr()->setValue("VISU", "scalar_bar_position_num", aPos);
 
      VISU::Plot3D_i* aPrs3d =
        CreatePrs3dFromFactory<VISU::Plot3D_i>(this,
-                                             aTimeStampSObj,
-                                             (const char*)aMeshName.toLatin1(),
-                                             (Entity)anEntity.toInt(),
-                                             (const char*)aFieldName.toLatin1(),
-                                             aTimeStampId.toInt(),
-                                             ColoredPrs3d_i::EPublishUnderTimeStamp);
+                                              aTimeStampSObj,
+                                              (const char*)aMeshName.toLatin1(),
+                                              (Entity)anEntity.toInt(),
+                                              (const char*)aFieldName.toLatin1(),
+                                              aTimeStampId.toInt(),
+                                              ColoredPrs3d_i::EPublishUnderTimeStamp);
      if (aPrs3d) {
-       SUIT_ResourceMgr* aResourceMgr = GetResourceMgr();
-       int aValue = aResourceMgr->integerValue("VISU","BuildDefaultPrs3d",0);
-       if (!aValue) {
-         VisuGUI_Plot3DDlg* aDlg = new VisuGUI_Plot3DDlg(this);
-         aDlg->initFromPrsObject(aPrs3d, true);
-         int    aOrient = aCutPrs->GetOrientationType(); // Plot3d has the same orientation type
-         double aRotX = aCutPrs->GetRotateX();
-         double aRotY = aCutPrs->GetRotateY();
-         double aPlanePos = aCutPrs->GetPlanePosition(0);
-         aDlg->setPlane(aOrient, aRotX, aRotY, aPlanePos);
-
-         if (!(runAndWait(aDlg, 0) && (aDlg->storeToPrsObject(aPrs3d)))) {
-           DeletePrs3d(this, aPrs3d);
-           delete aDlg;
-           return;
-         }
-         delete aDlg;
-         UpdateObjBrowser(this, true, aTimeStampSObj);
-       }
-       SVTK_ViewWindow* aSVtkWindow = dynamic_cast<SVTK_ViewWindow*>(aViewWindow);
-       if ( aSVtkWindow ) {
-         PublishInView(this, aPrs3d, aSVtkWindow, /*highlight = */true);
-         aSVtkWindow->onFitAll();
+        SUIT_ResourceMgr* aResourceMgr = GetResourceMgr();
+        int aValue = aResourceMgr->integerValue("VISU","BuildDefaultPrs3d",0);
+        if (!aValue) {
+          VisuGUI_Plot3DDlg* aDlg = new VisuGUI_Plot3DDlg(this);
+          aDlg->initFromPrsObject(aPrs3d, true);
+          int    aOrient = aCutPrs->GetOrientationType(); // Plot3d has the same orientation type
+          double aRotX = aCutPrs->GetRotateX();
+          double aRotY = aCutPrs->GetRotateY();
+          double aPlanePos = aCutPrs->GetPlanePosition(0);
+          aDlg->setPlane(aOrient, aRotX, aRotY, aPlanePos);
+
+          if (!(runAndWait(aDlg, 0) && (aDlg->storeToPrsObject(aPrs3d)))) {
+            DeletePrs3d(this, aPrs3d);
+            delete aDlg;
+            return;
+          }
+          delete aDlg;
+          UpdateObjBrowser(this, true, aTimeStampSObj);
+        }
+        SVTK_ViewWindow* aSVtkWindow = dynamic_cast<SVTK_ViewWindow*>(aViewWindow);
+        if ( aSVtkWindow ) {
+          PublishInView(this, aPrs3d, aSVtkWindow, /*highlight = */true);
+          aSVtkWindow->onFitAll();
 
-         AddScalarBarPosition(this, aSVtkWindow, aPrs3d, aPos);
-       }
-       if (aPrs3d)
-         emit presentationCreated(aPrs3d);
+          AddScalarBarPosition(this, aSVtkWindow, aPrs3d, aPos);
+        }
+        processPresentationCreated(aPrs3d);
      }
    }
    application()->putInfo(QObject::tr("INF_DONE"));
@@ -4222,10 +4818,10 @@ void VisuGUI::OnExportMED()
 
   QFileInfo aFileInfo =
     SUIT_FileDlg::getFileName(GetDesktop(this),
-                             aPath,
-                             aFilter,
-                             tr("MEN_EXPORT_MED"), // "Export To Med File"
-                             false);
+                              aPath,
+                              aFilter,
+                              tr("VISU_MEN_EXPORT_MED"), // "Export To Med File"
+                              false);
 
   QString aFile = aFileInfo.filePath();
   if ( aFile.length() > 0 ) {
@@ -4240,9 +4836,9 @@ void VisuGUI::OnFilterScalars()
 }
 
 /*!
-  \brief SLOT called when "Labeling" popup menu item of presentation is clicked 
-   activates/deactivates labeling of results of the screen. This functionality works 
-   to numbering in SMESH module but is intended for showing results on the screen 
+  \brief SLOT called when "Labeling" popup menu item of presentation is clicked
+   activates/deactivates labeling of results of the screen. This functionality works
+   to numbering in SMESH module but is intended for showing results on the screen
    instead of elements numbers
    \sa OnValuesLabelingParams()
 */
@@ -4256,23 +4852,23 @@ void VisuGUI::OnValuesLabeling()
 
   TSelectionItem aSelectionItem = GetSelectedObjects(this).front();
   VISU::Prs3d_i* aPrs3d = GetPrs3dFromBase(aSelectionItem.myObjectInfo.myBase);
-  if(!aPrs3d)
+  if (!aPrs3d)
     return;
 
   SVTK_ViewWindow* aViewWindow = GetActiveViewWindow<SVTK_ViewWindow>(this);
-  if(!aViewWindow)
+  if (!aViewWindow)
     return;
 
   VISU_Actor* anActor = FindActor(aViewWindow, aPrs3d);
-  if(!anActor)
+  if (!anActor)
     return;
 
-  if( VISU_ScalarMapAct* aScalarMapActor = dynamic_cast<VISU_ScalarMapAct*>(anActor) )
+  if ( VISU_ScalarMapAct* aScalarMapActor = dynamic_cast<VISU_ScalarMapAct*>(anActor) )
   {
     aScalarMapActor->SetValuesLabeled( !aScalarMapActor->GetValuesLabeled() );
     aViewWindow->Repaint();
   }
-  else if( VISU_GaussPtsAct* aGaussPtsAct = dynamic_cast<VISU_GaussPtsAct*>(anActor) )
+  else if ( VISU_GaussPtsAct* aGaussPtsAct = dynamic_cast<VISU_GaussPtsAct*>(anActor) )
   {
     aGaussPtsAct->SetValuesLabeled( !aGaussPtsAct->GetValuesLabeled() );
     aViewWindow->Repaint();
@@ -4280,7 +4876,7 @@ void VisuGUI::OnValuesLabeling()
 }
 
 /*!
-  \brief SLOT called when "Labeling parameters" popup menu item of presentation 
+  \brief SLOT called when "Labeling parameters" popup menu item of presentation
   is clicked launch dialog box for changing parameters of labeling
   \sa OnValuesLabeling()
 */
@@ -4288,7 +4884,7 @@ void VisuGUI::OnValuesLabelingParams()
 {
   Handle(SALOME_InteractiveObject) anIO;
   if ( VISU::Prs3d_i* aPrs3d = GetPrsToModify( this, anIO ) )
-    EditPrs3d<VISU::ColoredPrs3d_i, VisuGUI_ValuesLabelingDlg, 1>(this, anIO, aPrs3d);  
+    EditPrs3d<VISU::ColoredPrs3d_i, VisuGUI_ValuesLabelingDlg, 1>(this, anIO, aPrs3d);
 }
 /*!
   \brief Adds preferences for dfont of VTK viewer
@@ -4297,14 +4893,14 @@ void VisuGUI::OnValuesLabelingParams()
   \param param parameter
   \return identifier of preferences
 */
-int VisuGUI::addVtkFontPref( 
-  const QString& label, 
-  const int pId, 
-  const QString& param, 
+int VisuGUI::addVtkFontPref(
+  const QString& label,
+  const int pId,
+  const QString& param,
   const bool useSize )
 {
   int tfont = addPreference( label, pId, LightApp_Preferences::Font, "VISU", param );
-  
+
   setPreferenceProperty( tfont, "mode", QtxFontEdit::Custom );
 
   QStringList fam;
@@ -4322,3 +4918,211 @@ int VisuGUI::addVtkFontPref(
 
   return tfont;
 }
+
+/*!
+  \brief SLOT called when "2D Quadratic -> Arcs" popup menu item
+  \      of presentation is cliked
+ */
+void VisuGUI::OnArcQuadMode(){
+  ChangeQuadratic2DRepresentation(this,VISU::ARCS);
+}
+
+/*!
+  \brief SLOT called when "2D Quadratic -> Lines" popup menu item
+  \      of presentation is cliked
+ */
+void VisuGUI::OnLineQuadMode(){
+  ChangeQuadratic2DRepresentation(this,VISU::LINES);
+}
+
+/*!
+  \brief Return \c true if object can be renamed
+*/
+bool VisuGUI::renameAllowed( const QString& entry) const {  
+  
+  SalomeApp_Application* app = dynamic_cast< SalomeApp_Application* >( SUIT_Session::session()->activeApplication() );
+  SalomeApp_Study* appStudy = app ? dynamic_cast<SalomeApp_Study*>( app->activeStudy() ) : 0; 
+  SalomeApp_DataObject* obj = appStudy ? dynamic_cast<SalomeApp_DataObject*>(appStudy->findObjectByEntry(entry)) : 0;
+  
+  if(!app || !appStudy || !obj)
+    return false;
+
+  if(appStudy->isComponent(entry) || obj->isReference())
+    return false;
+
+  
+  VISU::TObjectInfo anObjectInfo = VISU::GetObjectByEntry( GetAppStudy(this), qPrintable(entry) );
+  VISU::Base_i* aBase = anObjectInfo.myBase;
+  if(aBase){
+    VISU::VISUType aType = aBase->GetType();
+    if( aType == VISU::TCOLOREDPRS3DHOLDER ) {
+      CORBA::Object_var anObject = ClientSObjectToObject(anObjectInfo.mySObject);
+      VISU::ColoredPrs3dHolder_var aHolder = VISU::ColoredPrs3dHolder::_narrow(anObject);
+      aType = aHolder->GetPrsType();
+    }
+    if (aType == VISU::TSCALARMAP || aType == VISU::TISOSURFACES ||
+        aType == VISU::TDEFORMEDSHAPE || aType == VISU::TCUTPLANES ||
+        aType == VISU::TCUTLINES || aType == VISU::TCUTSEGMENT || aType == VISU::TVECTORS ||
+        aType == VISU::TSTREAMLINES || aType == VISU::TPLOT3D ||
+        aType == VISU::TSCALARMAPONDEFORMEDSHAPE || aType == VISU::TCOLOREDPRS3DHOLDER ||
+        aType == VISU::TTABLE || aType == VISU::TCURVE || aType == VISU::TCONTAINER ||
+        aType == VISU::TPOINTMAP3D || aType == VISU::TVIEW3D ||
+        aType == VISU::TPOINTMAP3D || aType == VISU::TGAUSSPOINTS)
+      return true;
+  } else {
+    VISU::Storable::TRestoringMap aMap = VISU::Storable::GetStorableMap(anObjectInfo.mySObject);
+    bool anIsExist;
+    QString aVal = VISU::Storable::FindValue(aMap, "myComment", &anIsExist);
+    return anIsExist && "VIEW3D" == aVal;
+  }
+  return false;
+}
+
+void VisuGUI::OnShowDeviation() {
+
+  if(IsStudyLocked(GetCStudy(GetAppStudy(this))))
+    return;
+
+  QAction* anAction = action(VISU_SHOW_DEVIATION);
+  if(!anAction)
+    return;
+
+  bool anIsShow = anAction->isChecked();
+
+  VISU::TSelectionInfo aSelectionInfo = VISU::GetSelectedObjects(this);
+  if(aSelectionInfo.empty())
+    return;
+
+  TSelectionInfo::iterator anIter = aSelectionInfo.begin();
+  for( ; anIter != aSelectionInfo.end(); anIter++ )
+  {
+    VISU::TSelectionItem aSelectionItem = *anIter;
+    Handle(SALOME_InteractiveObject) anIO = aSelectionItem.myIO;
+    VISU::Base_i* aBase = aSelectionItem.myObjectInfo.myBase;
+    if(aBase && aBase->GetType() == VISU::TCURVE) {
+      // Curve object
+      if(VISU::Curve_i* aCurve = dynamic_cast<VISU::Curve_i*>(aBase)) {
+        aCurve->ShowDeviation(anIsShow);
+        if( displayer()->IsDisplayed( anIO->getEntry() ) )
+          PlotCurve(this, aCurve, VISU::eDisplay);
+      }
+    }
+  }
+}
+
+/*!
+  Rename object by entry.
+  \param entry entry of the object
+  \param name new name of the object
+  \brief Return \c true if rename operation finished successfully, \c false otherwise.
+*/
+bool VisuGUI::renameObject( const QString& entry, const QString& name) {    
+
+  SalomeApp_Application* app = dynamic_cast< SalomeApp_Application* >( SUIT_Session::session()->activeApplication());
+  SalomeApp_Study* appStudy = app ? dynamic_cast<SalomeApp_Study*>( app->activeStudy() ) : 0;
+  
+  if(!appStudy)
+    return false;
+  
+  _PTR(Study) aStudy = appStudy->studyDS();
+  
+  if(!aStudy)
+    return false;
+  
+  bool aLocked = (_PTR(AttributeStudyProperties)(appStudy->studyDS()->GetProperties()))->IsLocked();
+  if ( aLocked ) {
+    SUIT_MessageBox::warning ( app->desktop(), QObject::tr("WRN_WARNING"), QObject::tr("WRN_STUDY_LOCKED") );
+    return false;
+  }
+  
+  VISU::TObjectInfo anObjectInfo = VISU::GetObjectByEntry(GetAppStudy(this) , qPrintable(entry) );
+  
+  _PTR(SObject) aSObject = anObjectInfo.mySObject;
+  if (aSObject) {
+    VISU::Base_i* aBase = anObjectInfo.myBase;
+    VISU::Storable::TRestoringMap aMap = VISU::Storable::GetStorableMap(anObjectInfo.mySObject);
+    if(aBase){
+      VISU::VISUType aType = aBase->GetType();
+      if( aType == VISU::TCOLOREDPRS3DHOLDER ) {
+       CORBA::Object_var anObject = ClientSObjectToObject(anObjectInfo.mySObject);
+       VISU::ColoredPrs3dHolder_var aHolder = VISU::ColoredPrs3dHolder::_narrow(anObject);
+       aType = aHolder->GetPrsType();
+      }
+      if (aType == VISU::TSCALARMAP || aType == VISU::TISOSURFACES ||
+         aType == VISU::TDEFORMEDSHAPE || aType == VISU::TCUTPLANES ||
+         aType == VISU::TCUTLINES || aType == VISU::TCUTSEGMENT || aType == VISU::TVECTORS ||
+         aType == VISU::TSTREAMLINES || aType == VISU::TPLOT3D ||
+         aType == VISU::TSCALARMAPONDEFORMEDSHAPE || aType == VISU::TCOLOREDPRS3DHOLDER ||
+         aType == VISU::TTABLE || aType == VISU::TCURVE || aType == VISU::TCONTAINER ||
+         aType == VISU::TPOINTMAP3D || aType == VISU::TVIEW3D ||
+         aType == VISU::TPOINTMAP3D || aType == VISU::TGAUSSPOINTS) {
+       _PTR(GenericAttribute) anAttr;
+       if (aSObject->FindAttribute(anAttr, "AttributeName")) {
+         _PTR(AttributeName) aName (anAttr);
+         if (!name.isEmpty()) {
+           QApplication::setOverrideCursor(Qt::WaitCursor);
+           // rename specific objects
+           if (VISU::Base_i* aBase = anObjectInfo.myBase) {
+             switch (aBase->GetType()) {
+             case VISU::TCURVE: { // Curve object
+               if (VISU::Curve_i* aCurve = dynamic_cast<VISU::Curve_i*>(aBase))
+                 aCurve->SetName(qPrintable(name), true);
+               break;
+             }
+             case VISU::TTABLE: { // Table object
+               if (VISU::Table_i* aTable = dynamic_cast<VISU::Table_i*>(aBase))
+                 aTable->SetName(qPrintable(name), true);
+               break;
+             }
+             case VISU::TPOINTMAP3D: { // Table object
+               if (VISU::PointMap3d_i* aTable3d = dynamic_cast<VISU::PointMap3d_i*>(aBase)) {
+                 aTable3d->SetTitle(qPrintable(name));
+                 aTable3d->UpdateActors();
+               }
+               break;
+             }
+             case VISU::TCONTAINER: { // Container object
+               if (VISU::Container_i* aContainer = dynamic_cast<VISU::Container_i*>(aBase))
+                 aContainer->SetName(qPrintable(name), true);
+               break;
+             }
+             default: {
+             }}
+           }
+
+           // rename the study object
+           aName->SetValue( qPrintable(name) ); // rename the SObject
+           
+           ViewManagerList aViewManagerList;
+           getApp()->viewManagers(SPlot2d_Viewer::Type(), aViewManagerList);
+           SUIT_ViewManager* aViewManager;
+           Handle(SALOME_InteractiveObject) anIO = 
+             new SALOME_InteractiveObject ( qPrintable(entry), "VISU", qPrintable(name) );
+           foreach( aViewManager, aViewManagerList ) {
+             if (Plot2d_ViewManager* aManager = dynamic_cast<Plot2d_ViewManager*>(aViewManager)) {
+               if (SPlot2d_Viewer* aViewer = dynamic_cast<SPlot2d_Viewer*>(aManager->getViewModel()))
+                 aViewer->renameAll( anIO, qPrintable(name) );
+             }
+           }
+           QApplication::restoreOverrideCursor();          
+           return true;
+         }
+       }
+       //Rename visual params
+      }
+    } else {
+      bool anIsExist;
+      QString aVal = VISU::Storable::FindValue(aMap, "myComment", &anIsExist);
+      if(anIsExist && "VIEW3D" == aVal) {
+       _PTR(GenericAttribute) anAttr;
+       if (aSObject->FindAttribute(anAttr, "AttributeName")) {
+         _PTR(AttributeName) aName (anAttr);
+         if (!name.isEmpty()) {
+           aName->SetValue(qPrintable(name));
+         }
+       }
+      }
+    }
+  }
+  return false;
+}