barlabel_p.h
34 lines
| 605 B
| text/x-c
|
CLexer
|
r114 | #ifndef BARLABEL_H | ||
#define BARLABEL_H | ||||
#include "chartitem_p.h" | ||||
QTCOMMERCIALCHART_BEGIN_NAMESPACE | ||||
class BarLabel : public ChartItem | ||||
{ | ||||
public: | ||||
BarLabel(QGraphicsItem* parent = 0); | ||||
void set(QString label); | ||||
void setPos(qreal x, qreal y); | ||||
// From ChartItem | ||||
|
r116 | void setSize(const QSizeF &size); | ||
|
r114 | |||
// From QGraphicsItem | ||||
void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget); | ||||
QRectF boundingRect() const; | ||||
private: | ||||
|
r116 | QSizeF mSize; | ||
|
r114 | QString mLabel; | ||
qreal mXpos; | ||||
qreal mYpos; | ||||
}; | ||||
QTCOMMERCIALCHART_END_NAMESPACE | ||||
#endif // BARLABEL_H | ||||