Frapper  1.0a
Public Member Functions | List of all members
PainterPanel::PolygonItem Class Reference

PolygonItem class. More...

#include <PainterGraphicsItems.h>

Inheritance diagram for PainterPanel::PolygonItem:
Inheritance graph
[legend]
Collaboration diagram for PainterPanel::PolygonItem:
Collaboration graph
[legend]

Public Member Functions

 PolygonItem (QPointF startPos, QPen pen, QBrush brush)
 Constructor of the PolygonItem class.
 
void updateShape ()
 Call this function to update the shape of the item.
 
virtual ItemType GetItemType ()
 Get the type of this item.
 
- Public Member Functions inherited from PainterPanel::PolyLineItem
 PolyLineItem (QPointF startPos, QPen pen, QBrush brush)
 Constructor of the PolyLineItem class.
 
void addPosition (QPointF pos)
 Adds a new position to the polyline.
 
void updatePosition (QPointF pos)
 Updates the last added position of the polyline.
 
void skipLastPosition (bool &emptyItem)
 Skip the last position of the polyline.
 
- Public Member Functions inherited from PainterPanel::BaseShapeItem
 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 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

- Public Types inherited from PainterPanel::BaseShapeItem
enum  ItemType {
  BASE =0, PAINT, LINE, RECT,
  CIRCLE, ELLIPSE, POLYGON, POLYLINE,
  CURVE, CLOSEDCURVE, NUM_ITEMTYPES
}
 
enum  { Type = UserType + 1 }
 
- Protected Member Functions inherited from PainterPanel::BaseShapeItem
virtual QVariant itemChange (GraphicsItemChange change, const QVariant &value)
 React on changes of the item.
 
- Protected Attributes inherited from PainterPanel::BaseShapeItem
QPainterPath m_shape
 The shape of the item to draw.
 
QList< PointHandle * > m_points
 The list of point handles.
 
RotationHandlem_rotateHandle
 The handle to rotate this shape item.
 
TranslationHandlem_translateHandle
 The handle to translate this shape item.
 

Detailed Description

PolygonItem class.

This class implements an item which represents a PolygonItem by several positions

Constructor & Destructor Documentation

PainterPanel::PolygonItem::PolygonItem ( QPointF  startPos,
QPen  pen,
QBrush  brush 
)
inline

Constructor of the PolygonItem class.

Member Function Documentation

void PainterPanel::PolygonItem::updateShape ( )
inlinevirtual

Call this function to update the shape of the item.

Reimplemented from PainterPanel::PolyLineItem.

virtual ItemType PainterPanel::PolygonItem::GetItemType ( )
inlinevirtual

Get the type of this item.

Reimplemented from PainterPanel::PolyLineItem.


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