RUIC 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (90) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +21 -0
  3. data/README.md +201 -0
  4. data/bin/ruic +52 -0
  5. data/gui/MetaData.xml +387 -0
  6. data/gui/TODO +2 -0
  7. data/gui/appattributesmodel.rb +51 -0
  8. data/gui/appelementsmodel.rb +126 -0
  9. data/gui/launch.rb +20 -0
  10. data/gui/makefile +14 -0
  11. data/gui/resources.qrc +37 -0
  12. data/gui/resources/images/Objects-Behavior-Normal.png +0 -0
  13. data/gui/resources/images/Objects-Camera-Normal.png +0 -0
  14. data/gui/resources/images/Objects-Component-Normal.png +0 -0
  15. data/gui/resources/images/Objects-Effect-Normal.png +0 -0
  16. data/gui/resources/images/Objects-Group-Normal.png +0 -0
  17. data/gui/resources/images/Objects-Image-Normal.png +0 -0
  18. data/gui/resources/images/Objects-Layer-Normal.png +0 -0
  19. data/gui/resources/images/Objects-Light-Normal.png +0 -0
  20. data/gui/resources/images/Objects-Material-Normal.png +0 -0
  21. data/gui/resources/images/Objects-Model-Normal.png +0 -0
  22. data/gui/resources/images/Objects-Music-Normal.png +0 -0
  23. data/gui/resources/images/Objects-Property-Normal.png +0 -0
  24. data/gui/resources/images/Objects-References-Normal.png +0 -0
  25. data/gui/resources/images/Objects-Scene-Normal.png +0 -0
  26. data/gui/resources/images/Objects-Sound-Normal.png +0 -0
  27. data/gui/resources/images/Objects-Text-Normal.png +0 -0
  28. data/gui/resources/images/Objects-Unknown-Normal.png +0 -0
  29. data/gui/resources/images/Objects-Video-Normal.png +0 -0
  30. data/gui/resources/images/SCXML.ico +0 -0
  31. data/gui/resources/images/TSCXML.ico +0 -0
  32. data/gui/resources/images/UIA.ico +0 -0
  33. data/gui/resources/images/clipboard.png +0 -0
  34. data/gui/resources/images/console_arrow.png +0 -0
  35. data/gui/resources/images/cross.png +0 -0
  36. data/gui/resources/images/currentline.png +0 -0
  37. data/gui/resources/images/disk-black.png +0 -0
  38. data/gui/resources/images/disks-black.png +0 -0
  39. data/gui/resources/images/document--plus.png +0 -0
  40. data/gui/resources/images/document-copy.png +0 -0
  41. data/gui/resources/images/executable-actions-delete-active.png +0 -0
  42. data/gui/resources/images/executable-actions-delete-idle.png +0 -0
  43. data/gui/resources/images/executable-actions-enter-badge.png +0 -0
  44. data/gui/resources/images/executable-actions-exit-badge.png +0 -0
  45. data/gui/resources/images/folder-horizontal--plus.png +0 -0
  46. data/gui/resources/images/folder-horizontal-open.png +0 -0
  47. data/gui/resources/images/gear.png +0 -0
  48. data/gui/resources/images/invalid_breakpoint.png +0 -0
  49. data/gui/resources/images/scissors-blue.png +0 -0
  50. data/gui/resources/images/slide-16-active.png +0 -0
  51. data/gui/resources/images/slide-16-master.png +0 -0
  52. data/gui/resources/images/slide-16-normal.png +0 -0
  53. data/gui/resources/images/slide-32-active.png +0 -0
  54. data/gui/resources/images/slide-32-master.png +0 -0
  55. data/gui/resources/images/slide-32-normal.png +0 -0
  56. data/gui/resources/images/studio_architect32.ico +0 -0
  57. data/gui/resources/images/studio_architect32.png +0 -0
  58. data/gui/resources/images/textfile_icon.png +0 -0
  59. data/gui/resources/style/checkbox.png +0 -0
  60. data/gui/resources/style/dark.qss +459 -0
  61. data/gui/resources/style/down_arrow.png +0 -0
  62. data/gui/resources/style/handle.png +0 -0
  63. data/gui/window.rb +90 -0
  64. data/gui/window.ui +753 -0
  65. data/lib/ruic.rb +59 -0
  66. data/lib/ruic/application.rb +129 -0
  67. data/lib/ruic/asset_classes.rb +448 -0
  68. data/lib/ruic/behaviors.rb +31 -0
  69. data/lib/ruic/interfaces.rb +36 -0
  70. data/lib/ruic/presentation.rb +354 -0
  71. data/lib/ruic/statemachine.rb +111 -0
  72. data/lib/ruic/version.rb +3 -0
  73. data/ruic.gemspec +23 -0
  74. data/test/MetaData.xml +387 -0
  75. data/test/customclasses.ruic +21 -0
  76. data/test/filtering.ruic +39 -0
  77. data/test/nonmaster.ruic +21 -0
  78. data/test/projects/CustomClasses/Brush Strokes.effect +38 -0
  79. data/test/projects/CustomClasses/CustomClasses.uia +6 -0
  80. data/test/projects/CustomClasses/CustomClasses.uip +34 -0
  81. data/test/projects/CustomClasses/copper.material +194 -0
  82. data/test/projects/CustomClasses/maps/UV-Checker.png +0 -0
  83. data/test/projects/CustomClasses/maps/effects/brushnoise.dds +0 -0
  84. data/test/projects/CustomClasses/maps/materials/spherical_checker.png +0 -0
  85. data/test/projects/ReferencedMaterials/ReferencedMaterials.uia +6 -0
  86. data/test/projects/ReferencedMaterials/ReferencedMaterials.uip +39 -0
  87. data/test/properties.ruic +81 -0
  88. data/test/referencematerials.ruic +53 -0
  89. data/test/usage.ruic +20 -0
  90. metadata +166 -0
