ICF 3.0.5.47
Technical documentation of ICF Libraries
iview::IShapeView Class Referenceabstract

Common interface for a general shape view implementations. More...

#include <IShapeView.h>

Inheritance diagram for iview::IShapeView:
Collaboration diagram for iview::IShapeView:

Public Types

typedef IShapeObserver BaseClass
 
- Public Types inherited from iview::IDisplay
enum  ChangeFlags {
  CF_TRANSFORM = 0x3f67360 , CF_COLORS , CF_SIZE , CF_EDIT_MODE ,
  CS_CONSOLE
}
 Define possible display change flags. More...
 
- Public Types inherited from iview::ISelectable
enum  MousePointerMode {
  MPM_NONE , MPM_DEFAULT , MPM_DESELECT , MPM_POINTER ,
  MPM_WAIT , MPM_CROSS , MPM_HAND , MPM_DRAG ,
  MPM_SCREEN_MOVE , MPM_LAST = MPM_SCREEN_MOVE
}
 Defines possible states of mouse pointer. More...
 
enum  EditMode { EM_NONE = 0 , EM_MOVE = 1 , EM_ADD = 2 , EM_REMOVE = 3 }
 Describes standard edit modes. More...
 
typedef QSet< IInteractiveShape * > SelectedShapes
 
- Public Types inherited from iview::ITouchable
enum  TouchState {
  TS_NONE , TS_TRANSPARENT , TS_INACTIVE , TS_TICKER ,
  TS_DRAGGABLE , TS_OTHER , TS_LAST = TS_OTHER
}
 Enumeration for possible shape touch states. More...
 

Public Member Functions

virtual void SetFitArea (const i2d::CRectangle &area)=0
 Set area used for fitting of the view contents.
 
virtual void SetTransform (const i2d::CAffine2d &transform)=0
 Set a screen transformation.
 
virtual void Update ()=0
 Updates all invalidates shapes.
 
virtual void SetEditMode (int mode)=0
 Changes the edit mode.
 
virtual bool IsViewDraggable () const =0
 Check if is draggable mode.
 
virtual bool IsMultiselectable () const =0
 Check, if it is possible to select more than one shape.
 
virtual void UpdateMousePointer ()=0
 Update mouse pointer.
 
virtual int InsertLayer (IViewLayer *layerPtr, int index=-1, int layerType=IViewLayer::LT_NONE)=0
 Insert layer to view.
 
virtual int GetLayerIndex (const IViewLayer &layer) const =0
 Get index of layer.
 
virtual int GetLayerIndex (int layerType) const =0
 Get index of layer by type.
 
virtual void RemoveLayer (int index)=0
 Remove layer from view.
 
virtual int GetLayersCount () const =0
 Get count of layer in this view.
 
virtual IViewLayerGetLayer (int index) const =0
 Get layer with the given index.
 
virtual bool ConnectShape (IShape *shapePtr)=0
 Connect shape object to view.
 
virtual ISelectableLayerGetFocusedLayerPtr () const =0
 Get focused layer.
 
virtual void OnLayerShapeFocused (IInteractiveShape *shapePtr, ISelectableLayer *layerPtr)=0
 Called when shape in layer get focus.
 
virtual void OnLayerShapeDefocused (IInteractiveShape *shapePtr, ISelectableLayer *layerPtr)=0
 Called when shape in layer loose focus.
 
virtual void OnLayerInvalidated (const IViewLayer &layer, const i2d::CRect &prevArea, const i2d::CRect &newArea)=0
 Inform that layer was invalidated.
 
- Public Member Functions inherited from iview::IDisplay
virtual IDisplayGetParentDisplayPtr () const =0
 Get parent object of this display.
 
virtual const iview::CScreenTransformGetTransform () const =0
 Return a screen transformation.
 
virtual i2d::CRect GetBoundingBox () const =0
 Get bounding box of all object in this display.
 
virtual i2d::CRect GetClientRect () const =0
 Get bounding box of client area.
 
virtual const IColorSchemaGetColorSchema () const =0
 Get color schema.
 
virtual void OnAreaInvalidated (const i2d::CRect &prevArea, const i2d::CRect &newArea)=0
 Invalidate display area.
 
- Public Member Functions inherited from iview::IShapeObserver
virtual void OnChangeShape (IShape *shapePtr)=0
 Invalidate a shape.
 
virtual bool DisconnectShape (IShape *shapePtr)=0
 Disconnect shape object from view.
 
- Public Member Functions inherited from iview::ISelectable
virtual int GetSelectedShapesCount () const =0
 Get count of selected shapes.
 
virtual void InsertSelectedShapes (SelectedShapes &result) const =0
 Get set of selected shapes.
 
virtual void DeselectAllShapes ()=0
 Set all shapes to be deselected.
 
virtual int GetKeysState () const =0
 Get state of system keys.
 
virtual int GetEditMode () const =0
 Get actual edit mode.
 
virtual void OnShapeFocused (IInteractiveShape *shapePtr)=0
 Called when shape get focus.
 
virtual void OnShapeDefocused (IInteractiveShape *shapePtr)=0
 Called when shape loose focus.
 
