Public Slots | Signals | Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | Friends
UPlotCurve Class Reference

#include <UPlot.h>

Inheritance diagram for UPlotCurve:
Inheritance graph
[legend]

List of all members.

Public Slots

void addValue (UPlotItem *data)
void addValue (float y)
void addValue (float x, float y)
void addValue (const QString &y)
void addValues (QVector< UPlotItem * > &data)
void addValues (const QVector< float > &xs, const QVector< float > &ys)
void addValues (const QVector< float > &ys)
void addValues (const QVector< int > &ys)
void addValues (const std::vector< float > &ys)
void addValues (const std::vector< int > &ys)
virtual void clear ()
void setData (const QVector< float > &x, const QVector< float > &y)
void setData (const std::vector< float > &x, const std::vector< float > &y)
void setData (const QVector< float > &y)
void setData (const std::vector< float > &y)
void setVisible (bool visible)
void setXIncrement (float increment)
void setXStart (float val)

Signals

void dataChanged (const UPlotCurve *)

Public Member Functions

const QBrush & brush () const
void draw (QPainter *painter, const QRect &limits)
void getData (QVector< float > &x, QVector< float > &y) const
void getData (QMap< float, float > &data) const
QPointF getItemData (int index)
bool isVisible () const
QColor itemsColor () const
int itemsSize () const
QString name () const
const QPen & pen () const
void setBrush (const QBrush &brush)
void setData (QVector< UPlotItem * > &data)
void setItemsColor (const QColor &color)
void setPen (const QPen &pen)
 UPlotCurve (const QString &name, QObject *parent=0)
 UPlotCurve (const QString &name, const QVector< UPlotItem * > data, QObject *parent=0)
 UPlotCurve (const QString &name, const QVector< float > &x, const QVector< float > &y, QObject *parent=0)
virtual ~UPlotCurve ()

Protected Member Functions

void _addValue (UPlotItem *data)
void attach (UPlot *plot)
void detach (UPlot *plot)
const QVector< float > & getMinMax () const
virtual bool isMinMaxValid () const
int removeItem (int index)
virtual void update (float scaleX, float scaleY, float offsetX, float offsetY, float xDir, float yDir, int maxItemsKept)
void updateMinMax ()

Protected Attributes

QList< QGraphicsItem * > _items
UPlot_plot

Private Member Functions

void removeItem (UPlotItem *item)

Private Attributes

QBrush _brush
QColor _itemsColor
QVector< float > _minMax
QString _name
QPen _pen
QGraphicsRectItem * _rootItem
bool _valuesShown
bool _visible
float _xIncrement
float _xStart

Friends

class UPlot

Detailed Description

UPlotCurve is a curve used to hold data shown in a UPlot.

Definition at line 91 of file UPlot.h.


Constructor & Destructor Documentation

UPlotCurve::UPlotCurve ( const QString &  name,
QObject *  parent = 0 
)

Constructor 1

Definition at line 254 of file UPlot.cpp.

UPlotCurve::UPlotCurve ( const QString &  name,
const QVector< UPlotItem * >  data,
QObject *  parent = 0 
)

Constructor 2

UPlotCurve::UPlotCurve ( const QString &  name,
const QVector< float > &  x,
const QVector< float > &  y,
QObject *  parent = 0 
)

Constructor 3

Definition at line 281 of file UPlot.cpp.

UPlotCurve::~UPlotCurve ( ) [virtual]

Definition at line 295 of file UPlot.cpp.


Member Function Documentation

void UPlotCurve::_addValue ( UPlotItem data) [protected]

Definition at line 374 of file UPlot.cpp.

void UPlotCurve::addValue ( UPlotItem data) [slot]

Add a single value, using a custom UPlotItem.

Definition at line 420 of file UPlot.cpp.

void UPlotCurve::addValue ( float  y) [slot]

Add a single value y, x is auto-incremented by the increment set with setXIncrement().

See also:
setXStart()

Definition at line 446 of file UPlot.cpp.

void UPlotCurve::addValue ( float  x,
float  y 
) [slot]

Add a single value y at x.

Definition at line 430 of file UPlot.cpp.

void UPlotCurve::addValue ( const QString &  y) [slot]

For convenience... Add a single value y, x is auto-incremented by the increment set with setXIncrement().

See also:
setXStart()

Definition at line 461 of file UPlot.cpp.

void UPlotCurve::addValues ( QVector< UPlotItem * > &  data) [slot]

For convenience... Add multiple values, using custom UPlotItem.

Definition at line 475 of file UPlot.cpp.

void UPlotCurve::addValues ( const QVector< float > &  xs,
const QVector< float > &  ys 
) [slot]

Add multiple values y at x. Vectors must have the same size.

Definition at line 484 of file UPlot.cpp.

void UPlotCurve::addValues ( const QVector< float > &  ys) [slot]

Add multiple values y, x is auto-incremented by the increment set with setXIncrement().

See also:
setXStart()

Definition at line 494 of file UPlot.cpp.

void UPlotCurve::addValues ( const QVector< int > &  ys) [slot]

Definition at line 514 of file UPlot.cpp.

void UPlotCurve::addValues ( const std::vector< float > &  ys) [slot]

Add multiple values y, x is auto-incremented by the increment set with setXIncrement().

See also:
setXStart()

Definition at line 554 of file UPlot.cpp.

void UPlotCurve::addValues ( const std::vector< int > &  ys) [slot]

Definition at line 534 of file UPlot.cpp.

void UPlotCurve::attach ( UPlot plot) [protected]

Definition at line 308 of file UPlot.cpp.

