20#ifndef LIBREPCB_EDITOR_SYMBOLEDITORSTATE_DRAWTEXTBASE_H
21#define LIBREPCB_EDITOR_SYMBOLEDITORSTATE_DRAWTEXTBASE_H
49class HAlignActionGroup;
50class TextGraphicsItem;
51class VAlignActionGroup;
65 enum class Mode { NAME, VALUE, TEXT };
76 bool entry() noexcept override;
77 bool exit() noexcept override;
79 const noexcept override;
83 QGraphicsSceneMouseEvent& e) noexcept override;
85 QGraphicsSceneMouseEvent& e) noexcept override;
87 QGraphicsSceneMouseEvent& e) noexcept override;
89 bool processMirror(Qt::Orientation orientation) noexcept override;
The Alignment class.
Definition: alignment.h:115
The Angle class is used to represent an angle (for example 12.75 degrees)
Definition: angle.h:78
The HAlign class.
Definition: alignment.h:43
The Layer class provides all supported geometry layers.
Definition: layer.h:42
The Point class is used to represent a point/coordinate/vector, for example (1.2mm; 5....
Definition: point.h:79
The Text class.
Definition: text.h:48
The VAlign class.
Definition: alignment.h:79
The CmdTextEdit class.
Definition: cmdtextedit.h:51
The HAlignActionGroup class is a helper to add librepcb::HAlign chooser toolbuttons to a toolbar.
Definition: halignactiongroup.h:47
The SymbolEditorState_DrawTextBase class.
Definition: symboleditorstate_drawtextbase.h:60
bool processGraphicsSceneMouseMoved(QGraphicsSceneMouseEvent &e) noexcept override
Definition: symboleditorstate_drawtextbase.cpp:181
PositiveLength mLastHeight
Definition: symboleditorstate_drawtextbase.h:118
void vAlignActionGroupValueChanged(const VAlign &value) noexcept
Definition: symboleditorstate_drawtextbase.cpp:359
void hAlignActionGroupValueChanged(const HAlign &value) noexcept
Definition: symboleditorstate_drawtextbase.cpp:351
SymbolEditorState_DrawTextBase(const SymbolEditorState_DrawTextBase &other)=delete
bool abortAddText() noexcept
Definition: symboleditorstate_drawtextbase.cpp:286
const Layer * mLastLayer
Definition: symboleditorstate_drawtextbase.h:116
QPointer< HAlignActionGroup > mHAlignActionGroup
Definition: symboleditorstate_drawtextbase.h:112
QString mLastText
Definition: symboleditorstate_drawtextbase.h:120
Mode
Definition: symboleditorstate_drawtextbase.h:65
void heightEditValueChanged(const PositiveLength &value) noexcept
Definition: symboleditorstate_drawtextbase.cpp:335
Mode mMode
Definition: symboleditorstate_drawtextbase.h:107
SymbolEditorState_DrawTextBase()=delete
std::shared_ptr< Text > mCurrentText
Definition: symboleditorstate_drawtextbase.h:110
bool finishAddText(const Point &pos) noexcept
Definition: symboleditorstate_drawtextbase.cpp:267
std::shared_ptr< TextGraphicsItem > mCurrentGraphicsItem
Definition: symboleditorstate_drawtextbase.h:111
bool processRotate(const Angle &rotation) noexcept override
Definition: symboleditorstate_drawtextbase.cpp:210
void textComboBoxValueChanged(const QString &value) noexcept
Definition: symboleditorstate_drawtextbase.cpp:343
QPointer< VAlignActionGroup > mVAlignActionGroup
Definition: symboleditorstate_drawtextbase.h:113
Angle mLastRotation
Definition: symboleditorstate_drawtextbase.h:117
QScopedPointer< CmdTextEdit > mEditCmd
Definition: symboleditorstate_drawtextbase.h:109
void layerComboBoxValueChanged(const Layer &layer) noexcept
Definition: symboleditorstate_drawtextbase.cpp:327
void resetToDefaultParameters() noexcept
Definition: symboleditorstate_drawtextbase.cpp:300
bool exit() noexcept override
Definition: symboleditorstate_drawtextbase.cpp:156
bool processGraphicsSceneRightMouseButtonReleased(QGraphicsSceneMouseEvent &e) noexcept override
Definition: symboleditorstate_drawtextbase.cpp:204
virtual ~SymbolEditorState_DrawTextBase() noexcept
Definition: symboleditorstate_drawtextbase.cpp:65
Alignment mLastAlignment
Definition: symboleditorstate_drawtextbase.h:119
Point mStartPos
Definition: symboleditorstate_drawtextbase.h:108
bool processMirror(Qt::Orientation orientation) noexcept override
Definition: symboleditorstate_drawtextbase.cpp:221
QSet< EditorWidgetBase::Feature > getAvailableFeatures() const noexcept override
Definition: symboleditorstate_drawtextbase.cpp:169
bool processGraphicsSceneLeftMouseButtonPressed(QGraphicsSceneMouseEvent &e) noexcept override
Definition: symboleditorstate_drawtextbase.cpp:193
bool startAddText(const Point &pos) noexcept
Definition: symboleditorstate_drawtextbase.cpp:243
bool entry() noexcept override
Definition: symboleditorstate_drawtextbase.cpp:73
The SymbolEditorState class is the base class of all symbol editor FSM states.
Definition: symboleditorstate.h:54
The TextGraphicsItem class is the graphical representation of a librepcb::Text.
Definition: textgraphicsitem.h:49
The VAlignActionGroup class is a helper to add librepcb::VAlign chooser toolbuttons to a toolbar.
Definition: valignactiongroup.h:47
Definition: occmodel.cpp:77
type_safe::constrained_type< Length, PositiveLengthConstraint, PositiveLengthVerifier > PositiveLength
Definition: length.h:812
Definition: symboleditorfsm.h:76