virtual void OnShapeSelected (IInteractiveShape &shape, bool state=true)=0
 It is called after change shape selection state.
 
- Public Member Functions inherited from iview::ITouchable
virtual TouchState IsTouched (istd::CIndex2d position) const =0
 Check, if any shape is touched.
 
virtual QString GetShapeDescriptionAt (istd::CIndex2d position) const =0
 Get description to shape at specified position.
 

Detailed Description

Common interface for a general shape view implementations.

Definition at line 29 of file IShapeView.h.

Member Typedef Documentation

◆ BaseClass

Member Function Documentation

◆ ConnectShape()

virtual bool iview::IShapeView::ConnectShape ( IShape * shapePtr)
pure virtual

Connect shape object to view.

Parameters
shapePtrpointer shape object, will be not owned by this view.
Returns
true, if it was possible to connect this shape.

Implemented in iview::CViewBase.

Referenced by i2dgui::TViewExtenderCompBase< Base >::AddItemsToScene().

◆ GetFocusedLayerPtr()

virtual ISelectableLayer * iview::IShapeView::GetFocusedLayerPtr ( ) const
pure virtual

Get focused layer.

Implemented in iview::CViewBase.

◆ GetLayer()

virtual IViewLayer & iview::IShapeView::GetLayer ( int index) const
pure virtual

Get layer with the given index.

Implemented in iview::CViewBase.

◆ GetLayerIndex() [1/2]

virtual int iview::IShapeView::GetLayerIndex ( const IViewLayer & layer) const
pure virtual

Get index of layer.

Returns
layer index, or -1 if not found.

Implemented in iview::CViewBase.

◆ GetLayerIndex() [2/2]

virtual int iview::IShapeView::GetLayerIndex ( int layerType) const
pure virtual

Get index of layer by type.

Returns
layer index, or -1 if not found.

Implemented in iview::CViewBase.

◆ GetLayersCount()

virtual int iview::IShapeView::GetLayersCount ( ) const
pure virtual

Get count of layer in this view.

Implemented in iview::CViewBase.

◆ InsertLayer()

virtual int iview::IShapeView::InsertLayer ( IViewLayer * layerPtr,
int index = -1,
int layerType = IViewLayer::LT_NONE )
pure virtual

Insert layer to view.

Parameters
layerPtrpointer to inserted layer.
indexindex of inserted layer. If equals -1, layer will be inserted after last existing layer.
layerTypeused to set standard layers.
See also
iview::IShapeView::LayerType
Returns
index of this layer.

Implemented in iview::CCalibratedViewBase, and iview::CViewBase.

◆ IsMultiselectable()

virtual bool iview::IShapeView::IsMultiselectable ( ) const
pure virtual

Check, if it is possible to select more than one shape.

Implemented in iview::CViewBase.

◆ IsViewDraggable()

virtual bool iview::IShapeView::IsViewDraggable ( ) const
pure virtual

Check if is draggable mode.

If this function return true, user can move a view by dragging.

Implemented in iview::CViewBase.

◆ OnLayerInvalidated()

virtual void iview::IShapeView::OnLayerInvalidated ( const IViewLayer & layer,
const i2d::CRect & prevArea,
const i2d::CRect & newArea )
pure virtual

Inform that layer was invalidated.

Implemented in iview::CViewBase.

◆ OnLayerShapeDefocused()

virtual void iview::IShapeView::OnLayerShapeDefocused ( IInteractiveShape * shapePtr,
ISelectableLayer * layerPtr )
pure virtual

Called when shape in layer loose focus.

Implemented in iview::CViewBase.

◆ OnLayerShapeFocused()

virtual void iview::IShapeView::OnLayerShapeFocused ( IInteractiveShape * shapePtr,
ISelectableLayer * layerPtr )
pure virtual

Called when shape in layer get focus.

Implemented in iview::CViewBase.

◆ RemoveLayer()

virtual void iview::IShapeView::RemoveLayer ( int index)
pure virtual

Remove layer from view.

Implemented in iview::CCalibratedViewBase, and iview::CViewBase.

◆ SetEditMode()

virtual void iview::IShapeView::SetEditMode ( int mode)
pure virtual

Changes the edit mode.

Implemented in iview::CViewBase, and iview::CViewport.

◆ SetFitArea()

virtual void iview::IShapeView::SetFitArea ( const i2d::CRectangle & area)
pure virtual

Set area used for fitting of the view contents.

Implemented in iview::CViewBase, and iview::CViewport.

◆ SetTransform()

virtual void iview::IShapeView::SetTransform ( const i2d::CAffine2d & transform)
pure virtual

Set a screen transformation.

See also
GetTransform()

Implemented in iview::CViewBase.

◆ Update()

virtual void iview::IShapeView::Update ( )
pure virtual

Updates all invalidates shapes.

Implemented in iview::CViewBase.

Referenced by i2dgui::TViewExtenderCompBase< Base >::UpdateAllViews().

◆ UpdateMousePointer()

virtual void iview::IShapeView::UpdateMousePointer ( )
pure virtual

Update mouse pointer.

Implemented in iview::CViewBase.


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

© Witold Gantzke and Kirill Lepskiy