From: dmv Date: Tue, 27 Jan 2009 13:34:28 +0000 (+0000) Subject: 0020137: EDF 931 VISU : Trihedron Issues X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=d392c0d68832bd2498b6e85b0a054261e72f642a;p=modules%2Fgui.git 0020137: EDF 931 VISU : Trihedron Issues --- diff --git a/src/OCCViewer/OCCViewer_ViewWindow.cxx b/src/OCCViewer/OCCViewer_ViewWindow.cxx index b36d156ea..a366dfbb5 100755 --- a/src/OCCViewer/OCCViewer_ViewWindow.cxx +++ b/src/OCCViewer/OCCViewer_ViewWindow.cxx @@ -1564,15 +1564,14 @@ void OCCViewer_ViewWindow::setVisualParameters( const QString& parameters ) params.scaleX = paramsLst[13].toDouble(); params.scaleY = paramsLst[14].toDouble(); params.scaleZ = paramsLst[15].toDouble(); + params.isVisible = paramsLst[16].toDouble(); + params.size = paramsLst[17].toDouble(); } else { params.scaleX = 1.; params.scaleY = 1.; params.scaleZ = 1.; } - params.isVisible = paramsLst[16].toDouble(); - params.size = paramsLst[17].toDouble(); - performRestoring( params ); } } diff --git a/src/SVTK/SVTK_ViewWindow.cxx b/src/SVTK/SVTK_ViewWindow.cxx index 76499b925..e6ef8c945 100755 --- a/src/SVTK/SVTK_ViewWindow.cxx +++ b/src/SVTK/SVTK_ViewWindow.cxx @@ -936,7 +936,8 @@ QtxAction* SVTK_ViewWindow::getAction( int id ) const // 76 values for graduated axes, so both numbers are processed. const int nNormalParams = 13; // number of view windows parameters excluding graduated axes params const int nGradAxisParams = 25; // number of parameters of ONE graduated axis (X, Y, or Z) -const int nAllParams = nNormalParams + 3*nGradAxisParams + 1; // number of all visual parameters +const int nTrihedronParams = 3; // number of parameters for Trihedron +const int nAllParams = nNormalParams + 3*nGradAxisParams + nTrihedronParams + 1; // number of all visual parameters /*! The method returns visual parameters of a graduated axis actor (x,y,z axis of graduated axes) */ @@ -1377,7 +1378,6 @@ void SVTK_ViewWindow::doSetVisualParameters( const QString& parameters ) // apply graduated axes parameters SVTK_CubeAxesActor2D* gradAxesActor = GetCubeAxes(); if ( gradAxesActor && paramsLst.size() == nAllParams ) { - int i = nNormalParams+1, j = i + nGradAxisParams - 1; ::setGradAxisVisualParams( gradAxesActor->GetXAxisActor2D(), parameters.section( '*', i, j ) ); i = j + 1; j += nGradAxisParams; @@ -1389,13 +1389,13 @@ void SVTK_ViewWindow::doSetVisualParameters( const QString& parameters ) gradAxesActor->VisibilityOn(); else gradAxesActor->VisibilityOff(); - - if ( paramsLst[14].toUShort() ) + } else if ( paramsLst.size() == nAllParams ) { + if ( paramsLst[90].toUShort() ) GetTrihedron()->VisibilityOn(); else GetTrihedron()->VisibilityOff(); - SetTrihedronSize(paramsLst[15].toDouble()); + SetTrihedronSize(paramsLst[91].toDouble()); } } }