Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
GraphicsView_Viewer Class Reference

#include <GraphicsView_Viewer.h>

Inheritance diagram for GraphicsView_Viewer:
Inheritance graph

Public Types

enum  TransformType {
  NoTransform, Reset, FitAll, FitRect,
  FitSelect, Zoom, PanGlobal, Pan,
  FitWidth, UserTransform = 100
}
 
- Public Types inherited from SUIT_ViewModel
enum  HotOperation { PAN, ZOOM, ROTATE, FIT_AREA }
 
enum  InteractionStyle { STANDARD, KEY_FREE }
 
typedef QMap< HotOperation,
Qt::KeyboardModifiers > 
StatesMap
 
typedef QMap< HotOperation,
Qt::MouseButtons > 
ButtonsMap
 
typedef QMap< InteractionStyle,
StatesMap
InteractionStyle2StatesMap
 
typedef QMap< InteractionStyle,
ButtonsMap
InteractionStyle2ButtonsMap
 

Signals

void selectionChanged (GV_SelectionChangeStatus)
 
void wheelScaleChanged ()
 

Public Member Functions

 GraphicsView_Viewer (const QString &title, QWidget *widget=NULL)
 
 ~GraphicsView_Viewer ()
 
virtual SUIT_ViewWindowcreateView (SUIT_Desktop *)
 
virtual QString getType () const
 
virtual void contextMenuPopup (QMenu *)
 
GraphicsView_SelectorgetSelector ()
 
GraphicsView_ViewFramegetActiveView () const
 
GraphicsView_ViewPortgetActiveViewPort () const
 
GraphicsView_ScenegetActiveScene () const
 
void activateTransform (int)
 
bool isInitialized () const
 
void setIsInitialized (bool)
 
- Public Member Functions inherited from SUIT_ViewModel
 SUIT_ViewModel ()
 
virtual ~SUIT_ViewModel ()
 
virtual void setViewManager (SUIT_ViewManager *theViewManager)
 
SUIT_ViewManagergetViewManager () const
 

Static Public Member Functions

static QString Type ()
 
- Static Public Member Functions inherited from SUIT_ViewModel
static void setHotButton (InteractionStyle theInteractionStyle, HotOperation theOper, Qt::KeyboardModifiers theState, Qt::MouseButtons theButton)
 
static void getHotButton (InteractionStyle theInteractionStyle, HotOperation theOper, Qt::KeyboardModifiers &theState, Qt::MouseButtons &theButton)
 

Protected Slots

virtual void onKeyEvent (QKeyEvent *)
 
virtual void onMouseEvent (QGraphicsSceneMouseEvent *)
 
virtual void onWheelEvent (QGraphicsSceneWheelEvent *)
 
virtual void onSketchingFinished (QPainterPath)
 
virtual void onSelectionDone (GV_SelectionChangeStatus)
 
virtual void onSelectionCancel ()
 
virtual void onChangeBgColor ()
 

Protected Member Functions

virtual
GraphicsView_ViewTransformer
createTransformer (int)
 
virtual void onTransformationStarted ()
 
virtual void onTransformationFinished ()
 

Protected Attributes

GraphicsView_SelectormySelector
 
GraphicsView_ViewTransformermyTransformer
 
QWidgetmyWidget
 
bool myIsInitialized
 
- Protected Attributes inherited from SUIT_ViewModel
SUIT_ViewManagermyViewManager
 

Private Types

enum  QueueOperation { BringToFront, SendToBack, BringForward, SendBackward }
 

Private Member Functions

void handleKeyPress (QKeyEvent *)
 
void handleKeyRelease (QKeyEvent *)
 
void handleMouseMove (QGraphicsSceneMouseEvent *)
 
void handleMousePress (QGraphicsSceneMouseEvent *)
 
void handleMouseRelease (QGraphicsSceneMouseEvent *)
 
void handleWheel (QGraphicsSceneWheelEvent *)
 
void processQueueOperation (const QueueOperation)
 

Additional Inherited Members

- Static Public Attributes inherited from SUIT_ViewModel
static InteractionStyle2StatesMap myStateMap
 
static InteractionStyle2ButtonsMap myButtonMap
 

Member Enumeration Documentation

