20#ifndef LIBREPCB_EDITOR_SYMBOLEDITORFSM_H
21#define LIBREPCB_EDITOR_SYMBOLEDITORFSM_H
26#include "../../editorwidgetbase.h"
43class SymbolEditorState;
44class SymbolEditorWidget;
45class SymbolGraphicsItem;
109 QGraphicsSceneMouseEvent& e) noexcept;
111 QGraphicsSceneMouseEvent& e) noexcept;
113 QGraphicsSceneMouseEvent& e) noexcept;
115 QGraphicsSceneMouseEvent& e) noexcept;
120 bool processMove(Qt::ArrowType direction) noexcept;
The Angle class is used to represent an angle (for example 12.75 degrees)
Definition: angle.h:78
The LengthUnit class represents a length unit (millimeters, inches,...) and provides some useful meth...
Definition: lengthunit.h:60
The Symbol class represents the part of a component which is added to schematics.
Definition: symbol.h:55
The GraphicsScene class.
Definition: graphicsscene.h:45
The GraphicsView class.
Definition: graphicsview.h:51
The SymbolEditorFsm class is the finit state machine (FSM) of the symbol editor.
Definition: symboleditorfsm.h:56
bool processGraphicsSceneRightMouseButtonReleased(QGraphicsSceneMouseEvent &e) noexcept
Definition: symboleditorfsm.cpp:186
bool processKeyReleased(const QKeyEvent &e) noexcept
Definition: symboleditorfsm.cpp:141
SymbolEditorFsm(const SymbolEditorFsm &other)=delete
bool processStartAddingNames() noexcept
Definition: symboleditorfsm.cpp:299
bool setNextState(State state) noexcept
Definition: symboleditorfsm.cpp:353
bool processStartAddingValues() noexcept
Definition: symboleditorfsm.cpp:303
bool processKeyPressed(const QKeyEvent &e) noexcept
Definition: symboleditorfsm.cpp:133
bool processGraphicsSceneLeftMouseButtonDoubleClicked(QGraphicsSceneMouseEvent &e) noexcept
Definition: symboleditorfsm.cpp:176
void statusBarMessageChanged(const QString &message, int timeoutMs=-1)
EditorWidgetBase::Tool getCurrentTool() const noexcept
Definition: symboleditorfsm.cpp:82
bool processStartSelecting() noexcept
Definition: symboleditorfsm.cpp:291
bool processStartDrawLines() noexcept
Definition: symboleditorfsm.cpp:307
bool processSelectAll() noexcept
Definition: symboleditorfsm.cpp:203
bool processStartDrawRects() noexcept
Definition: symboleditorfsm.cpp:315
QMap< State, SymbolEditorState * > mStates
Definition: symboleditorfsm.h:156
bool processRemove() noexcept
Definition: symboleditorfsm.cpp:267
QSet< EditorWidgetBase::Feature > mAvailableFeatures
Definition: symboleditorfsm.h:159
bool processCopy() noexcept
Definition: symboleditorfsm.cpp:219
SymbolEditorState * getCurrentState() const noexcept
Definition: symboleditorfsm.cpp:349
bool processEditProperties() noexcept
Definition: symboleditorfsm.cpp:275
State mPreviousState
Definition: symboleditorfsm.h:158
State
Definition: symboleditorfsm.h:60
bool processCut() noexcept
Definition: symboleditorfsm.cpp:211
bool leaveCurrentState() noexcept
Definition: symboleditorfsm.cpp:365
bool switchToPreviousState() noexcept
Definition: symboleditorfsm.cpp:396
bool processStartDrawTexts() noexcept
Definition: symboleditorfsm.cpp:327
virtual ~SymbolEditorFsm() noexcept
Definition: symboleditorfsm.cpp:72
bool processStartDxfImport() noexcept
Definition: symboleditorfsm.cpp:331
bool processAbortCommand() noexcept
Definition: symboleditorfsm.cpp:283
void toolChanged(EditorWidgetBase::Tool newTool)
bool processGraphicsSceneLeftMouseButtonReleased(QGraphicsSceneMouseEvent &e) noexcept
Definition: symboleditorfsm.cpp:167
bool processGraphicsSceneLeftMouseButtonPressed(QGraphicsSceneMouseEvent &e) noexcept
Definition: symboleditorfsm.cpp:158
bool processStartDrawCircles() noexcept
Definition: symboleditorfsm.cpp:323
void updateAvailableFeatures() noexcept
Definition: symboleditorfsm.cpp:118
bool enterNextState(State state) noexcept
Definition: symboleditorfsm.cpp:382
State mCurrentState
Definition: symboleditorfsm.h:157
bool processGraphicsSceneMouseMoved(QGraphicsSceneMouseEvent &e) noexcept
Definition: symboleditorfsm.cpp:149
bool processRotate(const Angle &rotation) noexcept
Definition: symboleditorfsm.cpp:243
const QSet< EditorWidgetBase::Feature > & getAvailableFeatures() const noexcept
Definition: symboleditorfsm.h:97
bool processStartMeasure() noexcept
Definition: symboleditorfsm.cpp:341
bool processMirror(Qt::Orientation orientation) noexcept
Definition: symboleditorfsm.cpp:251
void availableFeaturesChanged()
bool processStartDrawArcs() noexcept
Definition: symboleditorfsm.cpp:311
bool processStartAddingSymbolPins() noexcept
Definition: symboleditorfsm.cpp:295
bool processStartDrawPolygons() noexcept
Definition: symboleditorfsm.cpp:319
bool processMove(Qt::ArrowType direction) noexcept
Definition: symboleditorfsm.cpp:235
bool processPaste() noexcept
Definition: symboleditorfsm.cpp:227
bool processSnapToGrid() noexcept
Definition: symboleditorfsm.cpp:259
The SymbolEditorState class is the base class of all symbol editor FSM states.
Definition: symboleditorstate.h:52
The SymbolGraphicsItem class.
Definition: symbolgraphicsitem.h:56
The UndoStack class holds UndoCommand objects and provides undo/redo commands.
Definition: undostack.h:106
Definition: occmodel.cpp:77
Definition: editorwidgetbase.h:68
Definition: symboleditorfsm.h:76
LengthUnit & lengthUnit
Definition: symboleditorfsm.h:82
Symbol & symbol
Definition: symboleditorfsm.h:83
GraphicsView & graphicsView
Definition: symboleditorfsm.h:81
ToolBarProxy & commandToolBar
Definition: symboleditorfsm.h:85
SymbolEditorWidget & editorWidget
Definition: symboleditorfsm.h:78
GraphicsScene & graphicsScene
Definition: symboleditorfsm.h:80
SymbolGraphicsItem & symbolGraphicsItem
Definition: symboleditorfsm.h:84
EditorWidgetBase::Context & editorContext
Definition: symboleditorfsm.h:77
UndoStack & undoStack
Definition: symboleditorfsm.h:79