Engauge Digitizer
2
Toggle main menu visibility
Loading...
Searching...
No Matches
Document
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
"
11
#include "
DocumentModelAbstractBase.h
"
12
#include "
InactiveOpacity.h
"
13
14
class
Document
;
15
class
QTextStream;
16
18
class
DocumentModelSegments
:
public
DocumentModelAbstractBase
19
{
20
public
:
22
DocumentModelSegments
();
23
25
DocumentModelSegments
(
const
Document
&document);
26
28
DocumentModelSegments
(
const
DocumentModelSegments
&other);
29
31
DocumentModelSegments
&
operator=
(
const
DocumentModelSegments
&other);
32
34
bool
fillCorners
()
const
;
35
37
InactiveOpacity
inactiveOpacity
()
const
;
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
66
void
setInactiveOpacity
(
InactiveOpacity
inactiveOpacity
);
67
69
void
setLineColor
(
ColorPalette
lineColor
);
70
72
void
setLineWidthActive
(
double
lineWidth);
73
75
void
setLineWidthInactive
(
double
lineWidth);
76
78
void
setMinLength
(
double
minLength
);
79
81
void
setPointSeparation
(
double
pointSeparation
);
82
83
private
:
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.h
ColorPalette
ColorPalette
Definition
ColorPalette.h:12
DocumentModelAbstractBase.h
InactiveOpacity.h
InactiveOpacity
InactiveOpacity
Enum for opacity/alpha values used for segments that are not currently under hover.
Definition
InactiveOpacity.h:15
DocumentModelAbstractBase::DocumentModelAbstractBase
DocumentModelAbstractBase()
Single constructor.
Definition
DocumentModelAbstractBase.cpp:10
DocumentModelSegments::loadXml
virtual void loadXml(QXmlStreamReader &reader)
Load model from serialized xml.
Definition
DocumentModelSegments.cpp:95
DocumentModelSegments::DocumentModelSegments
DocumentModelSegments()
Default constructor.
Definition
DocumentModelSegments.cpp:24
DocumentModelSegments::setFillCorners
void setFillCorners(bool fillCorners)
Set method for fill corners.
Definition
DocumentModelSegments.cpp:206
DocumentModelSegments::setLineWidthActive
void setLineWidthActive(double lineWidth)
Set method for line width when active.
Definition
DocumentModelSegments.cpp:221
DocumentModelSegments::lineWidthInactive
double lineWidthInactive() const
Get method for line width when inactive.
Definition
DocumentModelSegments.cpp:90
DocumentModelSegments::lineWidthActive
double lineWidthActive() const
Get method for line width when active.
Definition
DocumentModelSegments.cpp:85
DocumentModelSegments::setInactiveOpacity
void setInactiveOpacity(InactiveOpacity inactiveOpacity)
Set method for inactive opacity.
Definition
DocumentModelSegments.cpp:211
DocumentModelSegments::setPointSeparation
void setPointSeparation(double pointSeparation)
Set method for point separation.
Definition
DocumentModelSegments.cpp:236
DocumentModelSegments::printStream
void printStream(QString indentation, QTextStream &str) const
Debugging method that supports print method of this class and printStream method of some other class(...
Definition
DocumentModelSegments.cpp:172
DocumentModelSegments::inactiveOpacity
InactiveOpacity inactiveOpacity() const
Get method for inactive opacity.
Definition
DocumentModelSegments.cpp:75
DocumentModelSegments::setLineWidthInactive
void setLineWidthInactive(double lineWidth)
Set method for line width when inactive.
Definition
DocumentModelSegments.cpp:226
DocumentModelSegments::operator=
DocumentModelSegments & operator=(const DocumentModelSegments &other)
Assignment constructor.
Definition
DocumentModelSegments.cpp:57
DocumentModelSegments::lineColor
ColorPalette lineColor() const
Get method for line color.
Definition
DocumentModelSegments.cpp:80
DocumentModelSegments::minLength
double minLength() const
Get method for min length.
Definition
DocumentModelSegments.cpp:162
DocumentModelSegments::setLineColor
void setLineColor(ColorPalette lineColor)
Set method for line color.
Definition
DocumentModelSegments.cpp:216
DocumentModelSegments::fillCorners
bool fillCorners() const
Get method for fill corners.
Definition
DocumentModelSegments.cpp:70
DocumentModelSegments::saveXml
virtual void saveXml(QXmlStreamWriter &writer) const
Save entire model as xml into stream.
Definition
DocumentModelSegments.cpp:188
DocumentModelSegments::pointSeparation
double pointSeparation() const
Get method for point separation.
Definition
DocumentModelSegments.cpp:167
DocumentModelSegments::setMinLength
void setMinLength(double minLength)
Set method for min length.
Definition
DocumentModelSegments.cpp:231
Document
Storage of one imported image and the data attached to that image.
Definition
Document.h:44
Generated on
for Engauge Digitizer by
1.17.0