te::qt::widgets::HistogramChart Class Reference

#include <HistogramChart.h>

Inheritance diagram for te::qt::widgets::HistogramChart:
QwtPlotHistogram

Public Member Functions

void attach (QwtPlot *plot)
 It atttaches a QwtPlot to this Cahrt. More...
 
te::qt::widgets::HistogramgetHistogram ()
 It returns the chart's histogram. More...
 
te::qt::widgets::HistogramStylegetHistogramStyle ()
 Returns a clone of the pointer to the histogram's style. More...
 
StringScaleDrawgetScaleDraw ()
 It returns the chart's scale draw. More...
 
void highlight (const te::da::ObjectIdSet *oids, te::da::DataSetType *dataType)
 Highlights the objects identified by oids. More...
 
te::da::ObjectIdSethighlight (QPointF point)
 Highlights the intervals identified by point. More...
 
te::da::ObjectIdSethighlight (QRectF rect)
 Highlights the intervals contained by rectangle. More...
 
 HistogramChart (Histogram *data, te::qt::widgets::HistogramStyle *style=0)
 Constructor. More...
 
virtual int rtti () const
 Returns the chart's type. More...
 
void setData ()
 
void setHistogram (te::qt::widgets::Histogram *newHistogram)
 It sets the chart's histogram. More...
 
void setHistogramStyle (te::qt::widgets::HistogramStyle *newStyle)
 It sets the chart's style. More...
 
void setScaleDraw (StringScaleDraw *newScaleDraw)
 It sets the chart's scale draw. More...
 
void setSelectionColor (QColor selColor)
 color used to hgihlight selected objects on this chart. More...
 
 ~HistogramChart ()
 Destructor. More...
 

Private Attributes

Histogramm_histogram
 The histogram that will be shown on this chart. More...
 
StringScaleDrawm_histogramScaleDraw
 Scale draw that defines how a label will be displayed on this chart. More...
 
te::qt::widgets::HistogramStylem_histogramStyle
 The histogram's style as displayed by this widget. More...
 
QwtPlotHistogramm_selection
 The PlotItems to be highlighted when a selection occurs;. More...
 

Detailed Description

Definition at line 53 of file HistogramChart.h.

Constructor & Destructor Documentation

te::qt::widgets::HistogramChart::HistogramChart ( Histogram data,
te::qt::widgets::HistogramStyle style = 0 
)

Constructor.

It constructs a histogram chart .

Note
It will take the ownership of the pointer "data".
it will take the ownership of the pointer "style". If style is null, the chart will be constructed with a default style.

Definition at line 51 of file HistogramChart.cpp.

References te::qt::widgets::Config(), te::qt::widgets::HistogramStyle::getFill(), te::qt::widgets::HistogramStyle::getStroke(), m_histogramStyle, m_selection, and setData().

te::qt::widgets::HistogramChart::~HistogramChart ( )

Destructor.

Definition at line 204 of file HistogramChart.cpp.

References m_histogram, m_histogramStyle, and m_selection.

Member Function Documentation

te::qt::widgets::Histogram * te::qt::widgets::HistogramChart::getHistogram ( )

It returns the chart's histogram.

Returns
The chart's histogram.
Note
The caller will not take ownership of the returned pointer.

Definition at line 240 of file HistogramChart.cpp.

References m_histogram.

te::qt::widgets::HistogramStyle * te::qt::widgets::HistogramChart::getHistogramStyle ( )

Returns a clone of the pointer to the histogram's style.

Returns
A HistogramStyle type pointer to the histogram's style.
Note
The caller will take ownership of the returned pointer.

Definition at line 251 of file HistogramChart.cpp.

References te::qt::widgets::HistogramStyle::clone(), and m_histogramStyle.

Referenced by te::qt::widgets::HistogramFrame::setChart().

te::qt::widgets::StringScaleDraw * te::qt::widgets::HistogramChart::getScaleDraw ( )

It returns the chart's scale draw.

Returns
The chart's scale draw.
Note
The caller will not take ownership of the returned pointer.

Definition at line 216 of file HistogramChart.cpp.

References m_histogramScaleDraw.