const QBrush& UPlotCurve::brush ( ) const [inline]

Get brush.

Definition at line 117 of file UPlot.h.

void UPlotCurve::clear ( ) [virtual, slot]

Clear curve's values.

Reimplemented in rtabmap::PdfPlotCurve.

Definition at line 650 of file UPlot.cpp.

void UPlotCurve::dataChanged ( const UPlotCurve ) [signal]

emitted when data is changed.

void UPlotCurve::detach ( UPlot plot) [protected]

Definition at line 322 of file UPlot.cpp.

void UPlotCurve::draw ( QPainter *  painter,
const QRect &  limits 
)

Definition at line 765 of file UPlot.cpp.

void UPlotCurve::getData ( QVector< float > &  x,
QVector< float > &  y 
) const

Definition at line 1002 of file UPlot.cpp.

void UPlotCurve::getData ( QMap< float, float > &  data) const

Definition at line 1019 of file UPlot.cpp.

QPointF UPlotCurve::getItemData ( int  index)

Definition at line 842 of file UPlot.cpp.

const QVector<float>& UPlotCurve::getMinMax ( ) const [inline, protected]

Definition at line 233 of file UPlot.h.

virtual bool UPlotCurve::isMinMaxValid ( ) const [inline, protected, virtual]

Reimplemented in UPlotCurveThreshold.

Definition at line 236 of file UPlot.h.

bool UPlotCurve::isVisible ( ) const [inline]

Definition at line 140 of file UPlot.h.

QColor UPlotCurve::itemsColor ( ) const [inline]

Definition at line 129 of file UPlot.h.

int UPlotCurve::itemsSize ( ) const

Get the number of items in the curve (dot + line items).

Definition at line 837 of file UPlot.cpp.

QString UPlotCurve::name ( ) const [inline]

Get name.

Definition at line 134 of file UPlot.h.

const QPen& UPlotCurve::pen ( ) const [inline]

Get pen.

Definition at line 113 of file UPlot.h.

int UPlotCurve::removeItem ( int  index) [protected]

Definition at line 574 of file UPlot.cpp.

void UPlotCurve::removeItem ( UPlotItem item) [private]

Definition at line 626 of file UPlot.cpp.

void UPlotCurve::setBrush ( const QBrush &  brush)

Set brush.

Definition at line 668 of file UPlot.cpp.

void UPlotCurve::setData ( QVector< UPlotItem * > &  data)

Definition at line 876 of file UPlot.cpp.

void UPlotCurve::setData ( const QVector< float > &  x,
const QVector< float > &  y 
) [slot]

Definition at line 885 of file UPlot.cpp.

void UPlotCurve::setData ( const std::vector< float > &  x,
const std::vector< float > &  y 
) [slot]

Definition at line 926 of file UPlot.cpp.

void UPlotCurve::setData ( const QVector< float > &  y) [slot]

Definition at line 967 of file UPlot.cpp.

void UPlotCurve::setData ( const std::vector< float > &  y) [slot]

Definition at line 972 of file UPlot.cpp.

void UPlotCurve::setItemsColor ( const QColor &  color)

Definition at line 674 of file UPlot.cpp.

void UPlotCurve::setPen ( const QPen &  pen)

Set pen.

Definition at line 659 of file UPlot.cpp.

void UPlotCurve::setVisible ( bool  visible) [slot]

Show or hide the curve.

Definition at line 857 of file UPlot.cpp.

void UPlotCurve::setXIncrement ( float  increment) [slot]

Set increment of the x values (when auto-increment is used).

Definition at line 866 of file UPlot.cpp.

void UPlotCurve::setXStart ( float  val) [slot]

Set starting x value (when auto-increment is used).

Definition at line 871 of file UPlot.cpp.

void UPlotCurve::update ( float  scaleX,
float  scaleY,
float  offsetX,
float  offsetY,
float  xDir,
float  yDir,
int  maxItemsKept 
) [protected, virtual]

Reimplemented in UPlotCurveThreshold.

Definition at line 688 of file UPlot.cpp.

void UPlotCurve::updateMinMax ( ) [protected]

Definition at line 337 of file UPlot.cpp.


Friends And Related Function Documentation

friend class UPlot [friend]

Reimplemented in UPlotCurveThreshold.

Definition at line 229 of file UPlot.h.


Member Data Documentation

QBrush UPlotCurve::_brush [private]

Definition at line 247 of file UPlot.h.

QList<QGraphicsItem *> UPlotCurve::_items [protected]

Definition at line 238 of file UPlot.h.

QColor UPlotCurve::_itemsColor [private]

Definition at line 254 of file UPlot.h.

QVector<float> UPlotCurve::_minMax [private]

Definition at line 252 of file UPlot.h.

QString UPlotCurve::_name [private]

Definition at line 245 of file UPlot.h.

QPen UPlotCurve::_pen [private]

Definition at line 246 of file UPlot.h.

UPlot* UPlotCurve::_plot [protected]

Definition at line 239 of file UPlot.h.

QGraphicsRectItem* UPlotCurve::_rootItem [private]

Definition at line 253 of file UPlot.h.

bool UPlotCurve::_valuesShown [private]

Definition at line 251 of file UPlot.h.

bool UPlotCurve::_visible [private]

Definition at line 250 of file UPlot.h.

float UPlotCurve::_xIncrement [private]

Definition at line 248 of file UPlot.h.

float UPlotCurve::_xStart [private]

Definition at line 249 of file UPlot.h.


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


rtabmap
Author(s): Mathieu Labbe
autogenerated on Sat Jul 23 2016 11:44:31