Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Plot2d_Histogram Class Reference

#include <Plot2d_Histogram.h>

Inheritance diagram for Plot2d_Histogram:
Inheritance graph

Public Member Functions

 Plot2d_Histogram ()
 
 Plot2d_Histogram (const Plot2d_Histogram &)
 
virtual ~Plot2d_Histogram ()
 
Plot2d_Histogramoperator= (const Plot2d_Histogram &)
 
virtual int rtti ()
 
virtual QwtPlotItemcreatePlotItem ()
 
virtual void autoFill (const QwtPlot *)
 
virtual void updatePlotItem (QwtPlotItem *)
 
void setData (const QList< double > &, const QList< double > &)
 
QwtIntervalSeriesData getData () const
 
void setColor (const QColor &)
 
QColor getColor () const
 
void setWidth (const double)
 
double getWidth (const bool) const
 
- Public Member Functions inherited from Plot2d_Object
 Plot2d_Object ()
 
 Plot2d_Object (const Plot2d_Object &)
 
virtual ~Plot2d_Object ()
 
Plot2d_Objectoperator= (const Plot2d_Object &)
 
virtual QString getTableTitle () const
 
void setHorTitle (const QString &)
 
QString getHorTitle () const
 
void setVerTitle (const QString &)
 
QString getVerTitle () const
 
void setHorUnits (const QString &)
 
QString getHorUnits () const
 
void setVerUnits (const QString &)
 
QString getVerUnits () const
 
void setName (const QString &)
 
QString getName () const
 
void setScale (double)
 
double getScale () const
 
void addPoint (double, double, const QString &=QString())
 
void addPoint (const Plot2d_Point &)
 
void insertPoint (int, double, double, const QString &=QString())
 
void insertPoint (int, const Plot2d_Point &)
 
void deletePoint (int)
 
void clearAllPoints ()
 
pointList getPointList () const
 
void setPointList (const pointList &points)
 
Plot2d_PointgetPoint (int index)
 
void setData (const double *, const double *, long, const QStringList &=QStringList())
 
double * horData () const
 
double * verData () const
 
long getData (double **, double **) const
 
void setText (const int, const QString &)
 
QString text (const int) const
 
int nbPoints () const
 
bool isEmpty () const
 
void setAutoAssign (bool)
 
bool isAutoAssign () const
 
void setXAxis (QwtPlot::Axis)
 
QwtPlot::Axis getXAxis () const
 
void setYAxis (QwtPlot::Axis)
 
QwtPlot::Axis getYAxis () const
 
virtual double getMinX () const
 
virtual double getMaxX () const
 
virtual double getMinY () const
 
virtual double getMaxY () const
 
void setSelected (const bool)
 
bool isSelected () const
 

Static Public Member Functions

static double getMinInterval (const QList< double > &)
 
- Static Public Member Functions inherited from Plot2d_Object
static void setSelectionColor (const QColor &c)
 
static QColor selectionColor ()
 
static void setHighlightedLegendTextColor (const QColor &c)
 
static QColor highlightedLegendTextColor ()
 

Protected Member Functions

QColor getNextColor (const QwtPlot *)
 
bool existColor (const QwtPlot *, const QColor &)
 

Private Attributes

QColor myColor
 
double myWidth
 
double myDefWidth
 

Additional Inherited Members

- Protected Attributes inherited from Plot2d_Object
bool myAutoAssign
 
QString myHorTitle
 
QString myVerTitle
 
QString myHorUnits
 
QString myVerUnits
 
QString myName
 
QwtPlot::Axis myXAxis
 
QwtPlot::Axis myYAxis
 
double myScale
 
pointList myPoints
 
bool myIsSelected
 

Constructor & Destructor Documentation

Plot2d_Histogram::Plot2d_Histogram ( )

Constructor.

Plot2d_Histogram::Plot2d_Histogram ( const Plot2d_Histogram hist)

Copy constructor. Makes deep copy of data.

References myColor, myDefWidth, and myWidth.

Plot2d_Histogram::~Plot2d_Histogram ( )
virtual

Destructor.

Member Function Documentation

void Plot2d_Histogram::autoFill ( const QwtPlot thePlot)
virtual

Auto fill parameters of object by plot view

Reimplemented from Plot2d_Object.

References getNextColor(), and setColor().

QwtPlotItem * Plot2d_Histogram::createPlotItem ( )
virtual

Create plot object for the histogram

Implements Plot2d_Object.

References updatePlotItem().

bool Plot2d_Histogram::existColor ( const QwtPlot thePlot,
const QColor &  theColor 
)
protected

Checks if color is already user by other histogram entity

References Plot2d::closeColors(), Plot2d_HistogramQwtItem::color(), and rtti().

QColor Plot2d_Histogram::getColor ( ) const

Returns color of histogram

References myColor.

QwtIntervalSeriesData Plot2d_Histogram::getData ( ) const

Gets data

References Plot2d_Object::getPointList(), myDefWidth, and myWidth.

double Plot2d_Histogram::getMinInterval ( const QList< double > &  theVals)
static

Return min interval from values

QColor Plot2d_Histogram::getNextColor ( const QwtPlot thePlot)
protected

Gets new unique marker for item if possible

References existColor(), and MAX_ATTEMPTS.

double Plot2d_Histogram::getWidth ( const bool  isDef) const

Returns custom or automatic width for a histogram bar

References myDefWidth, and myWidth.

Plot2d_Histogram & Plot2d_Histogram::operator= ( const Plot2d_Histogram hist)

operator=. Makes deep copy of data.

References myColor, myDefWidth, myWidth, and Plot2d_Object::operator=().

int Plot2d_Histogram::rtti ( )
virtual

Get typeid for the plot2d histogram class

Implements Plot2d_Object.

void Plot2d_Histogram::setColor ( const QColor &  theColor)

Sets color of histogram

References myColor, and Plot2d_Object::setAutoAssign().

void Plot2d_Histogram::setData ( const QList< double > &  theXVals,
const QList< double > &  theYVals 
)

Sets data to object

References getMinInterval(), myDefWidth, myWidth, and Plot2d_Object::setPointList().

void Plot2d_Histogram::setWidth ( const double  theWidth)

Sets custom width of a histogram bar

References myWidth.

Member Data Documentation

QColor Plot2d_Histogram::myColor
private
double Plot2d_Histogram::myDefWidth
private
double Plot2d_Histogram::myWidth
private

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