1 #ifndef SOCC_VIEWMODEL_H
2 #define SOCC_VIEWMODEL_H
5 #pragma warning( disable:4251 )
9 #include "SALOME_Prs.h"
10 #include "OCCViewer_ViewModel.h"
11 #include "SALOME_InteractiveObject.hxx"
13 class SOCC_EXPORT SOCC_Viewer: public OCCViewer_Viewer, public SALOME_View
18 SOCC_Viewer( bool DisplayTrihedron = true );
19 virtual ~SOCC_Viewer();
21 /* Selection management */
22 bool highlight( const Handle(SALOME_InteractiveObject)&, bool, bool=true );
23 bool isInViewer( const Handle(SALOME_InteractiveObject)&, bool=false );
25 void setColor( const Handle(SALOME_InteractiveObject)&, const QColor&, bool=true );
26 void switchRepresentation( const Handle(SALOME_InteractiveObject)&, int, bool=true );
27 void setTransparency( const Handle(SALOME_InteractiveObject)&, float, bool=true );
29 void rename( const Handle(SALOME_InteractiveObject)&, const QString& );
31 /* Reimplemented from SALOME_View */
32 virtual void Display( const SALOME_OCCPrs* );
33 virtual void Erase( const SALOME_OCCPrs*, const bool = false );
34 virtual void EraseAll( const bool = false );
35 virtual SALOME_Prs* CreatePrs( const char* entry = 0 );
36 virtual void BeforeDisplay( SALOME_Displayer* d );
37 virtual void AfterDisplay ( SALOME_Displayer* d );
38 virtual void LocalSelection( const SALOME_OCCPrs*, const int );
39 virtual void GlobalSelection( const bool = false ) const;
40 virtual bool isVisible( const Handle(SALOME_InteractiveObject)& );
41 virtual void Repaint();
43 // a utility function, used by SALOME_View_s methods
44 bool getTrihedronSize( double& theNewSize, double& theSize );
49 #pragma warning( default:4251 )