|
rock_widget_collection
0.1
|
#include <TextItem.h>
Inherits DrawItem.
Public Slots | |
| QString | getText () |
Public Slots inherited from DrawItem | |
| int | getPosX () |
Public Member Functions | |
| TextItem (int posX, int posY, int groupNr, const QString &text) | |
| virtual | ~TextItem () |
| void | draw (QPainter *painter, QRectF &source, QRectF &target) |
| virtual void | renderOnGl (QGLWidget &widget, QRectF &source, QRectF &target) |
| QFont | getFont () |
| DrawType | getType () |
| void | setText (const QString &text) |
| void | setFont (const QFont &font) |
| void | setBackgroundColor (QColor color) |
Public Member Functions inherited from DrawItem | |
| DrawItem (int posX, int posY, int groupNr, const QColor &color) | |
| virtual | ~DrawItem () |
| bool | operator== (const DrawItem &other) |
| int | getPosY () |
| int | getGroupNr () |
| QColor | getColor () |
| void | setPosX (int posX) |
| void | setPosY (int posY) |
| void | setGroupNr (int groupNr) |
| void | setColor (const QColor &color) |
| int | getLineWidth () |
| Qt::PenStyle | getPenStyle () |
| Qt::PenCapStyle | getPenCapStyle () |
| void | setLineWidth (int lineWidth) |
| void | setPenStyle (Qt::PenStyle penStyle) |
| void | setPenCapStyle (Qt::PenCapStyle penCapStyle) |
| int | getID () const |
| void | openGL (bool value) |
| bool | onOpenGL () |
| void | setPosFactor (float fx, float fy) |
Additional Inherited Members | |
Protected Member Functions inherited from DrawItem | |
| void | addPenStyle (QPainter *painter) |
Protected Attributes inherited from DrawItem | |
| int | groupNr |
| int | posX |
| int | posY |
| QColor | color |
| int | lineWidth |
| Qt::PenCapStyle | penCapStyle |
| Qt::PenStyle | penStyle |
| int | m_id |
| float | position_factor_x |
| float | position_factor_y |
| bool | brender_on_opengl |
Static Protected Attributes inherited from DrawItem | |
| static int | _ID = 0 |
DrawItem that draws text.
the standard font used is QFont("Serif", 24, QFont::Normal)
Definition at line 19 of file TextItem.h.
| TextItem::TextItem | ( | int | posX, |
| int | posY, | ||
| int | groupNr, | ||
| const QString & | text | ||
| ) |
Creates a Textitem
| posX | the x start position |
| posY | the y start position |
| groupNr | the group number |
| color | the color of teh text |
| text | the text to display |
Definition at line 12 of file TextItem.cc.
|
inlinevirtual |
|
virtual |
|
inline |
|
inlineslot |
|
inlinevirtual |
Returns DrawType::Text
Implements DrawItem.
Definition at line 61 of file TextItem.h.
|
virtual |
Reimplemented from DrawItem.
Definition at line 31 of file TextItem.cc.
|
inline |
Definition at line 74 of file TextItem.h.
|
inline |
Sets the font of the item
| font | the font of the item |
Definition at line 73 of file TextItem.h.
|
inline |
Sets the text of the item
| text | the text of the item |
Definition at line 67 of file TextItem.h.
1.8.11