From: asl Date: Wed, 17 Sep 2014 11:44:49 +0000 (+0000) Subject: refs #453: scalar bar is invisible X-Git-Tag: master_20140917~2 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=9f7b45d044e701442d0b370e9779299d25a5d44c;p=modules%2Fhydro.git refs #453: scalar bar is invisible --- diff --git a/src/HYDROGUI/HYDROGUI_VTKPrsDisplayer.cxx b/src/HYDROGUI/HYDROGUI_VTKPrsDisplayer.cxx index b096a067..97815262 100644 --- a/src/HYDROGUI/HYDROGUI_VTKPrsDisplayer.cxx +++ b/src/HYDROGUI/HYDROGUI_VTKPrsDisplayer.cxx @@ -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 ); }