te::da::ObjectIdSet * te::qt::widgets::HistogramChart::highlight ( QPointF  point)

Highlights the intervals identified by point.

Parameters
pointThe point to be highlighted.

Definition at line 401 of file HistogramChart.cpp.

References te::dt::DATETIME_TYPE, te::qt::widgets::Histogram::find(), te::qt::widgets::Histogram::getType(), te::qt::widgets::StringScaleDraw::label(), m_histogram, m_histogramScaleDraw, and te::dt::STRING_TYPE.

te::da::ObjectIdSet * te::qt::widgets::HistogramChart::highlight ( QRectF  rect)

Highlights the intervals contained by rectangle.

Parameters
rectThe rectangle containing the intervals to be highlighted.

Definition at line 430 of file HistogramChart.cpp.

References te::dt::DATETIME_TYPE, te::qt::widgets::Histogram::find(), te::qt::widgets::Histogram::getType(), te::qt::widgets::StringScaleDraw::label(), m_histogram, m_histogramScaleDraw, and te::dt::STRING_TYPE.

int te::qt::widgets::HistogramChart::rtti ( ) const
virtual

Returns the chart's type.

Definition at line 211 of file HistogramChart.cpp.

References te::qt::widgets::HISTOGRAM_CHART.

void te::qt::widgets::HistogramChart::setHistogram ( te::qt::widgets::Histogram newHistogram)

It sets the chart's histogram.

Parameters
newHistogramThe chart's new histogram.
Note
It will take the ownership of the pointer "newHistogram".

Definition at line 245 of file HistogramChart.cpp.

References m_histogram.

Referenced by te::qt::widgets::RasterSlicingWizardPage::updateHistogram().

void te::qt::widgets::HistogramChart::setHistogramStyle ( te::qt::widgets::HistogramStyle newStyle)

It sets the chart's style.

Parameters
newStyleThe chart's new style.
Note
It will take the ownership of the pointer "newStyle".

Definition at line 256 of file HistogramChart.cpp.

References te::qt::widgets::Config(), te::qt::widgets::HistogramStyle::getFill(), te::qt::widgets::HistogramStyle::getStroke(), and m_histogramStyle.

Referenced by te::qt::widgets::HistogramFrame::getChart().

void te::qt::widgets::HistogramChart::setScaleDraw ( StringScaleDraw newScaleDraw)

It sets the chart's scale draw.

Parameters
new_labelsThe new chart's scale draw.
Note
It will take the ownership of the pointer "newScaleDraw".

Definition at line 221 of file HistogramChart.cpp.

References m_histogramScaleDraw.

void te::qt::widgets::HistogramChart::setSelectionColor ( QColor  selColor)

color used to hgihlight selected objects on this chart.

Parameters
selColorThe color used to hgihlight selected objects on this chart.

Definition at line 463 of file HistogramChart.cpp.

References m_selection.

Referenced by te::qt::widgets::ChartDisplay::setSelectionColor().

Member Data Documentation

Histogram* te::qt::widgets::HistogramChart::m_histogram
private

The histogram that will be shown on this chart.

Definition at line 166 of file HistogramChart.h.

Referenced by attach(), getHistogram(), highlight(), setData(), setHistogram(), and ~HistogramChart().

StringScaleDraw* te::qt::widgets::HistogramChart::m_histogramScaleDraw
private

Scale draw that defines how a label will be displayed on this chart.

Definition at line 167 of file HistogramChart.h.

Referenced by attach(), getScaleDraw(), highlight(), setData(), and setScaleDraw().

te::qt::widgets::HistogramStyle* te::qt::widgets::HistogramChart::m_histogramStyle
private

The histogram's style as displayed by this widget.

Definition at line 168 of file HistogramChart.h.

Referenced by getHistogramStyle(), HistogramChart(), setData(), setHistogramStyle(), and ~HistogramChart().

QwtPlotHistogram* te::qt::widgets::HistogramChart::m_selection
private

The PlotItems to be highlighted when a selection occurs;.

Definition at line 169 of file HistogramChart.h.

Referenced by highlight(), HistogramChart(), setSelectionColor(), and ~HistogramChart().


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