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

EllipseItem class. More...

#include <PainterGraphicsItems.h>

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

Public Member Functions

 EllipseItem (QPointF startPos, QPen pen, QBrush brush)
 Constructor of the EllipseItem 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.
 
- 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 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

- 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

EllipseItem class.

This class implements an item which represents an ellipse by two positions

Constructor & Destructor Documentation

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

Constructor of the EllipseItem class.

Member Function Documentation

void PainterPanel::EllipseItem::updatePosition ( QPointF  pos)
inlinevirtual

Update the second position of the item.

Parameters
posThe new second position of the ellipse

Implements PainterPanel::BaseShapeItem.

void PainterPanel::EllipseItem::addPosition ( QPointF  pos)
inlinevirtual

Update the second position of the item.

Parameters
posThe new second position of the ellipse

Implements PainterPanel::BaseShapeItem.

void PainterPanel::EllipseItem::updateShape ( )
inlinevirtual

Call this function to update the shape of the item.

Reimplemented from PainterPanel::BaseShapeItem.

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

Get the type of this item.

Reimplemented from PainterPanel::BaseShapeItem.


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