summaryrefslogtreecommitdiffhomepage
path: root/ftnoir_filter_accela
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2013-10-23 16:26:01 +0200
committerStanislaw Halik <sthalik@misaki.pl>2013-10-23 16:26:01 +0200
commit4907f040892b798ab973de542cf7465d48c6e5d8 (patch)
tree3b7608cfbaea13ba7adeec932c2e045b1005ea85 /ftnoir_filter_accela
parent0b2b8207b6ac55789ac6c402986870aaa7a6841d (diff)
fix layout (again, sorry)
Signed-off-by: Stanislaw Halik <sthalik@misaki.pl>
Diffstat (limited to 'ftnoir_filter_accela')
-rw-r--r--ftnoir_filter_accela/ftnoir_accela_filtercontrols.ui287
-rw-r--r--ftnoir_filter_accela/ftnoir_filter_accela_dialog.cpp4
2 files changed, 125 insertions, 166 deletions
diff --git a/ftnoir_filter_accela/ftnoir_accela_filtercontrols.ui b/ftnoir_filter_accela/ftnoir_accela_filtercontrols.ui
index 6cf3d20b..098213ef 100644
--- a/ftnoir_filter_accela/ftnoir_accela_filtercontrols.ui
+++ b/ftnoir_filter_accela/ftnoir_accela_filtercontrols.ui
@@ -9,8 +9,8 @@
<rect>
<x>0</x>
<y>0</y>
- <width>427</width>
- <height>235</height>
+ <width>459</width>
+ <height>207</height>
</rect>
</property>
<property name="sizePolicy">
@@ -21,14 +21,14 @@
</property>
<property name="minimumSize">
<size>
- <width>248</width>
- <height>235</height>
+ <width>0</width>
+ <height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
- <width>428</width>
- <height>235</height>
+ <width>459</width>
+ <height>207</height>
</size>
</property>
<property name="windowTitle">
@@ -47,23 +47,14 @@
<property name="styleSheet">
<string notr="true"/>
</property>
- <layout class="QGridLayout" name="gridLayout_2">
- <property name="sizeConstraint">
- <enum>QLayout::SetMaximumSize</enum>
- </property>
- <property name="horizontalSpacing">
- <number>-1</number>
- </property>
- <property name="verticalSpacing">
- <number>0</number>
- </property>
+ <layout class="QFormLayout" name="formLayout_3">
<item row="0" column="0">
<widget class="QGroupBox" name="groupbox2">
<property name="enabled">
<bool>true</bool>
</property>
<property name="sizePolicy">
- <sizepolicy hsizetype="Fixed" vsizetype="Minimum">
+ <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
@@ -77,29 +68,32 @@
<property name="title">
<string>Basic settings</string>
</property>
- <layout class="QGridLayout" name="gridLayout">
- <property name="leftMargin">
- <number>10</number>
+ <property name="alignment">
+ <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
+ </property>
+ <layout class="QFormLayout" name="formLayout_2">
+ <property name="fieldGrowthPolicy">
+ <enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
- <property name="topMargin">
- <number>10</number>
+ <property name="rowWrapPolicy">
+ <enum>QFormLayout::DontWrapRows</enum>
</property>
- <property name="rightMargin">
- <number>10</number>
+ <property name="labelAlignment">
+ <set>Qt::AlignRight|Qt::AlignTop|Qt::AlignTrailing</set>
</property>
- <property name="bottomMargin">
- <number>2</number>
+ <property name="formAlignment">
+ <set>Qt::AlignRight|Qt::AlignTop|Qt::AlignTrailing</set>
</property>
<property name="horizontalSpacing">
- <number>20</number>
+ <number>6</number>
</property>
<property name="verticalSpacing">
- <number>0</number>
+ <number>2</number>
</property>
- <item row="1" column="0">
+ <item row="0" column="0">
<widget class="QLabel" name="label_2">
<property name="sizePolicy">
- <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
+ <sizepolicy hsizetype="Fixed" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
@@ -112,50 +106,57 @@
</property>
</widget>
</item>
- <item row="1" column="1">
- <widget class="QSpinBox" name="spinZoom">
+ <item row="0" column="1">
+ <widget class="QDoubleSpinBox" name="rotation_alpha">
<property name="sizePolicy">
- <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
+ <sizepolicy hsizetype="Expanding" vsizetype="Minimum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
- <size>
- <width>35</width>
- <height>22</height>
- </size>
+ <property name="alignment">
+ <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
</property>
- <property name="styleSheet">
- <string notr="true">background:none;</string>
+ <property name="correctionMode">
+ <enum>QAbstractSpinBox::CorrectToPreviousValue</enum>
</property>
- <property name="readOnly">
- <bool>false</bool>
+ <property name="decimals">
+ <number>3</number>
</property>
<property name="minimum">
- <number>0</number>
+ <double>0.100000000000000</double>
</property>
<property name="maximum">
- <number>200</number>
+ <double>65535.000000000000000</double>
</property>
<property name="value">
- <number>45</number>
+ <double>1.000000000000000</double>
</property>
</widget>
</item>
- <item row="2" column="1">
- <widget class="QDoubleSpinBox" name="rotation_alpha">
+ <item row="1" column="0">
+ <widget class="QLabel" name="label_3">
<property name="sizePolicy">
- <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
+ <sizepolicy hsizetype="Fixed" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="alignment">
- <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>
+ <property name="text">
+ <string>Translation</string>
</property>
- <property name="correctionMode">
- <enum>QAbstractSpinBox::CorrectToPreviousValue</enum>
+ </widget>
+ </item>
+ <item row="1" column="1">
+ <widget class="QDoubleSpinBox" name="translation_alpha">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Expanding" vsizetype="Minimum">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="alignment">
+ <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
</property>
<property name="decimals">
<number>3</number>
@@ -174,7 +175,7 @@
<item row="2" column="0">
<widget class="QLabel" name="lblSensYaw_5">
<property name="sizePolicy">
- <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
+ <sizepolicy hsizetype="Fixed" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
@@ -200,141 +201,92 @@ background:none;</string>
</property>
</widget>
</item>
- <item row="0" column="0">
- <widget class="QLabel" name="label_3">
+ <item row="2" column="1">
+ <widget class="QSpinBox" name="spinZoom">
<property name="sizePolicy">
- <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
+ <sizepolicy hsizetype="Expanding" vsizetype="Minimum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="text">
- <string>Translation</string>
+ <property name="minimumSize">
+ <size>
+ <width>96</width>
+ <height>22</height>
+ </size>
+ </property>
+ <property name="styleSheet">
+ <string notr="true">background:none;</string>
+ </property>
+ <property name="alignment">
+ <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
+ </property>
+ <property name="readOnly">
+ <bool>false</bool>
+ </property>
+ <property name="suffix">
+ <string>%</string>
+ </property>
+ <property name="minimum">
+ <number>0</number>
+ </property>
+ <property name="maximum">
+ <number>200</number>
+ </property>
+ <property name="singleStep">
+ <number>1</number>
+ </property>
+ <property name="value">
+ <number>45</number>
</property>
</widget>
</item>
- <item row="0" column="1">
- <widget class="QDoubleSpinBox" name="translation_alpha">
+ <item row="3" column="1">
+ <widget class="QLabel" name="label_9">
<property name="sizePolicy">
- <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
+ <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="decimals">
- <number>3</number>
+ <property name="font">
+ <font>
+ <pointsize>8</pointsize>
+ </font>
</property>
- <property name="minimum">
- <double>0.100000000000000</double>
+ <property name="frameShape">
+ <enum>QFrame::NoFrame</enum>
</property>
- <property name="maximum">
- <double>65535.000000000000000</double>
+ <property name="text">
+ <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p align=&quot;justify&quot;&gt;Accela filter by Stanisław Halik&lt;br/&gt;With kind help from Donovan Baarda&lt;/p&gt;&lt;p align=&quot;right&quot;&gt;2012-2013&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
- <property name="value">
- <double>1.000000000000000</double>
+ <property name="textFormat">
+ <enum>Qt::RichText</enum>
+ </property>
+ <property name="scaledContents">
+ <bool>false</bool>
+ </property>
+ <property name="alignment">
+ <set>Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft</set>
+ </property>
+ <property name="wordWrap">
+ <bool>true</bool>
+ </property>
+ <property name="margin">
+ <number>0</number>
+ </property>
+ <property name="textInteractionFlags">
+ <set>Qt::LinksAccessibleByKeyboard|Qt::LinksAccessibleByMouse|Qt::TextBrowserInteraction|Qt::TextSelectableByKeyboard|Qt::TextSelectableByMouse</set>
</property>
</widget>
</item>
</layout>
</widget>
</item>
- <item row="1" column="1">
- <layout class="QHBoxLayout" name="horizontalLayout">
- <property name="spacing">
- <number>-1</number>
- </property>
- <property name="sizeConstraint">
- <enum>QLayout::SetMaximumSize</enum>
- </property>
- <property name="leftMargin">
- <number>0</number>
- </property>
- <property name="topMargin">
- <number>0</number>
- </property>
- <item>
- <widget class="QPushButton" name="btnOK">
- <property name="sizePolicy">
- <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
- <horstretch>0</horstretch>
- <verstretch>0</verstretch>
- </sizepolicy>
- </property>
- <property name="minimumSize">
- <size>
- <width>0</width>
- <height>32</height>
- </size>
- </property>
- <property name="text">
- <string>OK</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QPushButton" name="btnCancel">
- <property name="sizePolicy">
- <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
- <horstretch>0</horstretch>
- <verstretch>0</verstretch>
- </sizepolicy>
- </property>
- <property name="minimumSize">
- <size>
- <width>0</width>
- <height>32</height>
- </size>
- </property>
- <property name="text">
- <string>Cancel</string>
- </property>
- </widget>
- </item>
- </layout>
- </item>
- <item row="1" column="0">
- <widget class="QLabel" name="label_9">
- <property name="sizePolicy">
- <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
- <horstretch>0</horstretch>
- <verstretch>0</verstretch>
- </sizepolicy>
- </property>
- <property name="font">
- <font>
- <pointsize>8</pointsize>
- </font>
- </property>
- <property name="frameShape">
- <enum>QFrame::NoFrame</enum>
- </property>
- <property name="text">
- <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p align=&quot;justify&quot;&gt;Accela filter by Stanisław Halik&lt;br/&gt;With kind help from Donovan Baarda&lt;/p&gt;&lt;p align=&quot;right&quot;&gt;2012-2013&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
- </property>
- <property name="textFormat">
- <enum>Qt::RichText</enum>
- </property>
- <property name="scaledContents">
- <bool>false</bool>
- </property>
- <property name="alignment">
- <set>Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft</set>
- </property>
- <property name="wordWrap">
- <bool>true</bool>
- </property>
- <property name="margin">
- <number>0</number>
- </property>
- <property name="textInteractionFlags">
- <set>Qt::LinksAccessibleByKeyboard|Qt::LinksAccessibleByMouse|Qt::TextBrowserInteraction|Qt::TextSelectableByKeyboard|Qt::TextSelectableByMouse</set>
- </property>
- </widget>
- </item>
<item row="0" column="1">
<widget class="QGroupBox" name="groupBox">
<property name="sizePolicy">
- <sizepolicy hsizetype="Maximum" vsizetype="Maximum">
+ <sizepolicy hsizetype="Maximum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
@@ -356,7 +308,7 @@ background:none;</string>
<number>5</number>
</property>
<property name="topMargin">
- <number>7</number>
+ <number>0</number>
</property>
<property name="rightMargin">
<number>10</number>
@@ -604,6 +556,13 @@ background:none;</string>
</layout>
</widget>
</item>
+ <item row="1" column="0" colspan="2">
+ <widget class="QDialogButtonBox" name="buttonBox">
+ <property name="standardButtons">
+ <set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
+ </property>
+ </widget>
+ </item>
</layout>
</widget>
<resources/>
diff --git a/ftnoir_filter_accela/ftnoir_filter_accela_dialog.cpp b/ftnoir_filter_accela/ftnoir_filter_accela_dialog.cpp
index 0c04a32a..b0999070 100644
--- a/ftnoir_filter_accela/ftnoir_filter_accela_dialog.cpp
+++ b/ftnoir_filter_accela/ftnoir_filter_accela_dialog.cpp
@@ -42,8 +42,8 @@ FilterControls::FilterControls() :
// Load the settings from the current .INI-file
loadSettings();
- connect(ui.btnOK, SIGNAL(clicked()), this, SLOT(doOK()));
- connect(ui.btnCancel, SIGNAL(clicked()), this, SLOT(doCancel()));
+ connect(ui.buttonBox, SIGNAL(accepted()), this, SLOT(doOK()));
+ connect(ui.buttonBox, SIGNAL(rejected()), this, SLOT(doCancel()));
connect(ui.rotation_alpha, SIGNAL(valueChanged(double)), this, SLOT(settingChanged(double)));
connect(ui.translation_alpha, SIGNAL(valueChanged(double)), this, SLOT(settingChanged(double)));