IntelliPhoto 0.7

IntelliToolsettings.cpp
Go to the documentation of this file.
1 #include "IntelliToolsettings.h"
2 #include <QInputDialog>
3
4 IntelliToolsettings::IntelliToolsettings()
5 {
6 lineWidth = 1;
7 innerAlpha = 255;
8 }
9
10 IntelliToolsettings::~IntelliToolsettings(){
11
12 }
13
14 int IntelliToolsettings::getLineWidth() const {
15 return lineWidth;
16 }
17
18 void IntelliToolsettings::setLineWidth(int LineWidth){
19 if(LineWidth < 1) {
20 LineWidth = 1;
21 }
22 else if(LineWidth > 50) {
23 LineWidth = 50;
24 }
25 lineWidth = LineWidth;
26 }
27
28 int IntelliToolsettings::getInnerAlpha() const {
29 return this->innerAlpha;
30 }
31
32 void IntelliToolsettings::setInnerAlpha(int innerAlpha){
33 if(innerAlpha < 0) {
34 innerAlpha = 0;
35 }
36 else if(innerAlpha > 255) {
37 innerAlpha = 255;
38 }
39 this->innerAlpha = innerAlpha;
40 }
IntelliToolsettings::getLineWidth
int getLineWidth() const
getLineWidth returns the width attribute of the line.
Definition: IntelliToolsettings.cpp:14
IntelliToolsettings.h
IntelliToolsettings::getInnerAlpha
int getInnerAlpha() const
getInnerAlpha returns the inner alpha value.
Definition: IntelliToolsettings.cpp:28
IntelliToolsettings::~IntelliToolsettings
virtual ~IntelliToolsettings()
~IntelliToolsettings - basic destructor.
Definition: IntelliToolsettings.cpp:10
IntelliToolsettings::setInnerAlpha
void setInnerAlpha(int innerAlpha)
setInnerAlpha sets the inner alpha attribute of the Tool.
Definition: IntelliToolsettings.cpp:32
IntelliToolsettings::setLineWidth
void setLineWidth(int LineWidth)
setLineWidth sets the width attribute of the line.
Definition: IntelliToolsettings.cpp:18
IntelliToolsettings::IntelliToolsettings
IntelliToolsettings()
IntelliToolsettings - basic constructor of the IntelliToolsettings, initializing the basics.
Definition: IntelliToolsettings.cpp:4