diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2014-01-01 13:40:41 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2014-01-01 13:41:56 +0100 |
commit | 50104a86acbc20ba1854926a68349eae5459522a (patch) | |
tree | 761a437f58fbc6f2b70b98060d248936fb07c643 | |
parent | 3cc2032002cd5f5bf6523b0438d362ce991ece34 (diff) |
base spline widget size on config size
-rw-r--r-- | facetracknoir/ftnoir_curves.ui | 12 | ||||
-rw-r--r-- | qfunctionconfigurator/functionconfig.h | 2 | ||||
-rw-r--r-- | qfunctionconfigurator/qfunctionconfigurator.cpp | 7 |
3 files changed, 13 insertions, 8 deletions
diff --git a/facetracknoir/ftnoir_curves.ui b/facetracknoir/ftnoir_curves.ui index 77df9a20..5355dd20 100644 --- a/facetracknoir/ftnoir_curves.ui +++ b/facetracknoir/ftnoir_curves.ui @@ -325,7 +325,7 @@ <number>100</number>
</property>
<property name="pixPerEGU_Input" stdset="0">
- <number>7</number>
+ <number>28</number>
</property>
<property name="pixPerEGU_Output" stdset="0">
<number>2</number>
@@ -374,7 +374,7 @@ <number>100</number>
</property>
<property name="pixPerEGU_Input" stdset="0">
- <number>7</number>
+ <number>28</number>
</property>
<property name="pixPerEGU_Output" stdset="0">
<number>2</number>
@@ -415,7 +415,7 @@ <number>100</number>
</property>
<property name="pixPerEGU_Input" stdset="0">
- <number>7</number>
+ <number>28</number>
</property>
<property name="pixPerEGU_Output" stdset="0">
<number>2</number>
@@ -464,7 +464,7 @@ <number>100</number>
</property>
<property name="pixPerEGU_Input" stdset="0">
- <number>7</number>
+ <number>28</number>
</property>
<property name="pixPerEGU_Output" stdset="0">
<number>2</number>
@@ -505,7 +505,7 @@ <number>100</number>
</property>
<property name="pixPerEGU_Input" stdset="0">
- <number>7</number>
+ <number>28</number>
</property>
<property name="pixPerEGU_Output" stdset="0">
<number>2</number>
@@ -554,7 +554,7 @@ <number>100</number>
</property>
<property name="pixPerEGU_Input" stdset="0">
- <number>7</number>
+ <number>28</number>
</property>
<property name="pixPerEGU_Output" stdset="0">
<number>2</number>
diff --git a/qfunctionconfigurator/functionconfig.h b/qfunctionconfigurator/functionconfig.h index a8bb3371..6b154e33 100644 --- a/qfunctionconfigurator/functionconfig.h +++ b/qfunctionconfigurator/functionconfig.h @@ -32,6 +32,8 @@ private: int _max_Output; FunctionConfig(const FunctionConfig&) {} public: + const int maxInput() const { return _max_Input; } + const int maxOutput() const { return _max_Output; } // // Contructor(s) and destructor // diff --git a/qfunctionconfigurator/qfunctionconfigurator.cpp b/qfunctionconfigurator/qfunctionconfigurator.cpp index 4ad0a9a4..5a02a826 100644 --- a/qfunctionconfigurator/qfunctionconfigurator.cpp +++ b/qfunctionconfigurator/qfunctionconfigurator.cpp @@ -31,8 +31,7 @@ QFunctionConfigurator::QFunctionConfigurator(QWidget *parent) // // Defaults, for when the widget has no values different from the domXML() // - MaxInput = 50; // Maximum input limit - MaxOutput = 180; // Maximum output limit + pPerEGU_Output = 1; // Number of pixels, per EGU pPerEGU_Input = 4; // Number of pixels, per EGU gDistEGU_Input = 5; // Distance of gridlines @@ -74,6 +73,10 @@ void QFunctionConfigurator::setConfig(FunctionConfig* config, QString settingsFi setCaption(config->getTitle()); _draw_function = _draw_background = true; + + setmaxInputEGU(config->maxInput()); + setmaxOutputEGU(config->maxOutput()); + this->update(); } |