|
SHAPER
9.15.0
|
A class for providing access of SHAPERGUI functionality to SALOME viewer functionality. More...

Public Types | |
| typedef std::list< std::pair< std::wstring, std::vector< int > > > | TextColor |
| Type for mapping from text to color to display the names lines in different colors. More... | |
Signals | |
| void | lastViewClosed () |
| Signal emitted when last view window is closed. More... | |
| void | tryCloseView (ModuleBase_IViewWindow *theWnd) |
| Signal emitted before view window is closed. More... | |
| void | deleteView (ModuleBase_IViewWindow *theWnd) |
| Signal emitted on delete view window. More... | |
| void | viewCreated (ModuleBase_IViewWindow *theWnd) |
| Signal emitted on creation of view window. More... | |
| void | activated (ModuleBase_IViewWindow *theWnd) |
| Signal emitted on key release. More... | |
| void | mousePress (ModuleBase_IViewWindow *theWnd, QMouseEvent *theEvent) |
| Signal emitted on mouse press. More... | |
| void | mouseRelease (ModuleBase_IViewWindow *theWnd, QMouseEvent *theEvent) |
| Signal emitted on mouse release. More... | |
| void | mouseDoubleClick (ModuleBase_IViewWindow *theWnd, QMouseEvent *theEvent) |
| Signal emitted on mouse double click. More... | |
| void | mouseMove (ModuleBase_IViewWindow *theWnd, QMouseEvent *theEvent) |
| Signal emitted on mouse move. More... | |
| void | keyPress (ModuleBase_IViewWindow *theWnd, QKeyEvent *theEvent) |
| Signal emitted on key press. More... | |
| void | keyRelease (ModuleBase_IViewWindow *theWnd, QKeyEvent *theEvent) |
| Signal emitted on key release. More... | |
| void | selectionChanged () |
| Signal emitted on selection changed. More... | |
| void | contextMenuRequested (QContextMenuEvent *) |
| Signal emitted on selection changed. More... | |
| void | viewTransformed (int theTransformation) |
| Signal emitted on transformation of view point in view window. More... | |
| void | trihedronVisibilityChanged (bool theState) |
| Signal emitted on selection changed. More... | |
Public Member Functions | |
| SHAPERGUI_SalomeViewer (QObject *theParent) | |
| Constructor. More... | |
| virtual | HandleAAISContext () const |
| Returns AIS_InteractiveContext from current OCCViewer. More... | |
| virtual | Handlevv3dViewer () const |
| Retrurns V3d_Vioewer from current viewer. More... | |
| virtual | Handlettrihedron () const |
| Trihedron 3d object shown in the viewer. More... | |
| virtual | HandleaactiveView () const |
| Returns Vsd_View object from currently active view window. More... | |
| virtual QWidget * | activeViewPort () const |
| Returns viewer view port. More... | |
| virtual void | enableSelection (bool isEnabled) |
| Enable or disable selection in the viewer. More... | |
| virtual bool | isSelectionEnabled () const |
| Returns true if selection is enabled. More... | |
| virtual void | enableMultiselection (bool isEnable) |
| Enable or disable multiselection in the viewer. More... | |
| virtual bool | isMultiSelectionEnabled () const |
| Returns true if multiselection is enabled. More... | |
| virtual bool | enableDrawMode (bool isEnabled) |
| Enable or disable draw mode in the viewer. More... | |
| void | reconnectActions (SUIT_ViewWindow *theWindow, const bool theUseSHAPERSlot) |
| For some signals it disconnects the window from usual signal and connect it to the module ones. More... | |
| virtual void | fitAll () |
| Performs the fit all for the active view. More... | |
| virtual void | eraseAll () |
| Erases all presentations from the viewer. More... | |
| virtual void | setViewProjection (double theX, double theY, double theZ, double theTwist) |
| Sets the view projection. More... | |
| virtual void | setViewProjection (double theX, double theY, double theZ, double theUpX, double theUpY, double theUpZ) |
| Sets the view projection and up direction. More... | |
| void | setSelector (SHAPERGUI_OCCSelector *theSel) |
| Set selector. More... | |
| virtual void | addSelectionFilter (const Handle &&theFilter) |
| Add selection filter to the viewer. More... | |
| virtual void | removeSelectionFilter (const Handle &&theFilter) |
| Remove selection filter from the viewer. More... | |
| virtual bool | hasSelectionFilter (const Handle &&theFilter) |
| Returns true if the selection filter is set to the viewer. More... | |
| virtual void | clearSelectionFilters () |
| Remove all selection filters from the viewer. More... | |
| SHAPERGUI_OCCSelector * | selector () const |
| Returns current selector. More... | |
| virtual void | update () |
| Update current viewer. More... | |
| virtual bool | canDragByMouse () const |
| Method returns True if the viewer can process editing objects by mouse drugging. More... | |
| void | activateViewer (bool toActivate) |
| Activate or deactivate viewer. More... | |
| virtual bool | isColorScaleVisible () const |
| Returns True if ColorScale is visible. More... | |
| virtual void | setColorScaleShown (bool on) |
| Show/Hide ColorScale object. More... | |
| virtual void | setColorScalePosition (double theX, double theY) |
| Set position of color scale. More... | |
| virtual void | setColorScaleSize (double theW, double theH) |
| Set size of color scale. More... | |
| virtual void | setColorScaleRange (double theMin, double theMax) |
| Set range of color scale. More... | |
| virtual void | setColorScaleIntervals (int theNb) |
| Set number of intervals of color scale. More... | |
| virtual void | setColorScaleTextHeigth (int theH) |
| Set text height of color scale. More... | |
| virtual void | setColorScaleTextColor (const QColor &theColor) |
| Set color of text of color scale. More... | |
| virtual void | setColorScaleTitle (const QString &theText) |
| Set title of color scale. More... | |
| virtual void | setText (const ModuleBase_IViewer::TextColor &theText, const int theSize) |
| Sets the text displayed in right-top corner of the 3D view. More... | |
| virtual void | setFitter (OCCViewer_Fitter *theFitter) |
| virtual OCCViewer_Fitter * | fitter () const |
| const double | Scale (const Handle &&theView) |
| Returns a scale factor of the given view. More... | |
| void | SetScale (const Handle &&theView, const double theVal) |
| Remember a scale factor for the view object. More... | |
| virtual void | updateHighlight () |
| Fit all along Z (perpendicular to display) More... | |
| void | set2dMode (bool is2d) |
| Set flag which indicates that viewer is used for 2d operations. More... | |
| bool | is2dMode () const |
| Returns current state of 2d mode flag. More... | |
| void | showSelectionHighlight () |
| Switches On additional highlight for objects preselection. More... | |
| void | hideSelectionHighlight () |
| Switches Off additional highlight for objects preselection. More... | |
| virtual void | setFitter (AppElements_Fitter *theFitter)=0 |
Static Public Attributes | |
| static | HandleDDefaultHighlightDrawer |
Protected Attributes | |
| QMap< Handle,, double > | myWindowScale |
| A map for storing a scale factors dependent on view object. More... | |
| bool | myIs2dMode |
| bool | myShowHighlight |
A class for providing access of SHAPERGUI functionality to SALOME viewer functionality.
|
inherited |
Type for mapping from text to color to display the names lines in different colors.
| SHAPERGUI_SalomeViewer::SHAPERGUI_SalomeViewer | ( | QObject * | theParent | ) |
Constructor.
| theParent | a parent object |
|
virtual |
Returns AIS_InteractiveContext from current OCCViewer.
Implements ModuleBase_IViewer.
|
virtual |
Retrurns V3d_Vioewer from current viewer.
Implements ModuleBase_IViewer.
|
virtual |
Trihedron 3d object shown in the viewer.
Implements ModuleBase_IViewer.
|
virtual |
Returns Vsd_View object from currently active view window.
Implements ModuleBase_IViewer.
|
virtual |
Returns viewer view port.
Implements ModuleBase_IViewer.
|
virtual |
Enable or disable selection in the viewer.
Implements ModuleBase_IViewer.
|
virtual |
Returns true if selection is enabled.
Implements ModuleBase_IViewer.
|
virtual |
Enable or disable multiselection in the viewer.
Implements ModuleBase_IViewer.
|
virtual |
Returns true if multiselection is enabled.
Implements ModuleBase_IViewer.
|
virtual |
Enable or disable draw mode in the viewer.
Implements ModuleBase_IViewer.
| void SHAPERGUI_SalomeViewer::reconnectActions | ( | SUIT_ViewWindow * | theWindow, |
| const bool | theUseSHAPERSlot | ||
| ) |
For some signals it disconnects the window from usual signal and connect it to the module ones.
|
virtual |
Performs the fit all for the active view.
Implements ModuleBase_IViewer.
|
virtual |
Erases all presentations from the viewer.
Implements ModuleBase_IViewer.
|
virtual |
Sets the view projection.
| theX | the X projection value |
| theY | the Y projection value |
| theZ | the Z projection value |
| theTwist | the twist angle in radians |
Implements ModuleBase_IViewer.
|
virtual |
Sets the view projection and up direction.
| theX | the X projection value |
| theY | the Y projection value |
| theZ | the Z projection value |
| theUpX | the X value of the up direction vector |
| theUpY | the Y value of the up direction vector |
| theUpZ | the Z value of the up direction vector |
Implements ModuleBase_IViewer.
| void SHAPERGUI_SalomeViewer::setSelector | ( | SHAPERGUI_OCCSelector * | theSel | ) |
Set selector.
| theSel | a selector instance |
|
virtual |
Add selection filter to the viewer.
Implements ModuleBase_IViewer.
|
virtual |
Remove selection filter from the viewer.
Implements ModuleBase_IViewer.
|
virtual |
Returns true if the selection filter is set to the viewer.
| theFilter | a selection filter |
Implements ModuleBase_IViewer.
|
virtual |
Remove all selection filters from the viewer.
|
inline |
Returns current selector.
|
virtual |
Update current viewer.
Implements ModuleBase_IViewer.
|
virtual |
Method returns True if the viewer can process editing objects by mouse drugging.
If this is impossible thet it has to return False.
Reimplemented from ModuleBase_IViewer.
| void SHAPERGUI_SalomeViewer::activateViewer | ( | bool | toActivate | ) |
Activate or deactivate viewer.
| toActivate | - activation flag |
|
virtual |
Returns True if ColorScale is visible.
Implements ModuleBase_IViewer.
|
virtual |
Show/Hide ColorScale object.
Implements ModuleBase_IViewer.
|
virtual |
Set position of color scale.
Implements ModuleBase_IViewer.
|
virtual |
Set size of color scale.
Implements ModuleBase_IViewer.
|
virtual |
Set range of color scale.
Implements ModuleBase_IViewer.
|
virtual |
Set number of intervals of color scale.
Implements ModuleBase_IViewer.
|
virtual |
Set text height of color scale.
Implements ModuleBase_IViewer.
|
virtual |
Set color of text of color scale.
Implements ModuleBase_IViewer.
|
virtual |
Set title of color scale.
Implements ModuleBase_IViewer.
|
virtual |
Sets the text displayed in right-top corner of the 3D view.
| theText | the text to display, or empty string to erase presentation; the first item is the font name and text color |
| theSize | size of the text font |
Implements ModuleBase_IViewer.
|
inlineinherited |
Returns a scale factor of the given view.
| theView | a view object |
|
inlineinherited |
Remember a scale factor for the view object.
| theView | a view object |
| theVal | a scale factor |
|
inlinevirtualinherited |
Fit all along Z (perpendicular to display)
Show highlight for pre-highlighted sub-shape
Reimplemented in XGUI_ViewerProxy.
|
inlineinherited |
Set flag which indicates that viewer is used for 2d operations.
| is2d | a new 2d mode state |
|
inlineinherited |
Returns current state of 2d mode flag.
|
inlineinherited |
Switches On additional highlight for objects preselection.
|
inlineinherited |
Switches Off additional highlight for objects preselection.
|
signalinherited |
Signal emitted when last view window is closed.
|
signalinherited |
Signal emitted before view window is closed.
|
signalinherited |
Signal emitted on delete view window.
|
signalinherited |
Signal emitted on creation of view window.
|
signalinherited |
Signal emitted on key release.
|
signalinherited |
Signal emitted on mouse press.
|
signalinherited |
Signal emitted on mouse release.
|
signalinherited |
Signal emitted on mouse double click.
|
signalinherited |
Signal emitted on mouse move.
|
signalinherited |
Signal emitted on key press.
|
signalinherited |
Signal emitted on key release.
|
signalinherited |
Signal emitted on selection changed.
|
signalinherited |
Signal emitted on selection changed.
|
signalinherited |
Signal emitted on transformation of view point in view window.
| theTransformation | type of transformation (see AppElements_ViewWindow::OperationType) |
|
signalinherited |
Signal emitted on selection changed.
|
protectedinherited |
A map for storing a scale factors dependent on view object.