Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
QmitkHistogram Class Reference

Used to create a histogram that can be shown in a Qwt Plot. See QmitkHistogramWidget for an example of its usage. More...

#include <QmitkHistogram.h>

Inheritance diagram for QmitkHistogram:
Collaboration diagram for QmitkHistogram:

Public Member Functions

 QmitkHistogram (const QString &title=QString::null)
 
 QmitkHistogram (const QwtText &title)
 
virtual ~QmitkHistogram ()
 
void setData (const QwtIntervalSeriesData &data)
 
const QwtIntervalSeriesData & data () const
 
void setColor (const QColor &)
 
QColor color () const
 
virtual QRectF boundingRect () const override
 
virtual void draw (QPainter *, const QwtScaleMap &xMap, const QwtScaleMap &yMap, const QRectF &) const override
 
void setBaseline (double reference)
 
double baseline () const
 

Protected Member Functions

virtual void drawBar (QPainter *, Qt::Orientation o, const QRect &) const
 

Detailed Description

Used to create a histogram that can be shown in a Qwt Plot. See QmitkHistogramWidget for an example of its usage.

Definition at line 31 of file QmitkHistogram.h.

Constructor & Destructor Documentation

QmitkHistogram::QmitkHistogram ( const QString &  title = QString::null)
explicit

Definition at line 37 of file QmitkHistogram.cpp.

QmitkHistogram::QmitkHistogram ( const QwtText &  title)
explicit

Definition at line 32 of file QmitkHistogram.cpp.

QmitkHistogram::~QmitkHistogram ( )
virtual

Definition at line 42 of file QmitkHistogram.cpp.

Member Function Documentation

double QmitkHistogram::baseline ( ) const

Definition at line 67 of file QmitkHistogram.cpp.

Referenced by draw().

QRectF QmitkHistogram::boundingRect ( ) const
overridevirtual

Definition at line 97 of file QmitkHistogram.cpp.

QColor QmitkHistogram::color ( ) const

Definition at line 92 of file QmitkHistogram.cpp.

Referenced by drawBar(), and setColor().

const QwtIntervalSeriesData & QmitkHistogram::data ( ) const

Definition at line 78 of file QmitkHistogram.cpp.

void QmitkHistogram::draw ( QPainter *  painter,
const QwtScaleMap &  xMap,
const QwtScaleMap &  yMap,
const QRectF &   
) const
overridevirtual

Definition at line 111 of file QmitkHistogram.cpp.

References baseline(), and drawBar().

void QmitkHistogram::drawBar ( QPainter *  painter,
Qt::Orientation  o,
const QRect &  rect 
) const
protectedvirtual

Definition at line 149 of file QmitkHistogram.cpp.

References color().

Referenced by draw().

void QmitkHistogram::setBaseline ( double  reference)

Definition at line 58 of file QmitkHistogram.cpp.

void QmitkHistogram::setColor ( const QColor &  color)

Definition at line 83 of file QmitkHistogram.cpp.

References color().

void QmitkHistogram::setData ( const QwtIntervalSeriesData &  data)

Definition at line 72 of file QmitkHistogram.cpp.


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