Improve Option dialogs. Make them resizable as possible.

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2018-10-29 19:37:34 +02:00
parent 6d9105729f
commit 8a1eaa7292
6 changed files with 891 additions and 872 deletions

View File

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>501</width> <width>544</width>
<height>726</height> <height>750</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -15,241 +15,260 @@
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<widget class="QGroupBox" name="groupBox_2"> <widget class="QScrollArea" name="scrollArea">
<property name="title"> <property name="widgetResizable">
<string>Language</string> <bool>true</bool>
</property> </property>
<layout class="QFormLayout" name="formLayout"> <widget class="QWidget" name="scrollAreaWidgetContents">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>GUI language:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="langCombo"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Decimal separator parts:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QCheckBox" name="osOptionCheck">
<property name="text">
<string notr="true">&lt; With OS options &gt;</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_3">
<property name="title">
<string>Pattern making system</string>
</property>
<layout class="QFormLayout" name="formLayout_2">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Pattern making system:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="systemCombo"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Author:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="systemAuthorValueLabel">
<property name="text">
<string notr="true">author</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_9">
<property name="text">
<string>Book:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QPlainTextEdit" name="systemBookValueLabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="readOnly">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_5">
<property name="title">
<string>Measurements editing</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPushButton" name="resetWarningsButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Reset warnings</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_6">
<property name="title">
<string>Toolbar</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<item>
<widget class="QCheckBox" name="toolBarStyleCheck">
<property name="text">
<string>The text appears under the icon (recommended for beginners).</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox">
<property name="title">
<string>Default height and size</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Default height:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="defSizeCombo">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item>
<item row="0" column="2">
<widget class="QLabel" name="labelHeightUnit">
<property name="text">
<string notr="true">Height unit</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="defHeightCombo">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item>
<item row="1" column="2">
<widget class="QLabel" name="labelSizeUnit">
<property name="text">
<string notr="true">Size unit</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Default size:</string>
</property>
</widget>
</item>
<item row="0" column="3">
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="1" column="3">
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_4">
<property name="title">
<string>User Interface</string>
</property>
<widget class="QCheckBox" name="darkModeCheck">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>20</x> <x>0</x>
<y>30</y> <y>0</y>
<width>351</width> <width>524</width>
<height>20</height> <height>730</height>
</rect> </rect>
</property> </property>
<property name="text"> <layout class="QVBoxLayout" name="verticalLayout_2">
<string>Activate dark mode(Restart required)</string> <item>
</property> <widget class="QGroupBox" name="groupBox_2">
<property name="title">
<string>Language</string>
</property>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>GUI language:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="langCombo"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Decimal separator parts:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QCheckBox" name="osOptionCheck">
<property name="text">
<string notr="true">&lt; With OS options &gt;</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_3">
<property name="title">
<string>Pattern making system</string>
</property>
<layout class="QFormLayout" name="formLayout_2">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Pattern making system:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="systemCombo"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Author:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="systemAuthorValueLabel">
<property name="text">
<string notr="true">author</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_9">
<property name="text">
<string>Book:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QPlainTextEdit" name="systemBookValueLabel">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="readOnly">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_5">
<property name="title">
<string>Measurements editing</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPushButton" name="resetWarningsButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Reset warnings</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_6">
<property name="title">
<string>Toolbar</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<item>
<widget class="QCheckBox" name="toolBarStyleCheck">
<property name="text">
<string>The text appears under the icon (recommended for beginners).</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox">
<property name="title">
<string>Default height and size</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Default height:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="defSizeCombo">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item>
<item row="0" column="2">
<widget class="QLabel" name="labelHeightUnit">
<property name="text">
<string notr="true">Height unit</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="defHeightCombo">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item>
<item row="1" column="2">
<widget class="QLabel" name="labelSizeUnit">
<property name="text">
<string notr="true">Size unit</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Default size:</string>
</property>
</widget>
</item>
<item row="0" column="3">
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="1" column="3">
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_4">
<property name="title">
<string>User Interface</string>
</property>
<widget class="QCheckBox" name="darkModeCheck">
<property name="geometry">
<rect>
<x>20</x>
<y>30</y>
<width>351</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>Activate dark mode(Restart required)</string>
</property>
</widget>
</widget>
</item>
</layout>
</widget> </widget>
</widget> </widget>
</item> </item>

