|
| QgsLayoutSnapper (QgsLayout *layout) |
| Constructor for QgsLayoutSnapper, attached to the specified layout. More...
|
|
QgsLayout * | layout () override |
| Returns the layout the object belongs to. More...
|
|
bool | readXml (const QDomElement &gridElement, const QDomDocument &document, const QgsReadWriteContext &context) override |
| Sets the snapper's state from a DOM element. More...
|
|
void | setSnapToGrid (bool enabled) |
| Sets whether snapping to grid is enabled. More...
|
|
void | setSnapToGuides (bool enabled) |
| Sets whether snapping to guides is enabled. More...
|
|
void | setSnapToItems (bool enabled) |
| Sets whether snapping to items is enabled. More...
|
|
void | setSnapTolerance (int snapTolerance) |
| Sets the snap tolerance (in pixels) to use when snapping. More...
|
|
QPointF | snapPoint (QPointF point, double scaleFactor, bool &snapped, QGraphicsLineItem *horizontalSnapLine=nullptr, QGraphicsLineItem *verticalSnapLine=nullptr, const QList< QgsLayoutItem * > *ignoreItems=nullptr) const |
| Snaps a layout coordinate point. More...
|
|
QPointF | snapPointsToGrid (const QList< QPointF > &points, double scaleFactor, bool &snappedX, bool &snappedY) const |
| Snaps a set of points to the grid. More...
|
|
double | snapPointsToGuides (const QList< double > &points, Qt::Orientation orientation, double scaleFactor, bool &snapped) const |
| Snaps a set of points to the guides. More...
|
|
double | snapPointsToItems (const QList< double > &points, Qt::Orientation orientation, double scaleFactor, const QList< QgsLayoutItem * > &ignoreItems, bool &snapped, QGraphicsLineItem *snapLine=nullptr) const |
| Snaps a set of points to the item bounds. More...
|
|
QPointF | snapPointToGrid (QPointF point, double scaleFactor, bool &snappedX, bool &snappedY) const |
| Snaps a layout coordinate point to the grid. More...
|
|
double | snapPointToGuides (double original, Qt::Orientation orientation, double scaleFactor, bool &snapped) const |
| Snaps an original layout coordinate to the guides. More...
|
|
double | snapPointToItems (double original, Qt::Orientation orientation, double scaleFactor, const QList< QgsLayoutItem * > &ignoreItems, bool &snapped, QGraphicsLineItem *snapLine=nullptr) const |
| Snaps an original layout coordinate to the item bounds. More...
|
|
QRectF | snapRect (const QRectF &rect, double scaleFactor, bool &snapped, QGraphicsLineItem *horizontalSnapLine=nullptr, QGraphicsLineItem *verticalSnapLine=nullptr, const QList< QgsLayoutItem * > *ignoreItems=nullptr) const |
| Snaps a layout coordinate rect. More...
|
|
bool | snapToGrid () const |
| Returns true if snapping to grid is enabled. More...
|
|
bool | snapToGuides () const |
| Returns true if snapping to guides is enabled. More...
|
|
bool | snapToItems () const |
| Returns true if snapping to items is enabled. More...
|
|
int | snapTolerance () const |
| Returns the snap tolerance (in pixels) to use when snapping. More...
|
|
QString | stringType () const override |
| Returns the object type as a string. More...
|
|
bool | writeXml (QDomElement &parentElement, QDomDocument &document, const QgsReadWriteContext &context) const override |
| Stores the snapper's state in a DOM element. More...
|
|
QgsAbstractLayoutUndoCommand * | createCommand (const QString &text, int id, QUndoCommand *parent=nullptr) override |
| Creates a new layout undo command with the specified text and parent. More...
|
|
virtual QgsLayout * | layout ()=0 |
| Returns the layout the object belongs to. More...
|
|
virtual bool | readXml (const QDomElement &element, const QDomDocument &document, const QgsReadWriteContext &context)=0 |
| Sets the objects's state from a DOM element. More...
|
|
virtual QString | stringType () const =0 |
| Returns the object type as a string. More...
|
|
virtual bool | writeXml (QDomElement &parentElement, QDomDocument &document, const QgsReadWriteContext &context) const =0 |
| Stores the objects's state in a DOM element. More...
|
|
virtual | ~QgsLayoutUndoObjectInterface ()=default |
| Destructor for QgsLayoutUndoObjectInterface. More...
|
|
virtual QgsAbstractLayoutUndoCommand * | createCommand (const QString &text, int id=0, QUndoCommand *parent=nullptr)=0 |
| Creates a new layout undo command with the specified text and parent. More...
|
|