Engauge Digitizer 2
Loading...
Searching...
No Matches
DocumentModelSegments.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_SEGMENTS_H
8#define DOCUMENT_MODEL_SEGMENTS_H
9
10#include "ColorPalette.h"
12#include "InactiveOpacity.h"
13
14class Document;
15class QTextStream;
16
19{
20public:
23
25 DocumentModelSegments(const Document &document);
26
29
32
34 bool fillCorners () const;
35
38
40 ColorPalette lineColor() const;
41
43 double lineWidthActive() const;
44
46 double lineWidthInactive() const;
47
48 virtual void loadXml(QXmlStreamReader &reader);
49
51 double minLength() const;
52
54 double pointSeparation() const;
55
57 void printStream (QString indentation,
58 QTextStream &str) const;
59
60 virtual void saveXml(QXmlStreamWriter &writer) const;
61
63 void setFillCorners (bool fillCorners);
64
67
70
72 void setLineWidthActive (double lineWidth);
73
75 void setLineWidthInactive (double lineWidth);
76
78 void setMinLength(double minLength);
79
82
83private:
84
85 double m_pointSeparation;
86 double m_minLength;
87 bool m_fillCorners;
88 double m_lineWidthActive;
89 double m_lineWidthInactive;
90 ColorPalette m_lineColor;
91 InactiveOpacity m_inactiveOpacity;
92};
93
94#endif // DOCUMENT_MODEL_SEGMENTS_H
ColorPalette
InactiveOpacity
Enum for opacity/alpha values used for segments that are not currently under hover.
DocumentModelAbstractBase()
Single constructor.
virtual void loadXml(QXmlStreamReader &reader)
Load model from serialized xml.
DocumentModelSegments()
Default constructor.
void setFillCorners(bool fillCorners)
Set method for fill corners.
void setLineWidthActive(double lineWidth)
Set method for line width when active.
double lineWidthInactive() const
Get method for line width when inactive.
double lineWidthActive() const
Get method for line width when active.
void setInactiveOpacity(InactiveOpacity inactiveOpacity)
Set method for inactive opacity.
void setPointSeparation(double pointSeparation)
Set method for point separation.
void printStream(QString indentation, QTextStream &str) const
Debugging method that supports print method of this class and printStream method of some other class(...
InactiveOpacity inactiveOpacity() const
Get method for inactive opacity.
void setLineWidthInactive(double lineWidth)
Set method for line width when inactive.
DocumentModelSegments & operator=(const DocumentModelSegments &other)
Assignment constructor.
ColorPalette lineColor() const
Get method for line color.
double minLength() const
Get method for min length.
void setLineColor(ColorPalette lineColor)
Set method for line color.
bool fillCorners() const
Get method for fill corners.
virtual void saveXml(QXmlStreamWriter &writer) const
Save entire model as xml into stream.
double pointSeparation() const
Get method for point separation.
void setMinLength(double minLength)
Set method for min length.
Storage of one imported image and the data attached to that image.
Definition Document.h:44