OpenStructure
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions
PointlistOverlay Class Reference

#include <pointlist_overlay.hh>

Inherits PointlistOverlayBase.

Public Member Functions

 PointlistOverlay (const String &name="Pointlist")
 
 PointlistOverlay (const PointList &pl, const String &name="Pointlist")
 
virtual void OnMenuEvent (QAction *e)
 
virtual void OnDraw (QPainter &pnt, DataViewerPanel *dvp, bool is_active)
 
virtual bool OnMouseEvent (QMouseEvent *e, DataViewerPanel *dvp, const QPoint &lastmouse)
 
void Add (const Point &pnt, double scale=1.0)
 
void Add (const PointList &pl, double scale=1.0)
 
void Remove (const Point &pnt)
 
void Clear ()
 
- Public Member Functions inherited from PointlistOverlayBase
 PointlistOverlayBase (const String &name)
 
virtual QMenu * GetMenu ()
 
virtual void DrawPointList (QPainter &pnt, DataViewerPanel *dvp, const QColor &col, const std::vector< QPoint > &pointlist)
 
virtual void DrawVariableSizePointList (QPainter &pnt, DataViewerPanel *dvp, const QColor &col, const std::vector< std::pair< QPoint, double > > &pointlist)
 
unsigned int GetSymbolSize () const
 
void SetSymbolSize (unsigned int symbolsize)
 
unsigned int GetSymbolShape () const
 
void SetSymbolShape (unsigned int symbolshape)
 
bool GetCrosshair () const
 
void SetCrosshair (bool flag)
 
void SetActiveColor (const QColor &col)
 
void SetPassiveColor (const QColor &col)
 
- Public Member Functions inherited from Overlay
 Overlay (const String &name)
 
void SetName (const String &name)
 
String GetName () const
 
virtual bool OnKeyEvent (QKeyEvent *e, DataViewerPanel *dvp)
 

Additional Inherited Members

- Public Slots inherited from Overlay
void OnMenuEventSlot (QAction *e)
 
- Signals inherited from Overlay
void SettingsChanged ()
 
void InfoTextChanged (const QString &t)
 
- Protected Member Functions inherited from PointlistOverlayBase
void SetProps (PointlistOverlayBaseSettings *props)
 
- Protected Attributes inherited from PointlistOverlayBase
SymbolDrawingStrategyPtr strategy_
 
QColor active_color_
 
QColor passive_color_
 
unsigned int symbolsize_
 
unsigned int symbolstrength_
 
QMenu * menu_
 
QAction * a_sq_
 
QAction * a_ci_
 
QAction * a_cr_
 
QAction * a_settings_
 

Detailed Description

Definition at line 36 of file pointlist_overlay.hh.

Constructor & Destructor Documentation

PointlistOverlay ( const String name = "Pointlist")
PointlistOverlay ( const PointList pl,
const String name = "Pointlist" 
)

Member Function Documentation

void Add ( const Point pnt,
double  scale = 1.0 
)
void Add ( const PointList pl,
double  scale = 1.0 
)
void Clear ( )
virtual void OnDraw ( QPainter &  pnt,
DataViewerPanel dvp,
bool  is_active 
)
virtual

call when redrawing is necessary

params: the drawing context, the parent data viewer, as well as a flag to indicate wether this overlay is currently active

Reimplemented from PointlistOverlayBase.

virtual void OnMenuEvent ( QAction *  e)
virtual

Reimplemented from PointlistOverlayBase.

virtual bool OnMouseEvent ( QMouseEvent *  e,
DataViewerPanel dvp,
const QPoint &  lastmouse 
)
virtual

mouse event handler

if an overlay is active, it receives the mouse events. if it handles the event for itself, it should return true, otherwise false should be returned to give the data viewer a chance to handle the event for itself

Reimplemented from Overlay.

void Remove ( const Point pnt)

remove all points on the given point


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