]> SALOME platform Git repositories - modules/hydro.git/commitdiff
Salome HOME
refs #453: scalar bar is invisible
authorasl <asl@opencascade.com>
Wed, 17 Sep 2014 11:44:49 +0000 (11:44 +0000)
committerasl <asl@opencascade.com>
Wed, 17 Sep 2014 11:44:49 +0000 (11:44 +0000)
src/HYDROGUI/HYDROGUI_VTKPrsDisplayer.cxx

index b096a067269bf316943b42c05495e80ab8ce7197..97815262b84980fb0a757efdcbcd4ab17f9c0ca1 100644 (file)
@@ -398,6 +398,10 @@ void HYDROGUI_VTKPrsDisplayer::createScalarBar( const int theViewId )
     aScalarBar->SetNumberOfLabels( NB_COLORS * 0.75 );
     aScalarBar->SetWidth( aScalarBar->GetWidth() / 1.5 );
     aScalarBar->SetTextureGridWidth( aScalarBar->GetTextureGridWidth() * 4. );
+    aScalarBar->SetTitle( "  " );
+    // The call of SetTitle() with dummy string is a workaround necessary
+    // to avoid the problem with uninitialized variables in VTK scalar bar actor
+    // which leads to incorrect (very big) size of the VTK scalar bar presentation
     aTable->Delete();
     myScalarBars.insert( theViewId, aScalarBar );
   }