Envision
A visual programming IDE for object-oriented languages
|
Public Types | |
enum | PositionConstraint { NoConstraints = 0x0 , Below = 0x1 , Above = 0x2 , LeftOf = 0x4 , RightOf = 0x8 , Overlap = 0x10 } |
using | PositionConstraints = QFlags< PositionConstraint > |
Public Member Functions | |
ItemRegion (const QRect ®ion={}) | |
virtual | ~ItemRegion () |
Cursor * | cursor () const |
qreal | distanceTo (const QPointF &point) |
Item * | item () const |
QRect & | region () |
PositionConstraints | satisfiedPositionConstraints (const QPoint &point) const |
Returns all position constraints with respect to the point point satisfied by this region. More... | |
bool | satisfiesConstraint (PositionConstraint constraint, QRect rect) const |
Returns whether the region occupies a part directly corresponding to the specified constraint. More... | |
void | setCursor (Cursor *cursor) |
void | setItem (Item *item) |
void | setRegion (const QRect ®ion) |
Private Attributes | |
Cursor * | cursor_ |
Item * | item_ |
QRect | region_ |
using Visualization::ItemRegion::PositionConstraints = QFlags<PositionConstraint> |
Visualization::ItemRegion::ItemRegion | ( | const QRect & | region = {} | ) |
|
virtual |
|
inline |
qreal Visualization::ItemRegion::distanceTo | ( | const QPointF & | point | ) |
|
inline |
|
inline |
ItemRegion::PositionConstraints Visualization::ItemRegion::satisfiedPositionConstraints | ( | const QPoint & | point | ) | const |
Returns all position constraints with respect to the point point satisfied by this region.
The returned constraints are from the region's point of view, e.g. a constraint LeftOf means that the region is left of the specified point.
bool Visualization::ItemRegion::satisfiesConstraint | ( | PositionConstraint | constraint, |
QRect | rect | ||
) | const |
Returns whether the region occupies a part directly corresponding to the specified constraint.
|
inline |
|
inline |
|
inline |
|
private |
|
private |
|
private |