|
Schim
|
Graphical line object that wraps a Line.
More...
#include <gline.h>
Public Member Functions | |
| Line * | get () override |
| Return the object that is being wrapped by this class. More... | |
| void | reloadFromModel () override |
| Update the graphical representation to match the object from the model. More... | |
| void | applyToModel () override |
| Apply changes to the underlying model object. More... | |
| void | handleChanged (GObjectHandle *handle) override |
| Called when a handle's position has changed. More... | |
| void | showHandles (bool show=true) override |
| Display/hide the handles for this item. More... | |
Public Member Functions inherited from GObject | |
| GObject (Object *obj) | |
Construct a wrapper around obj. More... | |
| virtual | ~GObject () |
| bool | isHovered () const |
| Return whether the mouse is over this object. | |
| virtual void | setCosmetic (bool cosmetic) |
| Make the object's pen independent of any transformations. More... | |
| void | hoverEnterEvent (QGraphicsSceneHoverEvent *event) override |
Set hovered=true so that it can be used by paint. | |
| void | hoverLeaveEvent (QGraphicsSceneHoverEvent *event) override |
Disable the bool hovered so that it can be used by paint. | |
| QRectF | boundingRect () const override |
| Default implementation that returns childrenBoundingRect(). | |
| void | paint (QPainter *, const QStyleOptionGraphicsItem *, QWidget *) override |
| GCompositeObject * | parentItem () const |
Return the parent item cast to a GObject*. | |
Additional Inherited Members | |
Static Public Member Functions inherited from GObject | |
| static GObject * | assign (Object *obj) |
| Return a dynamically allocated GObject wrapping the specified object. More... | |
Protected Member Functions inherited from GObject | |
| void | mouseMoveEvent (QGraphicsSceneMouseEvent *event) override |
| QVariant | itemChange (GraphicsItemChange change, const QVariant &value) override |
| Process item changes that should behave uniformly across different object types. More... | |
Protected Attributes inherited from GObject | |
| Object * | obj |
| The object that is being wrapped. | |
| QList< GObjectHandle * > * | handles {} |
| Dynamically allocated list of handles. | |
Graphical line object that wraps a Line.
|
overridevirtual |
Apply changes to the underlying model object.
Reimplemented from GObject.
|
overridevirtual |
Return the object that is being wrapped by this class.
Reimplemented from GObject.
|
overridevirtual |
Called when a handle's position has changed.
The base implementation does nothing.
| handle | The handle that has been modified. |
Reimplemented from GObject.
|
overridevirtual |
Update the graphical representation to match the object from the model.
Reimplemented from GObject.
|
overridevirtual |
Display/hide the handles for this item.
The list of handles is dynamically allocated and it exists only while the handles are visible. This way, the handles do not take up memory when they are not used.
show = true. Each subclass should implement this this method separately, optionally calling the superclass method but only as the last statement. Reimplemented from GObject.
1.8.13