![]() |
TinkerCell Core 1.0
TinkerCell's Core library providing all basic functionalities
|
A closed polygon path made from arcs, lines, and beziers. More...
#include <NodeGraphicsItem.h>
Public Types | |
enum | { Type = UserType + 3 } |
for enabling dynamic_cast More... | |
Public Member Functions | |
Shape (NodeGraphicsItem *idrawable_ptr=0, QGraphicsItem *parent=0, QGraphicsScene *scene=0) | |
Shape (const Shape ©) | |
virtual Shape & | operator= (const Shape ©) |
void | refresh () |
Generates a new polygon using the points and types vectors Precondition: points.size > 1 Postcondition: NA. | |
bool | isClosed () const |
Checks if the polygon is closed. | |
virtual QPainterPath | shape () const |
gets a path that represents this shape | |
virtual QRectF | boundingRect () const |
bounding rect | |
virtual int | type () const |
for enabling dynamic_cast | |
Public Attributes | |
QBrush | defaultBrush |
permanent brush for this control point | |
QPen | defaultPen |
permanent pen for this control point | |
NodeGraphicsItem * | nodeItem |
paint method. Call's parent's paint after setting antialiasing to true | |
bool | negative |
QVector< ControlPoint * > | controlPoints |
control points defining this shape | |
QVector< qreal > | parameters |
thinckness, arc angles, etc. | |
QVector< ShapeType > | types |
types of shapes to draw using the control points | |
QPolygonF | polygon |
the polygon constructed from controls and types vectors | |
QPainterPath | path |
the path constructed from controls and types vectors | |
QPair< QPointF, QPointF > | gradientPoints |
start and stop coordinates for gradient fill | |
Protected Member Functions | |
virtual void | recomputeBoundingRect () |
reconstruct bounding rect | |
Protected Attributes | |
QRectF | boundingRectangle |
bounding reactangle for this shape |
A closed polygon path made from arcs, lines, and beziers.
Definition at line 132 of file NodeGraphicsItem.h.
anonymous enum |
Tinkercell::NodeGraphicsItem::Shape::Shape | ( | NodeGraphicsItem * | idrawable_ptr = 0 , |
QGraphicsItem * | parent = 0 , |
||
QGraphicsScene * | scene = 0 |
||
) |
Constructor: sets angle to 0 and scale to 1
Definition at line 727 of file NodeGraphicsItem.cpp.
Tinkercell::NodeGraphicsItem::Shape::Shape | ( | const Shape & | copy | ) |
Copy Constructor
Copy Constructor : shallow copy of all vectors
Definition at line 736 of file NodeGraphicsItem.cpp.
QRectF Tinkercell::NodeGraphicsItem::Shape::boundingRect | ( | ) | const [virtual] |
bounding rect
bounding rectangle
Definition at line 846 of file NodeGraphicsItem.cpp.
bool Tinkercell::NodeGraphicsItem::Shape::isClosed | ( | ) | const |
Checks if the polygon is closed.
Definition at line 853 of file NodeGraphicsItem.cpp.
NodeGraphicsItem::Shape & Tinkercell::NodeGraphicsItem::Shape::operator= | ( | const Shape & | copy | ) | [virtual] |
Copy operator
operator = shallow copy of all vectors
Definition at line 753 of file NodeGraphicsItem.cpp.
void Tinkercell::NodeGraphicsItem::Shape::recomputeBoundingRect | ( | ) | [protected, virtual] |
reconstruct bounding rect
Definition at line 878 of file NodeGraphicsItem.cpp.
void Tinkercell::NodeGraphicsItem::Shape::refresh | ( | ) |
Generates a new polygon using the points and types vectors Precondition: points.size > 1 Postcondition: NA.
paint method. Call's parent's paint after setting antialiasing to true
void |
Generates a new polygon using the points and types vectors Precondition: controlPoints.size > 1 Postcondition: NA
void |
Definition at line 780 of file NodeGraphicsItem.cpp.
QPainterPath Tinkercell::NodeGraphicsItem::Shape::shape | ( | ) | const [virtual] |
gets a path that represents this shape
gets a path that represents this graphicsItem
Definition at line 863 of file NodeGraphicsItem.cpp.
virtual int Tinkercell::NodeGraphicsItem::Shape::type | ( | ) | const [inline, virtual] |
for enabling dynamic_cast
Definition at line 178 of file NodeGraphicsItem.h.
QRectF Tinkercell::NodeGraphicsItem::Shape::boundingRectangle [protected] |
bounding reactangle for this shape
Definition at line 185 of file NodeGraphicsItem.h.
control points defining this shape
Definition at line 160 of file NodeGraphicsItem.h.
permanent brush for this control point
Definition at line 136 of file NodeGraphicsItem.h.
permanent pen for this control point
Definition at line 138 of file NodeGraphicsItem.h.
QPair<QPointF,QPointF> Tinkercell::NodeGraphicsItem::Shape::gradientPoints |
start and stop coordinates for gradient fill
Definition at line 172 of file NodeGraphicsItem.h.
is this a negative (clip out) shape
Definition at line 150 of file NodeGraphicsItem.h.
paint method. Call's parent's paint after setting antialiasing to true
the NodeGraphicsItem that this shape belongs in
Definition at line 148 of file NodeGraphicsItem.h.
QVector<qreal> Tinkercell::NodeGraphicsItem::Shape::parameters |
thinckness, arc angles, etc.
Definition at line 162 of file NodeGraphicsItem.h.
QPainterPath Tinkercell::NodeGraphicsItem::Shape::path |
the path constructed from controls and types vectors
Definition at line 168 of file NodeGraphicsItem.h.
the polygon constructed from controls and types vectors
Definition at line 166 of file NodeGraphicsItem.h.
types of shapes to draw using the control points
Definition at line 164 of file NodeGraphicsItem.h.