54 #include <QDomElement>
56 #include "../ifc/ifcdef.h"
57 #include "../ifc/xml/vabstractpattern.h"
58 #include "../vmisc/def.h"
59 #include "../vmisc/logging.h"
60 #include "../vmisc/vabstractapplication.h"
61 #include "../vtools/tools/vabstracttool.h"
62 #include "../vwidgets/vmaingraphicsview.h"
63 #include "../vundocommand.h"
69 , m_scene(
qApp->getCurrentScene())
71 setText(tr(
"move point label"));
74 if (domElement.isElement())
81 qCDebug(vUndo,
"Can't find point with id = %u.",
nodeId);
111 if (domElement.isElement())
118 tool->setPointNamePosition(
nodeId, pos);
123 qCDebug(vUndo,
"Can't find point with id = %u.",
nodeId);
QPointF GetNewPos() const
quint32 GetPointId() const
virtual int id() const Q_DECL_OVERRIDE
virtual void Do(const QPointF &pos) Q_DECL_OVERRIDE
virtual bool mergeWith(const QUndoCommand *command) Q_DECL_OVERRIDE
MoveLabel(VAbstractPattern *doc, const QPointF &pos, const quint32 &id, QUndoCommand *parent=nullptr)
static VDataTool * getTool(quint32 id)
getTool return tool from tool list.
static const QString TagPoint
QDomElement elementById(quint32 id, const QString &tagName=QString())
static qreal GetParametrDouble(const QDomElement &domElement, const QString &name, const QString &defValue)
Returns the double value of the given attribute.
void SetAttribute(QDomElement &domElement, const QString &name, const T &value) const
SetAttribute set attribute in pattern file. Replace "," by ".".