View File

@ -87,8 +87,6 @@ void DialogTapePreferences::showEvent(QShowEvent *event)
} }
// do your init stuff here // do your init stuff here
setMinimumSize(size());
QSize sz = qApp->Settings()->GetPreferenceDialogSize(); QSize sz = qApp->Settings()->GetPreferenceDialogSize();
if (sz.isEmpty() == false) if (sz.isEmpty() == false)
{ {

View File

@ -6,14 +6,14 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>516</width> <width>680</width>
<height>751</height> <height>624</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
<string notr="true">Configuration</string> <string notr="true">Configuration</string>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_2"> <layout class="QVBoxLayout" name="verticalLayout_6">
<item> <item>
<widget class="QTabWidget" name="tabWidget"> <widget class="QTabWidget" name="tabWidget">
<property name="currentIndex"> <property name="currentIndex">
@ -23,279 +23,264 @@
<attribute name="title"> <attribute name="title">
<string>General</string> <string>General</string>
</attribute> </attribute>
<widget class="QGroupBox" name="saveGroup"> <layout class="QVBoxLayout" name="verticalLayout">
<property name="geometry"> <item>
<rect> <widget class="QScrollArea" name="scrollArea">
<x>20</x> <property name="widgetResizable">
<y>0</y> <bool>true</bool>
<width>441</width> </property>
<height>70</height> <widget class="QWidget" name="scrollAreaWidgetContents">
</rect> <property name="geometry">
</property> <rect>
<property name="title"> <x>0</x>
<string>Save</string> <y>0</y>
</property> <width>624</width>
<layout class="QHBoxLayout" name="horizontalLayout"> <height>707</height>
<item> </rect>
<widget class="QCheckBox" name="autoSaveCheck">
<property name="text">
<string>Auto-save modified pattern</string>
</property>
<property name="checked">
<bool>true</bool>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QGroupBox" name="saveGroup">
<property name="title">
<string>Save</string>
</property>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QCheckBox" name="autoSaveCheck">
<property name="text">
<string>Auto-save modified pattern</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="label">
<property name="text">
<string>Interval:</string>
</property>
</widget>
</item>
<item>
<widget class="QSpinBox" name="autoTime">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="suffix">
<string>min</string>
</property>
<property name="minimum">
<number>1</number>
</property>
<property name="maximum">
<number>60</number>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_2">
<property name="title">
<string>Language</string>
</property>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>GUI language:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="langCombo"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Decimal separator parts:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QCheckBox" name="osOptionCheck">
<property name="text">
<string notr="true">&lt; With OS options &gt;</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Default unit:</string>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Label language:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="unitCombo"/>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="labelCombo"/>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_3">
<property name="title">
<string>Pattern making system</string>
</property>
<layout class="QFormLayout" name="formLayout_2">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Pattern making system:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="systemCombo"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Author:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="systemAuthorValueLabel">
<property name="text">
<string notr="true">author</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_9">
<property name="text">
<string>Book:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QPlainTextEdit" name="systemBookValueLabel">
<property name="readOnly">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_5">
<property name="title">
<string>Pattern editing</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPushButton" name="resetWarningsButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Reset warnings</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="checkBoxFreeCurve">
<property name="toolTip">
<string>Update a pattern only after a curve release</string>
</property>
<property name="text">
<string>Free curve mode</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="checkBoxZoomFitBestCurrentPP">
<property name="text">
<string>Double click calls Zoom fit best for current pattern piece</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_6">
<property name="title">
<string>Toolbar</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<item>
<widget class="QCheckBox" name="toolBarStyleCheck">
<property name="text">
<string>The text appears under the icon (recommended for beginners).</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_8">
<property name="title">
<string>User Interface</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_7">
<item>
<widget class="QCheckBox" name="darkModeCheck">
<property name="text">
<string>Activate dark mode(Restart required)</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
</widget> </widget>
</item> </widget>
<item> </item>
<widget class="QLabel" name="label"> </layout>
<property name="text">
<string>Interval:</string>
</property>
</widget>
</item>
<item>
<widget class="QSpinBox" name="autoTime">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="suffix">
<string>min</string>
</property>
<property name="minimum">
<number>1</number>
</property>
<property name="maximum">
<number>60</number>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QGroupBox" name="groupBox_2">
<property name="geometry">
<rect>
<x>20</x>
<y>70</y>
<width>441</width>
<height>173</height>
</rect>
</property>
<property name="title">
<string>Language</string>
</property>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>GUI language:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="langCombo"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Decimal separator parts:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QCheckBox" name="osOptionCheck">
<property name="text">
<string notr="true">&lt; With OS options &gt;</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Default unit:</string>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Label language:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="unitCombo"/>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="labelCombo"/>
</item>
</layout>
</widget>
<widget class="QGroupBox" name="groupBox_3">
<property name="geometry">
<rect>
<x>20</x>
<y>243</y>
<width>446</width>
<height>185</height>
</rect>
</property>
<property name="title">
<string>Pattern making system</string>
</property>
<layout class="QFormLayout" name="formLayout_2">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Pattern making system:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="systemCombo"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Author:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="systemAuthorValueLabel">
<property name="text">
<string notr="true">author</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_9">
<property name="text">
<string>Book:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QPlainTextEdit" name="systemBookValueLabel">
<property name="readOnly">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QGroupBox" name="groupBox_5">
<property name="geometry">
<rect>
<x>20</x>
<y>428</y>
<width>451</width>
<height>131</height>
</rect>
</property>
<property name="title">
<string>Pattern editing</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QPushButton" name="resetWarningsButton">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Reset warnings</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="checkBoxFreeCurve">
<property name="toolTip">
<string>Update a pattern only after a curve release</string>
</property>
<property name="text">
<string>Free curve mode</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="checkBoxZoomFitBestCurrentPP">
<property name="text">
<string>Double click calls Zoom fit best for current pattern piece</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QGroupBox" name="groupBox_6">
<property name="geometry">
<rect>
<x>20</x>
<y>560</y>
<width>451</width>
<height>71</height>
</rect>
</property>
<property name="title">
<string>Toolbar</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<item>
<widget class="QCheckBox" name="toolBarStyleCheck">
<property name="text">
<string>The text appears under the icon (recommended for beginners).</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QGroupBox" name="groupBox_8">
<property name="geometry">
<rect>
<x>20</x>
<y>630</y>
<width>446</width>
<height>71</height>
</rect>
</property>
<property name="title">
<string>User Interface</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_7">
<item>
<widget class="QCheckBox" name="darkModeCheck">
<property name="text">
<string>Activate dark mode(Restart required)</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</widget> </widget>
<widget class="QWidget" name="tabScrolling"> <widget class="QWidget" name="tabScrolling">
<attribute name="title"> <attribute name="title">

View File

@ -6,379 +6,398 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>381</width> <width>373</width>
<height>727</height> <height>760</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
<string notr="true">Pattern</string> <string notr="true">Pattern</string>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_2"> <layout class="QVBoxLayout" name="verticalLayout_5">
<item> <item>
<widget class="QGroupBox" name="groupBox_2"> <widget class="QScrollArea" name="scrollArea">
<property name="title"> <property name="widgetResizable">
<string>Graphical output</string> <bool>true</bool>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_3"> <widget class="QWidget" name="scrollAreaWidgetContents">
<item> <property name="geometry">
<widget class="QCheckBox" name="graphOutputCheck"> <rect>
<property name="text"> <x>0</x>
<string>Use antialiasing</string> <y>0</y>
</property> <width>353</width>
</widget> <height>740</height>
</item> </rect>
<item> </property>
<widget class="QCheckBox" name="checkBoxOpenGLRender"> <layout class="QVBoxLayout" name="verticalLayout_2">
<property name="toolTip"> <item>
<string>Use OpenGL to render a scene. <widget class="QGroupBox" name="groupBox_2">
<property name="title">
<string>Graphical output</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QCheckBox" name="graphOutputCheck">
<property name="text">
<string>Use antialiasing</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="checkBoxOpenGLRender">
<property name="toolTip">
<string>Use OpenGL to render a scene.
This option will take an affect after restart.</string> This option will take an affect after restart.</string>
</property> </property>
<property name="text"> <property name="text">
<string>Use OpenGL render</string> <string>Use OpenGL render</string>
</property> </property>
<property name="tristate"> <property name="tristate">
<bool>false</bool> <bool>false</bool>
</property> </property>
</widget> </widget>
</item> </item>
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_5"> <layout class="QHBoxLayout" name="horizontalLayout_5">
<item> <item>
<widget class="QLabel" name="label"> <widget class="QLabel" name="label">
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Preferred"> <sizepolicy hsizetype="Minimum" vsizetype="Preferred">
<horstretch>0</horstretch> <horstretch>0</horstretch>
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
</property>
<property name="text">
<string>Curve approximation:</string>
</property>
</widget>
</item>
<item>
<widget class="QDoubleSpinBox" name="doubleSpinBoxCurveApproximation">
<property name="toolTip">
<string>Set default curve approximation scale</string>
</property>
<property name="decimals">
<number>1</number>
</property>
<property name="minimum">
<double>0.100000000000000</double>
</property>
<property name="maximum">
<double>10.000000000000000</double>
</property>
<property name="singleStep">
<double>0.100000000000000</double>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_6">
<item>
<widget class="QLabel" name="label_6">
<property name="toolTip">
<string>Bold line width</string>
</property>
<property name="text">
<string>Line width:</string>
</property>
</widget>
</item>
<item>
<widget class="QDoubleSpinBox" name="doubleSpinBoxLineWidth">
<property name="suffix">
<string/>
</property>
<property name="decimals">
<number>6</number>
</property>
<property name="singleStep">
<double>0.100000000000000</double>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBoxLineWidthUnit">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>500</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_3">
<property name="title">
<string>Undo</string>
</property>
<layout class="QFormLayout" name="formLayout_2">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
<property name="text"> <item row="0" column="0">
<string>Curve approximation:</string> <widget class="QLabel" name="label_2">
<property name="text">
<string>Count steps (0 - no limit):</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QSpinBox" name="undoCount"/>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_5">
<property name="title">
<string>Workpiece</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<item>
<widget class="QCheckBox" name="forbidFlippingCheck">
<property name="toolTip">
<string>By default forbid flipping for all new created workpieces</string>
</property>
<property name="text">
<string>Forbid flipping</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="doublePassmarkCheck">
<property name="toolTip">
<string>Show a passmark both in the seam allowance and on the seam line.</string>
</property>
<property name="text">
<string>Show second passmark on seam line</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="checkBoxHideMainPath">
<property name="toolTip">
<string>By default hide the main path if the seam allowance was enabled</string>
</property>
<property name="text">
<string>Hide main path</string>
</property>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QLabel" name="label_3">
<property name="text">
<string>Label font:</string>
</property>
</widget>
</item>
<item>
<widget class="QFontComboBox" name="fontComboBoxLabelFont"/>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_6">
<property name="title">
<string>Seam allowance</string>
</property>
<layout class="QFormLayout" name="formLayout_3">
<item row="0" column="0">
<widget class="QLabel" name="label_defaultSeamAllowance">
<property name="text">
<string>Default value:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QDoubleSpinBox" name="defaultSeamAllowance">
<property name="decimals">
<number>3</number>
</property>
<property name="maximum">
<double>100.000000000000000</double>
</property>
<property name="singleStep">
<double>0.100000000000000</double>
</property>
<property name="value">
<double>1.000000000000000</double>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_4">
<property name="title">
<string>Label data/time format</string>
</property>
<layout class="QFormLayout" name="formLayout_4">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property> </property>
</widget> <item row="0" column="0">
</item> <widget class="QLabel" name="label_4">
<item> <property name="text">
<widget class="QDoubleSpinBox" name="doubleSpinBoxCurveApproximation"> <string>Date:</string>
<property name="toolTip"> </property>
<string>Set default curve approximation scale</string> </widget>
</property> </item>
<property name="decimals"> <item row="0" column="1">
<number>1</number> <layout class="QHBoxLayout" name="horizontalLayout_2">
</property> <item>
<property name="minimum"> <widget class="QComboBox" name="comboBoxDateFormats"/>
<double>0.100000000000000</double> </item>
</property> <item>
<property name="maximum"> <widget class="QPushButton" name="pushButtonEditDateFormats">
<double>10.000000000000000</double> <property name="text">
</property> <string>Edit formats</string>
<property name="singleStep"> </property>
<double>0.100000000000000</double> </widget>
</property> </item>
</widget> </layout>
</item> </item>
<item> <item row="1" column="0">
<spacer name="horizontalSpacer_2"> <widget class="QLabel" name="label_5">
<property name="orientation"> <property name="text">
<enum>Qt::Horizontal</enum> <string>Time:</string>
</property> </property>
<property name="sizeHint" stdset="0"> </widget>
<size> </item>
<width>40</width> <item row="1" column="1">
<height>20</height> <layout class="QHBoxLayout" name="horizontalLayout_3">
</size> <item>
</property> <widget class="QComboBox" name="comboBoxTimeFormats"/>
</spacer> </item>
</item> <item>
</layout> <widget class="QPushButton" name="pushButtonEditTimeFormats">
</item> <property name="text">
<item> <string>Edit formats</string>
<layout class="QHBoxLayout" name="horizontalLayout_6"> </property>
<item> </widget>
<widget class="QLabel" name="label_6"> </item>
<property name="toolTip"> </layout>
<string>Bold line width</string> </item>
</property> </layout>
<property name="text"> </widget>
<string>Line width:</string> </item>
</property> <item>
</widget> <widget class="QGroupBox" name="groupBox">
</item> <property name="title">
<item> <string>Materials</string>
<widget class="QDoubleSpinBox" name="doubleSpinBoxLineWidth"> </property>
<property name="suffix"> <layout class="QVBoxLayout" name="verticalLayout">
<string/> <item>
</property> <layout class="QHBoxLayout" name="horizontalLayout_4">
<property name="decimals"> <item>
<number>6</number> <widget class="QLabel" name="label_12">
</property> <property name="text">
<property name="singleStep"> <string>Known materials:</string>
<double>0.100000000000000</double> </property>
</property> </widget>
</widget> </item>
</item> <item>
<item> <widget class="QPushButton" name="pushButtonKnownMaterials">
<widget class="QComboBox" name="comboBoxLineWidthUnit"> <property name="sizePolicy">
<property name="sizePolicy"> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed"> <horstretch>0</horstretch>
<horstretch>0</horstretch> <verstretch>0</verstretch>
<verstretch>0</verstretch> </sizepolicy>
</sizepolicy> </property>
</property> <property name="toolTip">
</widget> <string>Manage list of known materials</string>
</item> </property>
<item> <property name="text">
<spacer name="horizontalSpacer_3"> <string>Manage</string>
<property name="orientation"> </property>
<enum>Qt::Horizontal</enum> </widget>
</property> </item>
<property name="sizeHint" stdset="0"> <item>
<size> <spacer name="horizontalSpacer">
<width>500</width> <property name="orientation">
<height>20</height> <enum>Qt::Horizontal</enum>
</size> </property>
</property> <property name="sizeHint" stdset="0">
</spacer> <size>
</item> <width>40</width>
</layout> <height>20</height>
</item> </size>
</layout> </property>
</spacer>
</item>
</layout>
</item>
<item>
<widget class="QCheckBox" name="checkBoxRemeberPatternMaterials">
<property name="toolTip">
<string>When manage pattern materials save them to known materials list</string>
</property>
<property name="text">
<string>Remeber pattern materials</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</widget> </widget>
</item> </item>
<item>
<widget class="QGroupBox" name="groupBox_3">
<property name="title">
<string>Undo</string>
</property>
<layout class="QFormLayout" name="formLayout_2">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>Count steps (0 - no limit):</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QSpinBox" name="undoCount"/>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_5">
<property name="title">
<string>Workpiece</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<item>
<widget class="QCheckBox" name="forbidFlippingCheck">
<property name="toolTip">
<string>By default forbid flipping for all new created workpieces</string>
</property>
<property name="text">
<string>Forbid flipping</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="doublePassmarkCheck">
<property name="toolTip">
<string>Show a passmark both in the seam allowance and on the seam line.</string>
</property>
<property name="text">
<string>Show second passmark on seam line</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="checkBoxHideMainPath">
<property name="toolTip">
<string>By default hide the main path if the seam allowance was enabled</string>
</property>
<property name="text">
<string>Hide main path</string>
</property>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QLabel" name="label_3">
<property name="text">
<string>Label font:</string>
</property>
</widget>
</item>
<item>
<widget class="QFontComboBox" name="fontComboBoxLabelFont"/>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_6">
<property name="title">
<string>Seam allowance</string>
</property>
<layout class="QFormLayout" name="formLayout_3">
<item row="0" column="0">
<widget class="QLabel" name="label_defaultSeamAllowance">
<property name="text">
<string>Default value:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QDoubleSpinBox" name="defaultSeamAllowance">
<property name="decimals">
<number>3</number>
</property>
<property name="maximum">
<double>100.000000000000000</double>
</property>
<property name="singleStep">
<double>0.100000000000000</double>
</property>
<property name="value">
<double>1.000000000000000</double>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox_4">
<property name="title">
<string>Label data/time format</string>
</property>
<layout class="QFormLayout" name="formLayout_4">
<property name="fieldGrowthPolicy">
<enum>QFormLayout::ExpandingFieldsGrow</enum>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Date:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<widget class="QComboBox" name="comboBoxDateFormats"/>
</item>
<item>
<widget class="QPushButton" name="pushButtonEditDateFormats">
<property name="text">
<string>Edit formats</string>
</property>
</widget>
</item>
</layout>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Time:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="QComboBox" name="comboBoxTimeFormats"/>
</item>
<item>
<widget class="QPushButton" name="pushButtonEditTimeFormats">
<property name="text">
<string>Edit formats</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="groupBox">
<property name="title">
<string>Materials</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<layout class="QHBoxLayout" name="horizontalLayout_4">
<item>
<widget class="QLabel" name="label_12">
<property name="text">
<string>Known materials:</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="pushButtonKnownMaterials">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Manage list of known materials</string>
</property>
<property name="text">
<string>Manage</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item>
<widget class="QCheckBox" name="checkBoxRemeberPatternMaterials">
<property name="toolTip">
<string>When manage pattern materials save them to known materials list</string>
</property>
<property name="text">
<string>Remeber pattern materials</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout> </layout>
</widget> </widget>
<resources/> <resources/>

View File

@ -90,8 +90,6 @@ void DialogPreferences::showEvent(QShowEvent *event)
} }
// do your init stuff here // do your init stuff here
setMinimumSize(size());
QSize sz = qApp->Settings()->GetPreferenceDialogSize(); QSize sz = qApp->Settings()->GetPreferenceDialogSize();
if (sz.isEmpty() == false) if (sz.isEmpty() == false)
{ {

View File

@ -6,7 +6,7 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>712</width> <width>827</width>
<height>522</height> <height>522</height>
</rect> </rect>
</property> </property>