Engauge Digitizer 2
Loading...
Searching...
No Matches
DocumentModelGridRemoval.h
Go to the documentation of this file.
1/******************************************************************************************************
2 * (C) 2014 markummitchell@github.com. This file is part of Engauge Digitizer, which is released *
3 * under GNU General Public License version 2 (GPLv2) or (at your option) any later version. See file *
4 * LICENSE or go to gnu.org/licenses for details. Distribution requires prior written permission. *
5 ******************************************************************************************************/
6
7#ifndef DOCUMENT_MODEL_GRID_REMOVAL_H
8#define DOCUMENT_MODEL_GRID_REMOVAL_H
9
11#include "GridCoordDisable.h"
12
13class Document;
14class QTextStream;
15
21{
22public:
25
28 double startY,
29 double stepX,
30 double stepY,
31 int countX,
32 int countY);
33
35 DocumentModelGridRemoval(const Document &document);
36
39
42
44 double closeDistance() const;
45
47 int countX() const;
48
50 int countY() const;
51
54
57
58 virtual void loadXml(QXmlStreamReader &reader);
59
61 void printStream (QString indentation,
62 QTextStream &str) const;
63
65 bool removeDefinedGridLines () const;
66
67 virtual void saveXml(QXmlStreamWriter &writer) const;
68
70 void setCloseDistance (double closeDistance);
71
73 void setCountX(int countX);
74
76 void setCountY(int countY);
77
79 void setGridCoordDisableX (GridCoordDisable gridCoordDisable);
80
82 void setGridCoordDisableY (GridCoordDisable gridCoordDisable);
83
86
88 void setStable ();
89
91 void setStartX(double startX);
92
94 void setStartY(double startY);
95
97 void setStepX(double stepX);
98
100 void setStepY(double stepY);
101
103 void setStopX(double stopX);
104
106 void setStopY(double stopY);
107
110 bool stable() const;
111
113 double startX() const;
114
116 double startY() const;
117
119 double stepX() const;
120
122 double stepY() const;
123
125 double stopX() const;
126
128 double stopY() const;
129
130private:
131
132 void setStable (bool stable); // Private version is for initialization
133
134 bool m_stable;
135 bool m_removeDefinedGridLines;
136 double m_closeDistance;
137 GridCoordDisable m_gridCoordDisableX;
138 int m_countX;
139 double m_startX;
140 double m_stepX;
141 double m_stopX;
142 GridCoordDisable m_gridCoordDisableY;
143 int m_countY;
144 double m_startY;
145 double m_stepY;
146 double m_stopY;
147};
148
149#endif // DOCUMENT_MODEL_GRID_REMOVAL_H
GridCoordDisable
DocumentModelAbstractBase()
Single constructor.
double closeDistance() const
Get method for close distance.
GridCoordDisable gridCoordDisableX() const
Get method for x coord parameter to disable.
bool removeDefinedGridLines() const
Get method for removing defined grid lines.
double stopX() const
Get method for x stop.
GridCoordDisable gridCoordDisableY() const
Get method for y coord parameter to disable.
virtual void loadXml(QXmlStreamReader &reader)
Load model from serialized xml.
void setCloseDistance(double closeDistance)
Set method for close distance.
void setStopY(double stopY)
Set method for y stop.
double startX() const
Get method for x start.
void setCountX(int countX)
Set method for x count.
double stopY() const
Get method for y stop.
void setGridCoordDisableY(GridCoordDisable gridCoordDisable)
Set method for y coord parameter to disable.
double stepX() const
Get method for x step.
DocumentModelGridRemoval & operator=(const DocumentModelGridRemoval &other)
Assignment constructor.
void setStable()
Set the stable flag to true. This public version has no argument since it cannot be undone.
void setGridCoordDisableX(GridCoordDisable gridCoordDisable)
Set method for x coord parameter to disable.
void setStepX(double stepX)
Set method for x step.
void setStopX(double stopX)
Set method for x stop.
void printStream(QString indentation, QTextStream &str) const
Debugging method that supports print method of this class and printStream method of some other class(...
void setStartY(double startY)
Set method for y start.
double stepY() const
Get method for y step.
virtual void saveXml(QXmlStreamWriter &writer) const
Save entire model as xml into stream.
int countY() const
Get method for y count.
int countX() const
Get method for x count.
double startY() const
Get method for y start.
void setRemoveDefinedGridLines(bool removeDefinedGridLines)
Set method for removing defined grid lines.
bool stable() const
Get method for stable flag.
void setStepY(double stepY)
Set method for y step.
DocumentModelGridRemoval()
Default constructor.
void setStartX(double startX)
Set method for x start.
void setCountY(int countY)
Set method for y count.
Storage of one imported image and the data attached to that image.
Definition Document.h:44