Home  · Classes  · Annotated Classes  · Modules  · Members  · Namespaces  · Related Pages
Public Member Functions | Protected Attributes

Annotation1DTextItem Class Reference

An annotation item which represents an arbitrary text on the canvas. More...

#include <OpenMS/VISUAL/ANNOTATION/Annotation1DTextItem.h>

Inheritance diagram for Annotation1DTextItem:
Annotation1DItem

List of all members.

Public Member Functions

 Annotation1DTextItem (const PointType &position, const QString &text, const int flags=Qt::AlignCenter)
 Constructor.
 Annotation1DTextItem (const Annotation1DTextItem &rhs)
 Copy constructor.
virtual ~Annotation1DTextItem ()
 Destructor.
virtual void ensureWithinDataRange (Spectrum1DCanvas *const canvas)
 Ensures that the item has coordinates within the visible area of the canvas.
virtual void draw (Spectrum1DCanvas *const canvas, QPainter &painter, bool flipped=false)
 Draws the item on painter.
virtual void move (const PointType &delta)
 Moves the item; behaviour depends on item type and is implemented in the subclasses.
void setPosition (const PointType &position)
 Sets the position of the item (in MZ / intensity coordinates).
const PointTypegetPosition () const
 Returns the position of the item (in MZ / intensity coordinates).
void setFlags (int flags)
 Set Qt flags (default: Qt::AlignCenter).
int getFlags () const
 Get Qt flags.

Protected Attributes

PointType position_
 The position of the item (in MZ / intensity coordinates).
int flags_

Detailed Description

An annotation item which represents an arbitrary text on the canvas.

See also:
Annotation1DItem

Constructor & Destructor Documentation

Annotation1DTextItem ( const PointType position,
const QString &  text,
const int  flags = Qt::AlignCenter 
)

Constructor.

Copy constructor.

virtual ~Annotation1DTextItem (  )  [virtual]

Destructor.


Member Function Documentation

virtual void draw ( Spectrum1DCanvas *const   canvas,
QPainter &  painter,
bool  flipped = false 
) [virtual]

Draws the item on painter.

Implements Annotation1DItem.

virtual void ensureWithinDataRange ( Spectrum1DCanvas *const   canvas  )  [virtual]

Ensures that the item has coordinates within the visible area of the canvas.

Implements Annotation1DItem.

int getFlags (  )  const

Get Qt flags.

const PointType& getPosition (  )  const

Returns the position of the item (in MZ / intensity coordinates).

virtual void move ( const PointType delta  )  [virtual]

Moves the item; behaviour depends on item type and is implemented in the subclasses.

Implements Annotation1DItem.

void setFlags ( int  flags  ) 

Set Qt flags (default: Qt::AlignCenter).

void setPosition ( const PointType position  ) 

Sets the position of the item (in MZ / intensity coordinates).


Member Data Documentation

int flags_ [protected]
PointType position_ [protected]

The position of the item (in MZ / intensity coordinates).


OpenMS / TOPP release 1.10.0 Documentation generated on Thu Mar 7 2013 09:42:57 using doxygen 1.7.1