Enumerator
BringToFront 
SendToBack 
BringForward 
SendBackward 
Enumerator
NoTransform 
Reset 
FitAll 
FitRect 
FitSelect 
Zoom 
PanGlobal 
Pan 
FitWidth 
UserTransform 

Constructor & Destructor Documentation

GraphicsView_Viewer::GraphicsView_Viewer ( const QString &  title,
QWidget widget = NULL 
)
GraphicsView_Viewer::~GraphicsView_Viewer ( )

References mySelector.

Member Function Documentation

void GraphicsView_Viewer::activateTransform ( int  theType)
void GraphicsView_Viewer::contextMenuPopup ( QMenu thePopup)
virtual

Reimplemented from SUIT_ViewModel.

References onChangeBgColor().

GraphicsView_ViewTransformer * GraphicsView_Viewer::createTransformer ( int  theType)
protectedvirtual
SUIT_ViewWindow * GraphicsView_Viewer::createView ( SUIT_Desktop theDesktop)
virtual

Create new instance of view window on desktop theDesktop.

Return values
SUIT_ViewWindow*- created view window pointer.

Reimplemented from SUIT_ViewModel.

References myWidget, onKeyEvent(), onMouseEvent(), onSketchingFinished(), and onWheelEvent().

GraphicsView_Scene * GraphicsView_Viewer::getActiveScene ( ) const

References getActiveViewPort().

GraphicsView_ViewFrame * GraphicsView_Viewer::getActiveView ( ) const
GraphicsView_ViewPort * GraphicsView_Viewer::getActiveViewPort ( ) const

References getActiveView().

GraphicsView_Selector * GraphicsView_Viewer::getSelector ( )
virtual QString GraphicsView_Viewer::getType ( ) const
inlinevirtual

Reimplemented from SUIT_ViewModel.

void GraphicsView_Viewer::handleKeyPress ( QKeyEvent *  e)
private
void GraphicsView_Viewer::handleKeyRelease ( QKeyEvent *  e)
private
void GraphicsView_Viewer::handleMouseRelease ( QGraphicsSceneMouseEvent *  e)
private
void GraphicsView_Viewer::handleWheel ( QGraphicsSceneWheelEvent *  e)
private
bool GraphicsView_Viewer::isInitialized ( ) const
inline
void GraphicsView_Viewer::onChangeBgColor ( )
protectedvirtualslot

References getActiveViewPort().

void GraphicsView_Viewer::onKeyEvent ( QKeyEvent *  e)
protectedvirtualslot
void GraphicsView_Viewer::onMouseEvent ( QGraphicsSceneMouseEvent *  e)
protectedvirtualslot
void GraphicsView_Viewer::onSelectionCancel ( )
protectedvirtualslot
void GraphicsView_Viewer::onSelectionDone ( GV_SelectionChangeStatus  theStatus)
protectedvirtualslot

References selectionChanged().

void GraphicsView_Viewer::onSketchingFinished ( QPainterPath  thePath)
protectedvirtualslot
void GraphicsView_Viewer::onTransformationFinished ( )
protectedvirtual

References getSelector(), and myTransformer.

void GraphicsView_Viewer::onTransformationStarted ( )
protectedvirtual

References getSelector(), and myTransformer.

void GraphicsView_Viewer::onWheelEvent ( QGraphicsSceneWheelEvent *  e)
protectedvirtualslot

References handleWheel().

void GraphicsView_Viewer::processQueueOperation ( const QueueOperation  )
private
void GraphicsView_Viewer::selectionChanged ( GV_SelectionChangeStatus  )
signal
void GraphicsView_Viewer::setIsInitialized ( bool  theFlag)

References myIsInitialized.

static QString GraphicsView_Viewer::Type ( )
inlinestatic
void GraphicsView_Viewer::wheelScaleChanged ( )
signal

Member Data Documentation

bool GraphicsView_Viewer::myIsInitialized
protected
GraphicsView_Selector* GraphicsView_Viewer::mySelector
protected
GraphicsView_ViewTransformer* GraphicsView_Viewer::myTransformer
protected
QWidget* GraphicsView_Viewer::myWidget
protected

The documentation for this class was generated from the following files: