7 #ifndef BACKGROUND_STATE_CONTEXT_H
8 #define BACKGROUND_STATE_CONTEXT_H
10 #include "BackgroundImage.h"
11 #include "BackgroundStateAbstractBase.h"
18 class QGraphicsPixmapItem;
59 const QString &curveSelected);
66 const QPixmap &pixmapOriginal,
67 const QString &curveSelected);
74 const QString &curveSelected);
79 void completeRequestedStateTransitionIfExists ();
83 QVector<BackgroundStateAbstractBase*> m_states;
84 BackgroundState m_currentState;
85 BackgroundState m_requestedState;
88 #endif // BACKGROUND_STATE_CONTEXT_H
void fitInView(GraphicsView &view)
Zoom so background fills the window.
void updateColorFilter(bool isGnuplot, const Transformation &transformation, const DocumentModelGridRemoval &modelGridRemoval, const DocumentModelColorFilter &colorFilter, const QString &curveSelected)
Apply color filter settings.
void setPixmap(bool isGnuplot, const Transformation &transformation, const DocumentModelGridRemoval &modelGridRemoval, const DocumentModelColorFilter &modelColorFilter, const QPixmap &pixmapOriginal, const QString &curveSelected)
Update the images of all states, rather than just the current state.
void requestStateTransition(BackgroundState backgroundState)
Initiate state transition to be performed later, when BackgroundState is off the stack.
void setBackgroundImage(BackgroundImage backgroundImage)
Transition to the specified state. This method is used by classes outside of the state machine to tri...
Model for DlgSettingsColorFilter and CmdSettingsColorFilter.
Context class that manages the background image state machine.
QGraphicsView class with event handling added. Typically the events are sent to the active digitizing...
void setCurveSelected(bool isGnuplot, const Transformation &transformation, const DocumentModelGridRemoval &modelGridRemoval, const DocumentModelColorFilter &modelColorFilter, const QString &curveSelected)
Update the selected curve.
void close()
Open Document is being closed so remove the background.
QImage imageForCurveState() const
Image for the Curve state, even if the current state is different.
Model for DlgSettingsGridRemoval and CmdSettingsGridRemoval. The settings are unstable until the user...
Main window consisting of menu, graphics scene, status bar and optional toolbars as a Single Document...