|
Engauge Digitizer 2
|
Container for all DigitizeStateAbstractBase subclasses. This functions as the context class in a standard state machine implementation. More...
#include <DigitizeStateContext.h>
Public Member Functions | |
| DigitizeStateContext (MainWindow &mainWindow, QGraphicsView &view, bool isGnuplot) | |
| Single constructor. | |
| QString | activeCurve () const |
| Curve name for active Curve. This can include AXIS_CURVE_NAME, and empty string. | |
| void | appendNewCmd (CmdMediator *cmdMediator, QUndoCommand *cmd) |
| Append just-created QUndoCommand to command stack. This is called from DigitizeStateAbstractBase subclasses. | |
| void | handleContextMenuEvent (CmdMediator *cmdMediator, const QString &pointIdentifier) |
| See DigitizeStateAbstractBase::handleContextMenuEvent. | |
| void | handleCurveChange (CmdMediator *cmdMediator) |
| See DigitizeStateAbstractBase::handleCurveChange. | |
| void | handleKeyPress (CmdMediator *cmdMediator, Qt::Key key, bool atLeastOneSelectedItem) |
| See DigitizeStateAbstractBase::handleKeyPress. | |
| void | handleLeave (CmdMediator *cmdMediator) |
| See DigitizeStateAbstractBase::handleLeave. | |
| void | handleMouseMove (CmdMediator *cmdMediator, QPointF pos) |
| See DigitizeStateAbstractBase::handleMouseMove. | |
| void | handleMousePress (CmdMediator *cmdMediator, QPointF pos) |
| See DigitizeStateAbstractBase::handleMousePress. | |
| void | handleMouseRelease (CmdMediator *cmdMediator, QPointF pos) |
| See DigitizeStateAbstractBase::handleMouseRelease. | |
| void | handleSetOverrideCursor (CmdMediator *cmdMediator, const QCursor &cursor) |
| See DigitizeStateAbstractBase::handleSetOverrideCursor. | |
| bool | isGnuplot () const |
| Get method for gnuplot flag. | |
| MainWindow & | mainWindow () |
| Reference to the MainWindow, without const. | |
| const MainWindow & | mainWindow () const |
| Reference to the MainWindow, with const. | |
| void | requestDelayedStateTransition (DigitizeState digitizeState) |
| Initiate state transition to be performed later, when DigitizeState is off the stack. | |
| void | requestImmediateStateTransition (CmdMediator *cmdMediator, DigitizeState digitizeState) |
| Perform immediate state transition. Called from outside state machine. | |
| void | resetOnLoad (CmdMediator *cmdMediator) |
| Resetting makes re-initializes for documents after the first. | |
| void | setCursor (CmdMediator *cmdMediator) |
| Set cursor after asking state for the new cursor shape. | |
| void | setDragMode (QGraphicsView::DragMode dragMode) |
| Set QGraphicsView drag mode (in m_view). Called from DigitizeStateAbstractBase subclasses. | |
| void | setImageIsLoaded (CmdMediator *cmdMediator, bool imageIsLoaded) |
| Set the image so QGraphicsView cursor and drag mode are accessible. | |
| QString | state () const |
| State name for debugging. | |
| void | updateModelDigitizeCurve (CmdMediator *cmdMediator, const DocumentModelDigitizeCurve &modelDigitizeCurve) |
| Update the digitize curve settings. | |
| void | updateModelSegments (const DocumentModelSegments &modelSegments) |
| Update the segments given the new settings. | |
| QGraphicsView & | view () |
| QGraphicsView for use by DigitizeStateAbstractBase subclasses. | |
Container for all DigitizeStateAbstractBase subclasses. This functions as the context class in a standard state machine implementation.
Definition at line 24 of file DigitizeStateContext.h.
| DigitizeStateContext::DigitizeStateContext | ( | MainWindow & | mainWindow, |
| QGraphicsView & | view, | ||
| bool | isGnuplot | ||
| ) |
Single constructor.
Definition at line 28 of file DigitizeStateContext.cpp.
|
virtual |
Definition at line 51 of file DigitizeStateContext.cpp.
| QString DigitizeStateContext::activeCurve | ( | ) | const |
Curve name for active Curve. This can include AXIS_CURVE_NAME, and empty string.
Definition at line 55 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::appendNewCmd | ( | CmdMediator * | cmdMediator, |
| QUndoCommand * | cmd | ||
| ) |
Append just-created QUndoCommand to command stack. This is called from DigitizeStateAbstractBase subclasses.
Definition at line 60 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::handleContextMenuEvent | ( | CmdMediator * | cmdMediator, |
| const QString & | pointIdentifier | ||
| ) |
See DigitizeStateAbstractBase::handleContextMenuEvent.
Definition at line 92 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::handleCurveChange | ( | CmdMediator * | cmdMediator | ) |
See DigitizeStateAbstractBase::handleCurveChange.
Definition at line 99 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::handleKeyPress | ( | CmdMediator * | cmdMediator, |
| Qt::Key | key, | ||
| bool | atLeastOneSelectedItem | ||
| ) |
See DigitizeStateAbstractBase::handleKeyPress.
Definition at line 104 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::handleLeave | ( | CmdMediator * | cmdMediator | ) |
See DigitizeStateAbstractBase::handleLeave.
Definition at line 116 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::handleMouseMove | ( | CmdMediator * | cmdMediator, |
| QPointF | pos | ||
| ) |
See DigitizeStateAbstractBase::handleMouseMove.
Definition at line 124 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::handleMousePress | ( | CmdMediator * | cmdMediator, |
| QPointF | pos | ||
| ) |
See DigitizeStateAbstractBase::handleMousePress.
Definition at line 134 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::handleMouseRelease | ( | CmdMediator * | cmdMediator, |
| QPointF | pos | ||
| ) |
See DigitizeStateAbstractBase::handleMouseRelease.
Definition at line 144 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::handleSetOverrideCursor | ( | CmdMediator * | cmdMediator, |
| const QCursor & | cursor | ||
| ) |
See DigitizeStateAbstractBase::handleSetOverrideCursor.
Definition at line 153 of file DigitizeStateContext.cpp.
| bool DigitizeStateContext::isGnuplot | ( | ) | const |
Get method for gnuplot flag.
Definition at line 160 of file DigitizeStateContext.cpp.
| MainWindow & DigitizeStateContext::mainWindow | ( | ) |
Reference to the MainWindow, without const.
Definition at line 165 of file DigitizeStateContext.cpp.
| const MainWindow & DigitizeStateContext::mainWindow | ( | ) | const |
Reference to the MainWindow, with const.
Definition at line 170 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::requestDelayedStateTransition | ( | DigitizeState | digitizeState | ) |
Initiate state transition to be performed later, when DigitizeState is off the stack.
Definition at line 175 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::requestImmediateStateTransition | ( | CmdMediator * | cmdMediator, |
| DigitizeState | digitizeState | ||
| ) |
Perform immediate state transition. Called from outside state machine.
Definition at line 180 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::resetOnLoad | ( | CmdMediator * | cmdMediator | ) |
Resetting makes re-initializes for documents after the first.
Definition at line 187 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::setCursor | ( | CmdMediator * | cmdMediator | ) |
Set cursor after asking state for the new cursor shape.
Definition at line 199 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::setDragMode | ( | QGraphicsView::DragMode | dragMode | ) |
Set QGraphicsView drag mode (in m_view). Called from DigitizeStateAbstractBase subclasses.
Definition at line 208 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::setImageIsLoaded | ( | CmdMediator * | cmdMediator, |
| bool | imageIsLoaded | ||
| ) |
Set the image so QGraphicsView cursor and drag mode are accessible.
Definition at line 217 of file DigitizeStateContext.cpp.
| QString DigitizeStateContext::state | ( | ) | const |
State name for debugging.
Definition at line 226 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::updateModelDigitizeCurve | ( | CmdMediator * | cmdMediator, |
| const DocumentModelDigitizeCurve & | modelDigitizeCurve | ||
| ) |
Update the digitize curve settings.
Definition at line 233 of file DigitizeStateContext.cpp.
| void DigitizeStateContext::updateModelSegments | ( | const DocumentModelSegments & | modelSegments | ) |
Update the segments given the new settings.
Definition at line 244 of file DigitizeStateContext.cpp.
| QGraphicsView & DigitizeStateContext::view | ( | ) |
QGraphicsView for use by DigitizeStateAbstractBase subclasses.
Definition at line 253 of file DigitizeStateContext.cpp.