Frapper
1.0a
|
#include <PainterGraphicsItems.h>
Public Member Functions | |
RectItem (QPointF startPos, QPen pen, QBrush brush) | |
Constructor of the RectItem class. | |
void | updatePosition (QPointF pos) |
Update the second position of the item. | |
void | addPosition (QPointF pos) |
Update the second position of the item. | |
void | updateShape () |
Call this function to update the shape of the item. | |
virtual ItemType | GetItemType () |
Get the type of this item. | |
![]() | |
BaseShapeItem (QPen pen=QPen(), QBrush brush=QBrush()) | |
Constructor of the BaseShapeItem class. | |
virtual | ~BaseShapeItem () |
Destructor of the PainterPanel class. | |
virtual int | type () const |
Enable the use of qgraphicsitem_cast with this item. | |
virtual void | skipLastPosition (bool &emptyItem) |
Forget the last position provided by add-/updatePosition() | |
virtual QRectF | boundingRect () const |
Get the bounding-rect of the shape. | |
virtual void | paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) |
Paint the item with the specified pen and brush Use a yellow pen when the item is selected. | |
QString | getDescriptionText () |
Additional Inherited Members | |
![]() | |
enum | ItemType { BASE =0, PAINT, LINE, RECT, CIRCLE, ELLIPSE, POLYGON, POLYLINE, CURVE, CLOSEDCURVE, NUM_ITEMTYPES } |
enum | { Type = UserType + 1 } |
![]() | |
virtual QVariant | itemChange (GraphicsItemChange change, const QVariant &value) |
React on changes of the item. | |
![]() | |
QPainterPath | m_shape |
The shape of the item to draw. | |
QList< PointHandle * > | m_points |
The list of point handles. | |
RotationHandle * | m_rotateHandle |
The handle to rotate this shape item. | |
TranslationHandle * | m_translateHandle |
The handle to translate this shape item. | |
RectItem class.
This class implements an item which represents a rectangle by two positions
|
inline |
Constructor of the RectItem class.
|
inlinevirtual |
Update the second position of the item.
pos | The new second position of the rectangle |
Implements PainterPanel::BaseShapeItem.
|
inlinevirtual |
Update the second position of the item.
pos | The new second position of the rectangle |
Implements PainterPanel::BaseShapeItem.
|
inlinevirtual |
Call this function to update the shape of the item.
Reimplemented from PainterPanel::BaseShapeItem.
|
inlinevirtual |
Get the type of this item.
Reimplemented from PainterPanel::BaseShapeItem.