@@ -0,0 +1,2 @@
1
+ * Preferences file for last opened file directory - yml?
2
+ * Revert!
@@ -0,0 +1,51 @@
1
+ module UIC; end
2
+ class UIC::GUI::AppAttributesModel < Qt::AbstractItemModel
3
+ INVALIDINDEX = Qt::ModelIndex.new
4
+ NODATA = Qt::Variant.new
5
+ def initialize(qtparent,el)
6
+ super(qtparent)
7
+ @indexes = {} # indexed by [row,col]
8
+ @root = Qt::ModelIndex.new
9
+ @el = el
10
+ el.properties.values.sort_by{ |p| p.formal.downcase }.each.with_index do |prop,i|
11
+ @indexes[[i,0]] = createIndex( i, 0, Qt::Variant.new(prop.formal) )
12
+ @indexes[[i,1]] = createIndex( i, 1, Qt::Variant.new(el[prop.name,0].to_s) )
13
+ end
14
+ end
15
+
16
+ def columnCount( *any )
17
+ 2
18
+ end
19
+
20
+ def index( row, col, parent=INVALIDINDEX )
21
+ @indexes[[row,col]]
22
+ end
23
+
24
+ def headerData(section, orientation, role=Qt::DisplayRole)
25
+ if orientation==Qt::Horizontal && role==Qt::DisplayRole
26
+ case section
27
+ when 0; Qt::Variant.new(tr("Attribute"))
28
+ when 1; Qt::Variant.new(tr("Value"))
29
+ else ; NODATA
30
+ end
31
+ else
32
+ NODATA
33
+ end
34
+ end
35
+
36
+ def parent(child)
37
+ child.valid? ? @root : @INVALIDINDEX
38
+ end
39
+
40
+ def rowCount( parent=INVALIDINDEX )
41
+ @rowcount ||= @el.properties.length
42
+ end
43
+
44
+ def data(index, role)
45
+ if index.valid? && role == Qt::DisplayRole
46
+ index.internal_pointer
47
+ else
48
+ NODATA
49
+ end
50
+ end
51
+ end
@@ -0,0 +1,126 @@
1
+ module UIC; end
2
+ class UIC::GUI::AppElementsModel < Qt::AbstractItemModel
3
+ INVALIDINDEX = Qt::ModelIndex.new
4
+ NODATA = Qt::Variant.new
5
+ def initialize(qtparent,app)
6
+ super(qtparent)
7
+ @root = El.new(app,0)
8
+ end
9
+
10
+ def columnCount( *any )
11
+ 2
12
+ end
13
+
14
+ def index( row, col, parent=INVALIDINDEX )
15
+ parentEl = parent.valid? ? parent.internal_pointer : @root
16
+ if childEl=parentEl.child(row)
17
+ createIndex(row,col,childEl)
18
+ else
19
+ INVALIDINDEX
20
+ end
21
+ end
22
+
23
+ def headerData(section, orientation, role=Qt::DisplayRole)
24
+ if orientation==Qt::Horizontal && role==Qt::DisplayRole
25
+ case section
26
+ when 0; Qt::Variant.new(tr("Name"))
27
+ when 1; Qt::Variant.new(tr("Type"))
28
+ else ; NODATA
29
+ end
30
+ else
31
+ NODATA
32
+ end
33
+ end
34
+
35
+ def parent(child)
36
+ if child.valid?
37
+ parentEl = child.internal_pointer.parent
38
+ if parentEl.nil? || parentEl==@root
39
+ INVALIDINDEX
40
+ else
41
+ createIndex(parentEl.row, 0, parentEl)
42
+ end
43
+ else
44
+ INVALIDINDEX
45
+ end
46
+ end
47
+
48
+ def rowCount( parent=INVALIDINDEX )
49
+ parentEl = parent.valid? ? parent.internal_pointer : @root
50
+ parentEl.child_count
51
+ end
52
+
53
+ def data(index, role)
54
+ if index.valid?
55
+ element = index.internal_pointer
56
+ case role
57
+ when Qt::DisplayRole
58
+ case index.column
59
+ when 0; Qt::Variant.new(element.displayName)
60
+ when 1; Qt::Variant.new(element.displayType)
61
+ else ; NODATA
62
+ end
63
+ when Qt::DecorationRole
64
+ index.column==0 ? element.icon : NODATA
65
+ else
66
+ NODATA
67
+ end
68
+ else
69
+ NODATA
70
+ end
71
+ end
72
+ end
73
+
74
+ class UIC::GUI::AppElementsModel::El
75
+ @by_el = {}
76
+ class << self
77
+ def [](el,row)
78
+ @by_el[el] ||= self.new(el,row)
79
+ end
80
+ end
81
+
82
+ attr_reader :row
83
+ attr_reader :el
84
+ def initialize(el,row)
85
+ @el = el
86
+ @isapp = el.is_a?( UIC::Application )
87
+ @row = row
88
+ end
89
+ def child_count
90
+ (@isapp ? @el.presentations : @el.children).length
91
+ end
92
+
93
+ def child(offset)
94
+ kids = @isapp ? @el.presentations : @el.children
95
+ self.class[ @isapp ? kids[offset].scene : kids[offset], offset ] if kids[offset]
96
+ end
97
+
98
+ def parent
99
+ unless @el.is_a?( UIC::Application )
100
+ self.class[@el.parent || @el.presentation.app, @row]
101
+ end
102
+ end
103
+
104
+ def icon
105
+ @icon ||= UIC::GUI::IconVariant[@el.type]
106
+ end
107
+
108
+ def displayName
109
+ @el.type=='Scene' ? @el.path : @el.name
110
+ end
111
+ def displayType
112
+ @el.type
113
+ end
114
+ end
115
+
116
+ module UIC::GUI::IconVariant
117
+ @by_path = {}
118
+ def self.[]( alias_or_path )
119
+ @by_path[alias_or_path] ||= begin
120
+ icon = Qt::Pixmap.new(alias_or_path)
121
+ icon = Qt::Pixmap.new(":/#{alias_or_path}") if icon.isNull
122
+ icon = Qt::Pixmap.new(":/Unknown") if icon.isNull
123
+ Qt::Variant.fromValue(icon)
124
+ end
125
+ end
126
+ end
@@ -0,0 +1,20 @@
1
+ #encoding: utf-8
2
+ require 'Qt'
3
+ require_relative 'window'
4
+
5
+ class Qt::Application
6
+ def self.translate(*a,&b)
7
+ method_missing(:translate,*a,&b).force_encoding('utf-8')
8
+ end
9
+ end
10
+
11
+ Qt::CoreApplication.organization_name = "PhrogzSoft"
12
+ Qt::CoreApplication.organization_domain = "phrogz.net"
13
+ Qt::CoreApplication.application_name = "RUIC"
14
+ $prefs = Qt::Settings.new
15
+
16
+ $app = Qt::Application.new(ARGV)
17
+ gui = UIC::GUI.new
18
+ gui.show
19
+ gui.open
20
+ $app.exec
@@ -0,0 +1,14 @@
1
+ all: window_ui.rb window_qrc.rb
2
+
3
+ window_ui.rb: window.ui
4
+ rbuic4 window.ui -o window_ui.rb
5
+
6
+ window_qrc.rb: resources.qrc
7
+ rbrcc -name resources resources.qrc -o window_qrc.rb
8
+
9
+ clean:
10
+ rm -f window_ui.rb
11
+ rm -f window_qrc.rb
12
+
13
+ run: all
14
+ ruby launch.rb
@@ -0,0 +1,37 @@
1
+ <RCC>
2
+ <qresource prefix="/">
3
+ <file alias="Effect">resources/images/Objects-Effect-Normal.png</file>
4
+ <file alias="Unknown">resources/images/Objects-Unknown-Normal.png</file>
5
+ <file alias="Behavior">resources/images/Objects-Behavior-Normal.png</file>
6
+ <file alias="Camera">resources/images/Objects-Camera-Normal.png</file>
7
+ <file alias="Component">resources/images/Objects-Component-Normal.png</file>
8
+ <file alias="Group">resources/images/Objects-Group-Normal.png</file>
9
+ <file alias="Image">resources/images/Objects-Image-Normal.png</file>
10
+ <file alias="Layer">resources/images/Objects-Layer-Normal.png</file>
11
+ <file alias="Light">resources/images/Objects-Light-Normal.png</file>
12
+ <file alias="Material">resources/images/Objects-Material-Normal.png</file>
13
+ <file alias="CustomMaterial">resources/images/Objects-Material-Normal.png</file>
14
+ <file alias="Model">resources/images/Objects-Model-Normal.png</file>
15
+ <file alias="Text">resources/images/Objects-Text-Normal.png</file>
16
+ <file alias="Scene">resources/images/Objects-Scene-Normal.png</file>
17
+ <file>resources/style/dark.qss</file>
18
+ <file>resources/style/checkbox.png</file>
19
+ <file>resources/style/down_arrow.png</file>
20
+ <file>resources/images/textfile_icon.png</file>
21
+ <file>resources/images/studio_architect32.png</file>
22
+ <file alias="copy">resources/images/clipboard.png</file>
23
+ <file>resources/images/cross.png</file>
24
+ <file>resources/images/disk-black.png</file>
25
+ <file>resources/images/disks-black.png</file>
26
+ <file>resources/images/document-copy.png</file>
27
+ <file>resources/images/document--plus.png</file>
28
+ <file>resources/images/folder-horizontal-open.png</file>
29
+ <file alias="cut">resources/images/scissors-blue.png</file>
30
+ <file>resources/images/gear.png</file>
31
+ <file>resources/images/executable-actions-delete-active.png</file>
32
+ <file>resources/images/executable-actions-delete-idle.png</file>
33
+ <file>resources/images/executable-actions-enter-badge.png</file>
34
+ <file>resources/images/executable-actions-exit-badge.png</file>
35
+ <file>resources/images/folder-horizontal--plus.png</file>
36
+ </qresource>
37
+ </RCC>
@@ -0,0 +1,459 @@
1
+ QToolTip
2
+ {
3
+ border: 1px solid black;
4
+ background-color: #ffa02f;
5
+ padding: 1px;
6
+ border-radius: 3px;
7
+ opacity: 100;
8
+ }
9
+
10
+ QWidget
11
+ {
12
+ color: #b1b1b1;
13
+ background-color: #323232;
14
+ }
15
+
16
+ QWidget:item:hover
17
+ {
18
+ background-color: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #ffa02f, stop: 1 #ca0619);
19
+ color: #000000;
20
+ }
21
+
22
+ QWidget:item:selected
23
+ {
24
+ background-color: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #ffa02f, stop: 1 #d7801a);
25
+ }
26
+
27
+ QMenuBar::item
28
+ {
29
+ background: transparent;
30
+ }
31
+
32
+ QMenuBar::item:selected
33
+ {
34
+ background: transparent;
35
+ border: 1px solid #ffaa00;
36
+ }
37
+
38
+ QMenuBar::item:pressed
39
+ {
40
+ background: #444;
41
+ border: 1px solid #000;
42
+ background-color: QLinearGradient(
43
+ x1:0, y1:0,
44
+ x2:0, y2:1,
45
+ stop:1 #212121,
46
+ stop:0.4 #343434/*,
47
+ stop:0.2 #343434,
48
+ stop:0.1 #ffaa00*/
49
+ );
50
+ margin-bottom:-1px;
51
+ padding-bottom:1px;
52
+ }
53
+
54
+ QMenu
55
+ {
56
+ border: 1px solid #000;
57
+ }
58
+
59
+ QMenu::item
60
+ {
61
+ padding: 2px 20px 2px 20px;
62
+ }
63
+
64
+ QMenu::item:selected
65
+ {
66
+ color: #000000;
67
+ }
68
+
69
+ QWidget:disabled
70
+ {
71
+ color: #404040;
72
+ background-color: #323232;
73
+ }
74
+
75
+ QAbstractItemView
76
+ {
77
+ background-color: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #4d4d4d, stop: 0.1 #646464, stop: 1 #5d5d5d);
78
+ }
79
+
80
+ QWidget:focus
81
+ {
82
+ /*border: 2px solid QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #ffa02f, stop: 1 #d7801a);*/
83
+ }
84
+
85
+ QLineEdit
86
+ {
87
+ background-color: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #4d4d4d, stop: 0 #646464, stop: 1 #5d5d5d);
88
+ padding: 1px;
89
+ border-style: solid;
90
+ border: 1px solid #1e1e1e;
91
+ border-radius: 5;
92
+ }
93
+
94
+ QPushButton
95
+ {
96
+ color: #b1b1b1;
97
+ background-color: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #565656, stop: 0.1 #525252, stop: 0.5 #4e4e4e, stop: 0.9 #4a4a4a, stop: 1 #464646);
98
+ border-width: 1px;
99
+ border-color: #1e1e1e;
100
+ border-style: solid;
101
+ border-radius: 6;
102
+ padding: 3px;
103
+ font-size: 12px;
104
+ padding-left: 5px;
105
+ padding-right: 5px;
106
+ }
107
+
108
+ QPushButton:pressed
109
+ {
110
+ background-color: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #2d2d2d, stop: 0.1 #2b2b2b, stop: 0.5 #292929, stop: 0.9 #282828, stop: 1 #252525);
111
+ }
112
+
113
+ QComboBox
114
+ {
115
+ selection-background-color: #ffaa00;
116
+ background-color: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #565656, stop: 0.1 #525252, stop: 0.5 #4e4e4e, stop: 0.9 #4a4a4a, stop: 1 #464646);
117
+ border-style: solid;
118
+ border: 1px solid #1e1e1e;
119
+ border-radius: 5;
120
+ }
121
+
122
+ QComboBox:hover,QPushButton:hover
123
+ {
124
+ border: 2px solid QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #ffa02f, stop: 1 #d7801a);
125
+ }
126
+
127
+
128
+ QComboBox:on
129
+ {
130
+ padding-top: 3px;
131
+ padding-left: 4px;
132
+ background-color: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #2d2d2d, stop: 0.1 #2b2b2b, stop: 0.5 #292929, stop: 0.9 #282828, stop: 1 #252525);
133
+ selection-background-color: #ffaa00;
134
+ }
135
+
136
+ QComboBox QAbstractItemView
137
+ {
138
+ border: 2px solid darkgray;
139
+ selection-background-color: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #ffa02f, stop: 1 #d7801a);
140
+ }
141
+
142
+ QComboBox::drop-down
143
+ {
144
+ subcontrol-origin: padding;
145
+ subcontrol-position: top right;
146
+ width: 15px;
147
+
148
+ border-left-width: 0px;
149
+ border-left-color: darkgray;
150
+ border-left-style: solid; /* just a single line */
151
+ border-top-right-radius: 3px; /* same radius as the QComboBox */
152
+ border-bottom-right-radius: 3px;
153
+ }
154
+
155
+ QComboBox::down-arrow
156
+ {
157
+ image: url(:/resources/style/down_arrow.png);
158
+ }
159
+
160
+ QGroupBox:focus
161
+ {
162
+ border: 2px solid QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #ffa02f, stop: 1 #d7801a);
163
+ }
164
+
165
+ QTextEdit:focus
166
+ {
167
+ border: 2px solid QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #ffa02f, stop: 1 #d7801a);
168
+ }
169
+
170
+ QScrollBar:horizontal {
171
+ border: 1px solid #222222;
172
+ background: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0.0 #121212, stop: 0.2 #282828, stop: 1 #484848);
173
+ height: 7px;
174
+ margin: 0px 16px 0 16px;
175
+ }
176
+
177
+ QScrollBar::handle:horizontal
178
+ {
179
+ background: QLinearGradient( x1: 0, y1: 0, x2: 1, y2: 0, stop: 0 #ffa02f, stop: 0.5 #d7801a, stop: 1 #ffa02f);
180
+ min-height: 20px;
181
+ border-radius: 2px;
182
+ }
183
+
184
+ QScrollBar::add-line:horizontal {
185
+ border: 1px solid #1b1b19;
186
+ border-radius: 2px;
187
+ background: QLinearGradient( x1: 0, y1: 0, x2: 1, y2: 0, stop: 0 #ffa02f, stop: 1 #d7801a);
188
+ width: 14px;
189
+ subcontrol-position: right;
190
+ subcontrol-origin: margin;
191
+ }
192
+
193
+ QScrollBar::sub-line:horizontal {
194
+ border: 1px solid #1b1b19;
195
+ border-radius: 2px;
196
+ background: QLinearGradient( x1: 0, y1: 0, x2: 1, y2: 0, stop: 0 #ffa02f, stop: 1 #d7801a);
197
+ width: 14px;
198
+ subcontrol-position: left;
199
+ subcontrol-origin: margin;
200
+ }
201
+
202
+ QScrollBar::right-arrow:horizontal, QScrollBar::left-arrow:horizontal
203
+ {
204
+ border: 1px solid black;
205
+ width: 1px;
206
+ height: 1px;
207
+ background: white;
208
+ }
209
+
210
+ QScrollBar::add-page:horizontal, QScrollBar::sub-page:horizontal
211
+ {
212
+ background: none;
213
+ }
214
+
215
+ QScrollBar:vertical
216
+ {
217
+ background: QLinearGradient( x1: 0, y1: 0, x2: 1, y2: 0, stop: 0.0 #121212, stop: 0.2 #282828, stop: 1 #484848);
218
+ width: 7px;
219
+ margin: 16px 0 16px 0;
220
+ border: 1px solid #222222;
221
+ }
222
+
223
+ QScrollBar::handle:vertical
224
+ {
225
+ background: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #ffa02f, stop: 0.5 #d7801a, stop: 1 #ffa02f);
226
+ min-height: 20px;
227
+ border-radius: 2px;
228
+ }
229
+
230
+ QScrollBar::add-line:vertical
231
+ {
232
+ border: 1px solid #1b1b19;
233
+ border-radius: 2px;
234
+ background: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #ffa02f, stop: 1 #d7801a);
235
+ height: 14px;
236
+ subcontrol-position: bottom;
237
+ subcontrol-origin: margin;
238
+ }
239
+
240
+ QScrollBar::sub-line:vertical
241
+ {
242
+ border: 1px solid #1b1b19;
243
+ border-radius: 2px;
244
+ background: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #d7801a, stop: 1 #ffa02f);
245
+ height: 14px;
246
+ subcontrol-position: top;
247
+ subcontrol-origin: margin;
248
+ }
249
+
250
+ QScrollBar::up-arrow:vertical, QScrollBar::down-arrow:vertical
251
+ {
252
+ border: 1px solid black;
253
+ width: 1px;
254
+ height: 1px;
255
+ background: white;
256
+ }
257
+
258
+
259
+ QScrollBar::add-page:vertical, QScrollBar::sub-page:vertical
260
+ {
261
+ background: none;
262
+ }
263
+
264
+ QTextEdit
265
+ {
266
+ background-color: #242424;
267
+ }
268
+
269
+ QPlainTextEdit
270
+ {
271
+ background-color: #242424;
272
+ }
273
+
274
+ QHeaderView::section
275
+ {
276
+ background-color: QLinearGradient(x1:0, y1:0, x2:0, y2:1, stop:0 #616161, stop: 0.5 #505050, stop: 0.6 #434343, stop:1 #656565);
277
+ color: white;
278
+ padding-left: 4px;
279
+ border: 1px solid #6c6c6c;
280
+ }
281
+
282
+ QCheckBox:disabled
283
+ {
284
+ color: #414141;
285
+ }
286
+
287
+ QDockWidget::title
288
+ {
289
+ padding-left: 10px;
290
+ spacing: 3px; /* spacing between items in the tool bar */
291
+ background-color: QLinearGradient(x1:0, y1:0, x2:0, y2:1, stop:0 #323232, stop: 0.5 #242424, stop:1 #323232);
292
+ }
293
+
294
+ QDockWidget::close-button, QDockWidget::float-button
295
+ {
296
+ text-align: center;
297
+ spacing: 1px; /* spacing between items in the tool bar */
298
+ background-color: QLinearGradient(x1:0, y1:0, x2:0, y2:1, stop:0 #323232, stop: 0.5 #242424, stop:1 #323232);
299
+ }
300
+
301
+ QDockWidget::close-button:hover, QDockWidget::float-button:hover
302
+ {
303
+ background: #242424;
304
+ }
305
+
306
+ QDockWidget::close-button:pressed, QDockWidget::float-button:pressed
307
+ {
308
+ padding: 1px -1px -1px 1px;
309
+ }
310
+
311
+ QMainWindow::separator
312
+ {
313
+ background-color: QLinearGradient(x1:0, y1:0, x2:0, y2:1, stop:0 #161616, stop: 0.5 #151515, stop: 0.6 #212121, stop:1 #343434);
314
+ color: white;
315
+ padding-left: 4px;
316
+ border: 1px solid #4c4c4c;
317
+ spacing: 3px; /* spacing between items in the tool bar */
318
+ }
319
+
320
+ QMainWindow::separator:hover
321
+ {
322
+
323
+ background-color: QLinearGradient(x1:0, y1:0, x2:0, y2:1, stop:0 #d7801a, stop:0.5 #b56c17 stop:1 #ffa02f);
324
+ color: white;
325
+ padding-left: 4px;
326
+ border: 1px solid #6c6c6c;
327
+ spacing: 3px; /* spacing between items in the tool bar */
328
+ }
329
+
330
+ QToolBar::handle
331
+ {
332
+ spacing: 3px; /* spacing between items in the tool bar */
333
+ background: url(:/resources/style/handle.png);
334
+ }
335
+
336
+ QMenu::separator
337
+ {
338
+ height: 2px;
339
+ background-color: QLinearGradient(x1:0, y1:0, x2:0, y2:1, stop:0 #161616, stop: 0.5 #151515, stop: 0.6 #212121, stop:1 #343434);
340
+ color: white;
341
+ padding-left: 4px;
342
+ margin-left: 10px;
343
+ margin-right: 5px;
344
+ }
345
+
346
+ QProgressBar
347
+ {
348
+ border: 2px solid grey;
349
+ border-radius: 5px;
350
+ text-align: center;
351
+ }
352
+
353
+ QProgressBar::chunk
354
+ {
355
+ background-color: #d7801a;
356
+ width: 2.15px;
357
+ margin: 0.5px;
358
+ }
359
+
360
+ QTabBar::tab {
361
+ color: #b1b1b1;
362
+ border: 1px solid #444;
363
+ border-bottom-style: none;
364
+ background-color: #323232;
365
+ padding-left: 10px;
366
+ padding-right: 10px;
367
+ padding-top: 3px;
368
+ padding-bottom: 2px;
369
+ margin-right: -1px;
370
+ }
371
+
372
+ QTabWidget::pane {
373
+ border: 1px solid #444;
374
+ top: 1px;
375
+ }
376
+
377
+ QTabBar::tab:last
378
+ {
379
+ margin-right: 0; /* the last selected tab has nothing to overlap with on the right */
380
+ border-top-right-radius: 3px;
381
+ }
382
+
383
+ QTabBar::tab:first:!selected
384
+ {
385
+ margin-left: 0px; /* the last selected tab has nothing to overlap with on the right */
386
+
387
+
388
+ border-top-left-radius: 3px;
389
+ }
390
+
391
+ QTabBar::tab:!selected
392
+ {
393
+ color: #b1b1b1;
394
+ border-bottom-style: solid;
395
+ margin-top: 3px;
396
+ background-color: QLinearGradient(x1:0, y1:0, x2:0, y2:1, stop:1 #212121, stop:.4 #343434);
397
+ }
398
+
399
+ QTabBar::tab:selected
400
+ {
401
+ border-top-left-radius: 3px;
402
+ border-top-right-radius: 3px;
403
+ margin-bottom: 0px;
404
+ }
405
+
406
+ QTabBar::tab:!selected:hover
407
+ {
408
+ /*border-top: 2px solid #ffaa00;
409
+ padding-bottom: 3px;*/
410
+ border-top-left-radius: 3px;
411
+ border-top-right-radius: 3px;
412
+ background-color: QLinearGradient(x1:0, y1:0, x2:0, y2:1, stop:1 #212121, stop:0.4 #343434, stop:0.2 #343434, stop:0.1 #ffaa00);
413
+ }
414
+
415
+ QRadioButton::indicator:checked, QRadioButton::indicator:unchecked{
416
+ color: #b1b1b1;
417
+ background-color: #323232;
418
+ border: 1px solid #b1b1b1;
419
+ border-radius: 6px;
420
+ }
421
+
422
+ QRadioButton::indicator:checked
423
+ {
424
+ background-color: qradialgradient(
425
+ cx: 0.5, cy: 0.5,
426
+ fx: 0.5, fy: 0.5,
427
+ radius: 1.0,
428
+ stop: 0.25 #ffaa00,
429
+ stop: 0.3 #323232
430
+ );
431
+ }
432
+
433
+ QCheckBox::indicator{
434
+ color: #b1b1b1;
435
+ background-color: #323232;
436
+ border: 1px solid #b1b1b1;
437
+ width: 9px;
438
+ height: 9px;
439
+ }
440
+
441
+ QRadioButton::indicator
442
+ {
443
+ border-radius: 6px;
444
+ }
445
+
446
+ QRadioButton::indicator:hover, QCheckBox::indicator:hover
447
+ {
448
+ border: 1px solid #ffaa00;
449
+ }
450
+
451
+ QCheckBox::indicator:checked
452
+ {
453
+ image:url(:/resources/style/checkbox.png);
454
+ }
455
+
456
+ QCheckBox::indicator:disabled, QRadioButton::indicator:disabled
457
+ {
458
+ border: 1px solid #444;
459
+ }