Skip to content

Commit a036b79

Browse files
committed
Merge pull request #3347
7e195e8 [Qt] massive options/settings rework (no core changes) (Philip Kaufmann)
2 parents 131fb42 + 7e195e8 commit a036b79

File tree

5 files changed

+441
-241
lines changed

5 files changed

+441
-241
lines changed

src/qt/forms/optionsdialog.ui

Lines changed: 175 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
<rect>
77
<x>0</x>
88
<y>0</y>
9-
<width>540</width>
10-
<height>380</height>
9+
<width>560</width>
10+
<height>400</height>
1111
</rect>
1212
</property>
1313
<property name="windowTitle">
@@ -19,9 +19,6 @@
1919
<layout class="QVBoxLayout" name="verticalLayout">
2020
<item>
2121
<widget class="QTabWidget" name="tabWidget">
22-
<property name="tabPosition">
23-
<enum>QTabWidget::North</enum>
24-
</property>
2522
<property name="currentIndex">
2623
<number>0</number>
2724
</property>
@@ -86,21 +83,44 @@
8683
</property>
8784
</widget>
8885
</item>
89-
<item>
90-
<spacer name="verticalSpacer_Main">
91-
<property name="orientation">
92-
<enum>Qt::Vertical</enum>
93-
</property>
94-
<property name="sizeHint" stdset="0">
95-
<size>
96-
<width>20</width>
97-
<height>40</height>
98-
</size>
99-
</property>
100-
</spacer>
101-
</item>
10286
<item>
10387
<layout class="QHBoxLayout" name="horizontalLayout_2_Main">
88+
<item>
89+
<widget class="QLabel" name="databaseCacheLabel">
90+
<property name="text">
91+
<string>Size of &amp;database cache</string>
92+
</property>
93+
<property name="textFormat">
94+
<enum>Qt::PlainText</enum>
95+
</property>
96+
<property name="buddy">
97+
<cstring>databaseCache</cstring>
98+
</property>
99+
</widget>
100+
</item>
101+
<item>
102+
<widget class="QSpinBox" name="databaseCache">
103+
<property name="toolTip">
104+
<string>Set database cache size in megabytes (default: 25)</string>
105+
</property>
106+
<property name="maximum">
107+
<number>1024</number>
108+
</property>
109+
<property name="value">
110+
<number>25</number>
111+
</property>
112+
</widget>
113+
</item>
114+
<item>
115+
<widget class="QLabel" name="databaseCacheUnitLabel">
116+
<property name="text">
117+
<string>MB</string>
118+
</property>
119+
<property name="textFormat">
120+
<enum>Qt::PlainText</enum>
121+
</property>
122+
</widget>
123+
</item>
104124
<item>
105125
<spacer name="horizontalSpacer_2_Main">
106126
<property name="orientation">
@@ -114,21 +134,64 @@
114134
</property>
115135
</spacer>
116136
</item>
137+
</layout>
138+
</item>
139+
<item>
140+
<layout class="QHBoxLayout" name="horizontalLayout_3_Main">
141+
<item>
142+
<widget class="QLabel" name="threadsScriptVerifLabel">
143+
<property name="text">
144+
<string>Number of script &amp;verification threads</string>
145+
</property>
146+
<property name="textFormat">
147+
<enum>Qt::PlainText</enum>
148+
</property>
149+
<property name="buddy">
150+
<cstring>threadsScriptVerif</cstring>
151+
</property>
152+
</widget>
153+
</item>
117154
<item>
118-
<widget class="QPushButton" name="resetButton">
155+
<widget class="QSpinBox" name="threadsScriptVerif">
119156
<property name="toolTip">
120-
<string>Reset all client options to default.</string>
157+
<string>Set the number of script verification threads (up to 16, 0 = auto, &lt;0 = leave that many cores free, default: 0)</string>
121158
</property>
122-
<property name="text">
123-
<string>&amp;Reset Options</string>
159+
<property name="minimum">
160+
<number>-16</number>
124161
</property>
125-
<property name="autoDefault">
126-
<bool>false</bool>
162+
<property name="maximum">
163+
<number>16</number>
127164
</property>
128165
</widget>
129166
</item>
167+
<item>
168+
<spacer name="horizontalSpacer_3_Main">
169+
<property name="orientation">
170+
<enum>Qt::Horizontal</enum>
171+
</property>
172+
<property name="sizeHint" stdset="0">
173+
<size>
174+
<width>40</width>
175+
<height>20</height>
176+
</size>
177+
</property>
178+
</spacer>
179+
</item>
130180
</layout>
131181
</item>
182+
<item>
183+
<spacer name="verticalSpacer_Main">
184+
<property name="orientation">
185+
<enum>Qt::Vertical</enum>
186+
</property>
187+
<property name="sizeHint" stdset="0">
188+
<size>
189+
<width>20</width>
190+
<height>40</height>
191+
</size>
192+
</property>
193+
</spacer>
194+
</item>
132195
</layout>
133196
</widget>
134197
<widget class="QWidget" name="tabNetwork">
@@ -149,15 +212,15 @@
149212
<item>
150213
<widget class="QCheckBox" name="connectSocks">
151214
<property name="toolTip">
152-
<string>Connect to the Bitcoin network through a SOCKS proxy (e.g. when connecting through Tor).</string>
215+
<string>Connect to the Bitcoin network through a SOCKS proxy.</string>
153216
</property>
154217
<property name="text">
155-
<string>&amp;Connect through SOCKS proxy:</string>
218+
<string>&amp;Connect through SOCKS proxy (default proxy):</string>
156219
</property>
157220
</widget>
158221
</item>
159222
<item>
160-
<layout class="QHBoxLayout" name="horizontalLayout_Network">
223+
<layout class="QHBoxLayout" name="horizontalLayout_1_Network">
161224
<item>
162225
<widget class="QLabel" name="proxyIpLabel">
163226
<property name="text">
@@ -173,14 +236,20 @@
173236
</item>
174237
<item>
175238
<widget class="QValidatedLineEdit" name="proxyIp">
239+
<property name="minimumSize">
240+
<size>
241+
<width>140</width>
242+
<height>0</height>
243+
</size>
244+
</property>
176245
<property name="maximumSize">
177246
<size>
178247
<width>140</width>
179248
<height>16777215</height>
180249
</size>
181250
</property>
182251
<property name="toolTip">
183-
<string>IP address of the proxy (e.g. 127.0.0.1)</string>
252+
<string>IP address of the proxy (e.g. IPv4: 127.0.0.1 / IPv6: ::1)</string>
184253
</property>
185254
</widget>
186255
</item>
@@ -199,6 +268,12 @@
199268
</item>
200269
<item>
201270
<widget class="QLineEdit" name="proxyPort">
271+
<property name="minimumSize">
272+
<size>
273+
<width>55</width>
274+
<height>0</height>
275+
</size>
276+
</property>
202277
<property name="maximumSize">
203278
<size>
204279
<width>55</width>
@@ -231,7 +306,7 @@
231306
</widget>
232307
</item>
233308
<item>
234-
<spacer name="horizontalSpacer_Network">
309+
<spacer name="horizontalSpacer_1_Network">
235310
<property name="orientation">
236311
<enum>Qt::Horizontal</enum>
237312
</property>
@@ -390,8 +465,67 @@
390465
</widget>
391466
</widget>
392467
</item>
468+
<item>
469+
<widget class="QFrame" name="frame">
470+
<layout class="QVBoxLayout" name="verticalLayout_Bottom">
471+
<item>
472+
<layout class="QHBoxLayout" name="horizontalLayout_Bottom">
473+
<item>
474+
<widget class="QLabel" name="overriddenByCommandLineInfoLabel">
475+
<property name="text">
476+
<string>Active command-line options that override above options: </string>
477+
</property>
478+
<property name="textFormat">
479+
<enum>Qt::PlainText</enum>
480+
</property>
481+
</widget>
482+
</item>
483+
<item>
484+
<spacer name="horizontalSpacer_Bottom">
485+
<property name="orientation">
486+
<enum>Qt::Horizontal</enum>
487+
</property>
488+
<property name="sizeHint" stdset="0">
489+
<size>
490+
<width>40</width>
491+
<height>20</height>
492+
</size>
493+
</property>
494+
</spacer>
495+
</item>
496+
</layout>
497+
</item>
498+
<item>
499+
<widget class="QLabel" name="overriddenByCommandLineLabel">
500+
<property name="text">
501+
<string/>
502+
</property>
503+
<property name="textFormat">
504+
<enum>Qt::PlainText</enum>
505+
</property>
506+
<property name="wordWrap">
507+
<bool>true</bool>
508+
</property>
509+
</widget>
510+
</item>
511+
</layout>
512+
</widget>
513+
</item>
393514
<item>
394515
<layout class="QHBoxLayout" name="horizontalLayout_Buttons">
516+
<item>
517+
<widget class="QPushButton" name="resetButton">
518+
<property name="toolTip">
519+
<string>Reset all client options to default.</string>
520+
</property>
521+
<property name="text">
522+
<string>&amp;Reset Options</string>
523+
</property>
524+
<property name="autoDefault">
525+
<bool>false</bool>
526+
</property>
527+
</widget>
528+
</item>
395529
<item>
396530
<spacer name="horizontalSpacer_1">
397531
<property name="orientation">
@@ -407,6 +541,12 @@
407541
</item>
408542
<item>
409543
<widget class="QLabel" name="statusLabel">
544+
<property name="minimumSize">
545+
<size>
546+
<width>200</width>
547+
<height>0</height>
548+
</size>
549+
</property>
410550
<property name="font">
411551
<font>
412552
<weight>75</weight>
@@ -454,16 +594,6 @@
454594
</property>
455595
</widget>
456596
</item>
457-
<item>
458-
<widget class="QPushButton" name="applyButton">
459-
<property name="text">
460-
<string>&amp;Apply</string>
461-
</property>
462-
<property name="autoDefault">
463-
<bool>false</bool>
464-
</property>
465-
</widget>
466-
</item>
467597
</layout>
468598
</item>
469599
</layout>
@@ -473,17 +603,18 @@
473603
<class>BitcoinAmountField</class>
474604
<extends>QLineEdit</extends>
475605
<header>bitcoinamountfield.h</header>
476-
</customwidget>
477-
<customwidget>
478-
<class>QValueComboBox</class>
479-
<extends>QComboBox</extends>
480-
<header>qvaluecombobox.h</header>
606+
<container>1</container>
481607
</customwidget>
482608
<customwidget>
483609
<class>QValidatedLineEdit</class>
484610
<extends>QLineEdit</extends>
485611
<header>qvalidatedlineedit.h</header>
486612
</customwidget>
613+
<customwidget>
614+
<class>QValueComboBox</class>
615+
<extends>QComboBox</extends>
616+
<header>qvaluecombobox.h</header>
617+
</customwidget>
487618
</customwidgets>
488619
<resources/>
489620
<connections/>

0 commit comments

Comments
 (0)