mirror of
https://github.com/edubart/otclient.git
synced 2025-10-15 20:14:54 +02:00
Refactor modules, closes #223
* All modules are sandboxed now * All images,sounds,fonts,translations and styles were moved to "data" folder * Reorganize image files folders * Remove unmaintained modules: client_particles, client_shaders * Implement new automatic way to load styles and fonts * Add hide/show offline option in VipList * Add invite/exclude to/from private channel in players menus * Many other minor changes
This commit is contained in:
69
data/styles/10-buttons.otui
Normal file
69
data/styles/10-buttons.otui
Normal file
@@ -0,0 +1,69 @@
|
||||
Button < UIButton
|
||||
font: verdana-11px-antialised
|
||||
color: #f0ad4dff
|
||||
size: 106 22
|
||||
text-offset: 0 0
|
||||
image-source: /images/ui/button_rounded
|
||||
image-color: white
|
||||
image-clip: 0 0 20 20
|
||||
image-border: 2
|
||||
padding: 5 10 5 10
|
||||
|
||||
$hover !disabled:
|
||||
image-clip: 0 20 20 20
|
||||
|
||||
$pressed:
|
||||
image-clip: 0 40 20 20
|
||||
text-offset: 1 1
|
||||
|
||||
$disabled:
|
||||
color: #f0ad4d88
|
||||
|
||||
TabButton < UIButton
|
||||
size: 20 20
|
||||
image-source: /images/ui/tabbutton_rounded
|
||||
image-color: white
|
||||
image-clip: 0 0 20 20
|
||||
image-border: 2
|
||||
icon-color: white
|
||||
color: #aaaaaa
|
||||
|
||||
$hover !on:
|
||||
image-clip: 0 20 20 20
|
||||
color: white
|
||||
|
||||
$disabled:
|
||||
image-color: #ffffff66
|
||||
icon-color: #888888
|
||||
|
||||
$on:
|
||||
image-clip: 0 40 20 20
|
||||
color: #80c7f8
|
||||
|
||||
NextButton < UIButton
|
||||
size: 12 21
|
||||
image-source: /images/ui/arrow_horizontal
|
||||
image-clip: 12 0 12 21
|
||||
|
||||
$hover !disabled:
|
||||
image-clip: 12 21 12 21
|
||||
|
||||
$pressed:
|
||||
image-clip: 12 21 12 21
|
||||
|
||||
$disabled:
|
||||
image-color: #ffffff55
|
||||
|
||||
PreviousButton < UIButton
|
||||
size: 12 21
|
||||
image-source: /images/ui/arrow_horizontal
|
||||
image-clip: 0 0 12 21
|
||||
|
||||
$hover !disabled:
|
||||
image-clip: 0 21 12 21
|
||||
|
||||
$pressed:
|
||||
image-clip: 0 21 12 21
|
||||
|
||||
$disabled:
|
||||
image-color: #ffffff55
|
66
data/styles/10-checkboxes.otui
Normal file
66
data/styles/10-checkboxes.otui
Normal file
@@ -0,0 +1,66 @@
|
||||
CheckBox < UICheckBox
|
||||
size: 16 16
|
||||
text-align: left
|
||||
text: aa
|
||||
text-offset: 16 0
|
||||
color: #aaaaaa
|
||||
image-color: #ffffffff
|
||||
image-rect: 0 0 12 12
|
||||
image-offset: 0 2
|
||||
image-source: /images/ui/checkbox
|
||||
|
||||
$hover !disabled:
|
||||
color: #cccccc
|
||||
|
||||
$!checked:
|
||||
image-clip: 0 0 12 12
|
||||
|
||||
$hover !checked:
|
||||
image-clip: 0 12 12 12
|
||||
|
||||
$checked:
|
||||
image-clip: 0 24 12 12
|
||||
|
||||
$hover checked:
|
||||
image-clip: 0 36 12 12
|
||||
|
||||
$disabled:
|
||||
image-color: #ffffff88
|
||||
color: #aaaaaa88
|
||||
|
||||
ColorBox < UICheckBox
|
||||
size: 16 16
|
||||
image-color: #ffffffff
|
||||
image-source: /images/ui/colorbox
|
||||
|
||||
$checked:
|
||||
image-clip: 16 0 16 16
|
||||
|
||||
$!checked:
|
||||
image-clip: 0 0 16 16
|
||||
|
||||
ButtonBox < UICheckBox
|
||||
font: verdana-11px-antialised
|
||||
color: #ffffffff
|
||||
size: 106 22
|
||||
text-offset: 0 0
|
||||
text-align: center
|
||||
image-source: /images/ui/tabbutton_rounded
|
||||
image-color: white
|
||||
image-clip: 0 0 20 20
|
||||
image-border: 2
|
||||
|
||||
$hover !disabled:
|
||||
image-clip: 0 20 20 20
|
||||
|
||||
$checked:
|
||||
image-clip: 0 40 20 20
|
||||
color: #80c7f8
|
||||
|
||||
$disabled:
|
||||
color: #666666ff
|
||||
image-color: #ffffff88
|
||||
|
||||
ButtonBoxRounded < ButtonBox
|
||||
image-source: /images/ui/tabbutton_rounded
|
||||
image-border: 2
|
62
data/styles/10-comboboxes.otui
Normal file
62
data/styles/10-comboboxes.otui
Normal file
@@ -0,0 +1,62 @@
|
||||
ComboBoxPopupMenuButton < UIButton
|
||||
height: 20
|
||||
font: verdana-11px-antialised
|
||||
text-align: left
|
||||
text-offset: 4 0
|
||||
color: #aaaaaa
|
||||
background-color: alpha
|
||||
|
||||
$hover !disabled:
|
||||
color: #ffffff
|
||||
background-color: #ffffff44
|
||||
|
||||
$disabled:
|
||||
color: #555555
|
||||
|
||||
ComboBoxPopupMenu < UIPopupMenu
|
||||
image-source: /images/ui/combobox_square
|
||||
image-clip: 0 60 89 20
|
||||
image-border-left: 1
|
||||
image-border-right: 1
|
||||
|
||||
ComboBox < UIComboBox
|
||||
font: verdana-11px-antialised
|
||||
color: #aaaaaa
|
||||
size: 89 20
|
||||
text-offset: 3 0
|
||||
text-align: left
|
||||
image-source: /images/ui/combobox_square
|
||||
image-border: 1
|
||||
image-border-right: 17
|
||||
image-clip: 0 0 89 20
|
||||
|
||||
$hover !disabled:
|
||||
image-clip: 0 20 89 20
|
||||
|
||||
$on:
|
||||
image-clip: 0 40 89 20
|
||||
|
||||
ComboBoxRoundedPopupMenuButton < UIButton
|
||||
height: 20
|
||||
font: verdana-11px-antialised
|
||||
text-align: left
|
||||
text-offset: 4 0
|
||||
color: #aaaaaa
|
||||
background-color: alpha
|
||||
|
||||
$hover !disabled:
|
||||
color: #ffffff
|
||||
background-color: #ffffff44
|
||||
|
||||
$disabled:
|
||||
color: #555555
|
||||
|
||||
ComboBoxRoundedPopupMenu < UIPopupMenu
|
||||
image-source: /images/ui/combobox_rounded
|
||||
image-clip: 0 60 89 20
|
||||
image-border-left: 1
|
||||
image-border-right: 1
|
||||
|
||||
ComboBoxRounded < ComboBox
|
||||
image-source: /images/ui/combobox_rounded
|
||||
image-border: 2
|
48
data/styles/10-creaturebuttons.otui
Normal file
48
data/styles/10-creaturebuttons.otui
Normal file
@@ -0,0 +1,48 @@
|
||||
CreatureButton < UICreatureButton
|
||||
height: 20
|
||||
margin-bottom: 5
|
||||
|
||||
UICreature
|
||||
id: creature
|
||||
size: 20 20
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
phantom: true
|
||||
|
||||
UIWidget
|
||||
id: spacer
|
||||
width: 5
|
||||
anchors.left: creature.right
|
||||
anchors.top: creature.top
|
||||
phantom: true
|
||||
|
||||
UIWidget
|
||||
id: skull
|
||||
height: 11
|
||||
anchors.left: spacer.right
|
||||
anchors.top: spacer.top
|
||||
phantom: true
|
||||
|
||||
UIWidget
|
||||
id: emblem
|
||||
height: 11
|
||||
anchors.left: skull.right
|
||||
anchors.top: creature.top
|
||||
phantom: true
|
||||
|
||||
Label
|
||||
id: label
|
||||
anchors.left: emblem.right
|
||||
anchors.top: creature.top
|
||||
color: #888888
|
||||
margin-left: 2
|
||||
phantom: true
|
||||
|
||||
ProgressBar
|
||||
id: lifeBar
|
||||
height: 5
|
||||
anchors.left: spacer.right
|
||||
anchors.right: parent.right
|
||||
anchors.top: label.bottom
|
||||
margin-top: 2
|
||||
phantom: true
|
10
data/styles/10-creatures.otui
Normal file
10
data/styles/10-creatures.otui
Normal file
@@ -0,0 +1,10 @@
|
||||
Creature < UICreature
|
||||
size: 80 80
|
||||
padding: 1
|
||||
image-source: /images/ui/panel_flat
|
||||
image-border: 1
|
||||
border-width: 1
|
||||
border-color: alpha
|
||||
|
||||
$checked:
|
||||
border-color: white
|
6
data/styles/10-items.otui
Normal file
6
data/styles/10-items.otui
Normal file
@@ -0,0 +1,6 @@
|
||||
Item < UIItem
|
||||
size: 34 34
|
||||
padding: 1
|
||||
image-source: /images/ui/item
|
||||
font: verdana-11px-rounded
|
||||
border-color: white
|
65
data/styles/10-labels.otui
Normal file
65
data/styles/10-labels.otui
Normal file
@@ -0,0 +1,65 @@
|
||||
Label < UILabel
|
||||
font: verdana-11px-antialised
|
||||
color: #bbbbbb
|
||||
|
||||
$disabled:
|
||||
color: #bbbbbb88
|
||||
|
||||
FlatLabel < UILabel
|
||||
font: verdana-11px-antialised
|
||||
color: #aaaaaa
|
||||
size: 86 20
|
||||
text-offset: 3 3
|
||||
image-source: /images/ui/panel_flat
|
||||
image-border: 1
|
||||
|
||||
$disabled:
|
||||
color: #aaaaaa88
|
||||
|
||||
MenuLabel < Label
|
||||
|
||||
GameLabel < UILabel
|
||||
font: verdana-11px-antialised
|
||||
color: #bbbbbb
|
||||
|
||||
FrameCounterLabel < Label
|
||||
font: verdana-11px-rounded
|
||||
@onSetup: |
|
||||
self.updateEvent = cycleEvent(function()
|
||||
local text = 'FPS: ' .. g_app.getBackgroundPaneFps()
|
||||
self:setText(text)
|
||||
end, 1000)
|
||||
@onDestroy: self.updateEvent:cancel()
|
||||
|
||||
PingLabel < Label
|
||||
font: verdana-11px-rounded
|
||||
@onSetup: |
|
||||
self.updateEvent = cycleEvent(function()
|
||||
if g_game.isOnline() and modules.client_options.getOption('showPing') then
|
||||
local ping = -1
|
||||
if g_game.getFeature(GameClientPing) or g_game.getFeature(GameExtendedClientPing) then
|
||||
ping = g_game.getPing()
|
||||
else
|
||||
ping = g_game.getLocalPlayer():getWalkPing()
|
||||
end
|
||||
local text = 'Ping: '
|
||||
if ping < 0 then
|
||||
text = text .. "??"
|
||||
self:setColor('yellow')
|
||||
else
|
||||
text = text .. ping .. ' ms'
|
||||
if ping >= 500 then
|
||||
self:setColor('red')
|
||||
elseif ping >= 250 then
|
||||
self:setColor('yellow')
|
||||
else
|
||||
self:setColor('green')
|
||||
end
|
||||
end
|
||||
self:setText(text)
|
||||
self:show()
|
||||
else
|
||||
self:hide()
|
||||
end
|
||||
end, 1000)
|
||||
@onDestroy: self.updateEvent:cancel()
|
12
data/styles/10-listboxes.otui
Normal file
12
data/styles/10-listboxes.otui
Normal file
@@ -0,0 +1,12 @@
|
||||
TextList < UIScrollArea
|
||||
layout: verticalBox
|
||||
border-width: 1
|
||||
border-color: #1d222b
|
||||
background-color: #222833
|
||||
padding: 1
|
||||
|
||||
HorizontalList < UIScrollArea
|
||||
layout: horizontalBox
|
||||
border-width: 1
|
||||
border-color: #1d222b
|
||||
background-color: #222833
|
21
data/styles/10-panels.otui
Normal file
21
data/styles/10-panels.otui
Normal file
@@ -0,0 +1,21 @@
|
||||
Panel < UIWidget
|
||||
phantom: true
|
||||
|
||||
ScrollablePanel < UIScrollArea
|
||||
phantom: true
|
||||
|
||||
FlatPanel < Panel
|
||||
image-source: /images/ui/panel_flat
|
||||
image-border: 1
|
||||
|
||||
ScrollableFlatPanel < ScrollablePanel
|
||||
image-source: /images/ui/panel_flat
|
||||
image-border: 1
|
||||
|
||||
ParticlesFlatPanel < Panel
|
||||
image-source: /images/ui/panel_flat
|
||||
image-border: 1
|
||||
|
||||
LightFlatPanel < Panel
|
||||
image-source: /images/ui/panel_lightflat
|
||||
image-border: 1
|
13
data/styles/10-progressbars.otui
Normal file
13
data/styles/10-progressbars.otui
Normal file
@@ -0,0 +1,13 @@
|
||||
ProgressBar < UIProgressBar
|
||||
height: 16
|
||||
background-color: red
|
||||
border: 1 black
|
||||
image-source: /images/ui/progressbar
|
||||
image-border: 1
|
||||
|
||||
ProgressRect < UIProgressRect
|
||||
anchors.fill: parent
|
||||
phantom: true
|
||||
color: white
|
||||
background-color: #00000088
|
||||
font: verdana-11px-rounded
|
99
data/styles/10-scrollbars.otui
Normal file
99
data/styles/10-scrollbars.otui
Normal file
@@ -0,0 +1,99 @@
|
||||
ScrollBarSlider < UIButton
|
||||
id: sliderButton
|
||||
anchors.centerIn: parent
|
||||
size: 13 17
|
||||
image-source: /images/ui/scrollbar
|
||||
image-clip: 0 26 13 13
|
||||
image-border: 2
|
||||
image-color: #ffffffbb
|
||||
$hover:
|
||||
image-clip: 13 26 13 13
|
||||
$pressed:
|
||||
image-clip: 26 26 13 13
|
||||
image-color: #ffffff99
|
||||
$disabled:
|
||||
image-color: #ffffff66
|
||||
|
||||
VerticalScrollBar < UIScrollBar
|
||||
orientation: vertical
|
||||
width: 13
|
||||
height: 39
|
||||
image-source: /images/ui/scrollbar
|
||||
image-clip: 39 0 13 65
|
||||
image-border: 1
|
||||
pixels-scroll: true
|
||||
|
||||
UIButton
|
||||
id: decrementButton
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
image-source: /images/ui/scrollbar
|
||||
image-clip: 0 0 13 13
|
||||
image-color: #ffffffff
|
||||
size: 13 13
|
||||
$hover:
|
||||
image-clip: 13 0 13 13
|
||||
$pressed:
|
||||
image-clip: 26 0 13 13
|
||||
$disabled:
|
||||
image-color: #ffffff66
|
||||
|
||||
UIButton
|
||||
id: incrementButton
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
size: 13 13
|
||||
image-source: /images/ui/scrollbar
|
||||
image-clip: 0 13 13 13
|
||||
image-color: #ffffffff
|
||||
$hover:
|
||||
image-clip: 13 13 13 13
|
||||
$pressed:
|
||||
image-clip: 26 13 13 13
|
||||
$disabled:
|
||||
image-color: #ffffff66
|
||||
|
||||
ScrollBarSlider
|
||||
|
||||
HorizontalScrollBar < UIScrollBar
|
||||
orientation: horizontal
|
||||
height: 13
|
||||
width: 39
|
||||
image-source: /images/ui/scrollbar
|
||||
image-clip: 0 65 52 13
|
||||
image-border: 1
|
||||
|
||||
$disabled:
|
||||
color: #bbbbbb88
|
||||
|
||||
UIButton
|
||||
id: decrementButton
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
image-source: /images/ui/scrollbar
|
||||
image-clip: 0 39 13 13
|
||||
image-color: #ffffffff
|
||||
size: 13 13
|
||||
$hover:
|
||||
image-clip: 13 39 13 13
|
||||
$pressed:
|
||||
image-clip: 26 39 13 13
|
||||
$disabled:
|
||||
image-color: #ffffff66
|
||||
|
||||
UIButton
|
||||
id: incrementButton
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
size: 13 13
|
||||
image-source: /images/ui/scrollbar
|
||||
image-clip: 0 52 13 13
|
||||
image-color: #ffffffff
|
||||
$hover:
|
||||
image-clip: 13 52 13 13
|
||||
$pressed:
|
||||
image-clip: 26 52 13 13
|
||||
$disabled:
|
||||
image-color: #ffffff66
|
||||
|
||||
ScrollBarSlider
|
13
data/styles/10-separators.otui
Normal file
13
data/styles/10-separators.otui
Normal file
@@ -0,0 +1,13 @@
|
||||
HorizontalSeparator < UIWidget
|
||||
image-source: /images/ui/separator_horizontal
|
||||
image-border-top: 2
|
||||
height: 2
|
||||
phantom: true
|
||||
focusable: false
|
||||
|
||||
VerticalSeparator < UIWidget
|
||||
image-source: /images/ui/separator_vertical
|
||||
image-border-left: 2
|
||||
width: 2
|
||||
phantom: true
|
||||
focusable: false
|
9
data/styles/10-splitters.otui
Normal file
9
data/styles/10-splitters.otui
Normal file
@@ -0,0 +1,9 @@
|
||||
Splitter < UISplitter
|
||||
size: 4 4
|
||||
opacity: 0
|
||||
background: #ffffff44
|
||||
|
||||
ResizeBorder < UIResizeBorder
|
||||
size: 4 4
|
||||
opacity: 0
|
||||
background: #ffffff44
|
17
data/styles/10-textedits.otui
Normal file
17
data/styles/10-textedits.otui
Normal file
@@ -0,0 +1,17 @@
|
||||
TextEdit < UITextEdit
|
||||
font: verdana-11px-antialised
|
||||
color: #aaaaaa
|
||||
size: 86 20
|
||||
text-offset: 0 3
|
||||
padding: 3
|
||||
image-source: /images/ui/textedit
|
||||
image-border: 1
|
||||
|
||||
$disabled:
|
||||
color: #aaaaaa88
|
||||
|
||||
PasswordTextEdit < TextEdit
|
||||
text-hidden: true
|
||||
|
||||
MultilineTextEdit < TextEdit
|
||||
multiline: true
|
29
data/styles/10-windows.otui
Normal file
29
data/styles/10-windows.otui
Normal file
@@ -0,0 +1,29 @@
|
||||
Window < UIWindow
|
||||
font: verdana-11px-antialised
|
||||
size: 200 200
|
||||
opacity: 1
|
||||
color: white
|
||||
text-offset: 0 4
|
||||
text-align: top
|
||||
image-source: /images/ui/window
|
||||
image-border: 5
|
||||
image-border-top: 22
|
||||
opacity: 1
|
||||
padding-top: 30
|
||||
padding-left: 16
|
||||
padding-right: 16
|
||||
padding-bottom: 16
|
||||
|
||||
$disabled:
|
||||
color: #aaaaaa88
|
||||
|
||||
$dragging:
|
||||
opacity: 0.8
|
||||
|
||||
HeadlessWindow < UIWindow
|
||||
image-source: /images/ui/window_headless
|
||||
image-border: 5
|
||||
padding: 5
|
||||
|
||||
MainWindow < Window
|
||||
anchors.centerIn: parent
|
43
data/styles/20-popupmenus.otui
Normal file
43
data/styles/20-popupmenus.otui
Normal file
@@ -0,0 +1,43 @@
|
||||
PopupMenuButton < UIButton
|
||||
height: 18
|
||||
margin-left: 5
|
||||
margin-right: 5
|
||||
margin-top: 1
|
||||
margin-bottom: 1
|
||||
size: 0 21
|
||||
text-offset: 0 0
|
||||
font: verdana-11px-antialised
|
||||
|
||||
image-source: /images/ui/button_popupmenu
|
||||
image-color: white
|
||||
image-clip: 0 0 20 20
|
||||
image-border: 2
|
||||
|
||||
color: #aaaaaa
|
||||
background-color: alpha
|
||||
|
||||
$hover !disabled:
|
||||
color: #ffffff
|
||||
background-color: #ffffff44
|
||||
image-clip: 0 40 20 20
|
||||
|
||||
$disabled:
|
||||
color: #555555
|
||||
|
||||
PopupMenuSeparator < UIWidget
|
||||
margin-left: 2
|
||||
margin-right: 2
|
||||
margin-bottom: 1
|
||||
image-source: /images/ui/menubox
|
||||
image-border-left: 1
|
||||
image-border-right: 1
|
||||
image-clip: 0 0 32 2
|
||||
height: 2
|
||||
phantom: true
|
||||
|
||||
PopupMenu < UIPopupMenu
|
||||
width: 50
|
||||
image-source: /images/ui/menubox
|
||||
image-border: 3
|
||||
padding-top: 3
|
||||
padding-bottom: 3
|
33
data/styles/20-spinboxes.otui
Normal file
33
data/styles/20-spinboxes.otui
Normal file
@@ -0,0 +1,33 @@
|
||||
SpinBox < TextEdit
|
||||
__class: UISpinBox
|
||||
size: 86 20
|
||||
|
||||
Button
|
||||
id: up
|
||||
size: 10 10
|
||||
image-source: /images/ui/spinbox_up
|
||||
image-border: 1
|
||||
image-clip: 0 0 10 10
|
||||
anchors.top: parent.top
|
||||
anchors.right: parent.right
|
||||
@onClick: self:getParent():up()
|
||||
|
||||
$hover:
|
||||
image-clip: 0 10 10 10
|
||||
$pressed:
|
||||
image-clip: 0 20 10 10
|
||||
|
||||
Button
|
||||
id: down
|
||||
size: 10 10
|
||||
image-source: /images/ui/spinbox_down
|
||||
image-border: 1
|
||||
image-clip: 0 0 10 10
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
@onClick: self:getParent():down()
|
||||
|
||||
$hover:
|
||||
image-clip: 0 10 10 10
|
||||
$pressed:
|
||||
image-clip: 0 20 10 10
|
89
data/styles/20-tabbars.otui
Normal file
89
data/styles/20-tabbars.otui
Normal file
@@ -0,0 +1,89 @@
|
||||
TabBar < UITabBar
|
||||
size: 80 20
|
||||
TabBarPanel < Panel
|
||||
TabBarButton < UIButton
|
||||
size: 20 20
|
||||
image-source: /images/ui/tabbutton_square
|
||||
image-color: white
|
||||
image-clip: 0 0 20 20
|
||||
image-border: 2
|
||||
icon-color: white
|
||||
color: #aaaaaa
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
padding: 5
|
||||
|
||||
$hover !checked:
|
||||
image-clip: 0 20 20 20
|
||||
color: white
|
||||
|
||||
$disabled:
|
||||
image-color: #ffffff66
|
||||
icon-color: #888888
|
||||
|
||||
$checked:
|
||||
image-clip: 0 40 20 20
|
||||
color: #D8E7F0
|
||||
|
||||
$on !checked:
|
||||
color: #F55E5E
|
||||
|
||||
TabBarRounded < TabBar
|
||||
TabBarRoundedPanel < TabBarPanel
|
||||
TabBarRoundedButton < TabBarButton
|
||||
image-source: /images/ui/tabbutton_rounded
|
||||
|
||||
TabBarVertical < UITabBar
|
||||
width: 96
|
||||
|
||||
ScrollableFlatPanel
|
||||
id: buttonsPanel
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
anchors.right: scrollBar.left
|
||||
anchors.bottom: parent.bottom
|
||||
vertical-scrollbar: scrollBar
|
||||
|
||||
VerticalScrollBar
|
||||
id: scrollBar
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
step: 16
|
||||
pixels-scroll: true
|
||||
|
||||
$!on:
|
||||
width: 0
|
||||
|
||||
TabBarVerticalPanel < Panel
|
||||
|
||||
TabBarVerticalButton < UIButton
|
||||
size: 48 48
|
||||
color: #aaaaaa
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
text-align: bottom
|
||||
icon-align: top
|
||||
icon-offset-y: 2
|
||||
icon-color: #888888
|
||||
|
||||
$first:
|
||||
anchors.top: parent.top
|
||||
|
||||
$!first:
|
||||
anchors.top: prev.bottom
|
||||
margin-top: 5
|
||||
|
||||
$hover !checked:
|
||||
color: white
|
||||
icon-color: #cccccc
|
||||
|
||||
$disabled:
|
||||
icon-color: #333333
|
||||
|
||||
$checked:
|
||||
icon-color: #ffffff
|
||||
color: #80c7f8
|
||||
|
||||
$on !checked:
|
||||
color: #F55E5E
|
26
data/styles/20-tables.otui
Normal file
26
data/styles/20-tables.otui
Normal file
@@ -0,0 +1,26 @@
|
||||
Table < UITable
|
||||
layout: verticalBox
|
||||
header-column-style: HeaderTableColumn
|
||||
header-row-style: HeaderTableRow
|
||||
column-style: TableColumn
|
||||
row-style: TableRow
|
||||
|
||||
TableData < UIScrollArea
|
||||
layout: verticalBox
|
||||
|
||||
TableRow < Label
|
||||
layout: horizontalBox
|
||||
height: 10
|
||||
text-wrap: true
|
||||
|
||||
TableColumn < Label
|
||||
width: 30
|
||||
text-wrap: true
|
||||
|
||||
TableHeaderRow < Label
|
||||
layout: horizontalBox
|
||||
height: 10
|
||||
text-wrap: true
|
||||
|
||||
TableHeaderColumn < Button
|
||||
width: 30
|
49
data/styles/20-topmenu.otui
Normal file
49
data/styles/20-topmenu.otui
Normal file
@@ -0,0 +1,49 @@
|
||||
TopButton < UIButton
|
||||
size: 26 26
|
||||
image-source: /images/ui/button_top
|
||||
image-clip: 0 0 26 26
|
||||
image-border: 3
|
||||
image-color: #ffffffff
|
||||
icon-color: #ffffffff
|
||||
|
||||
$hover !disabled:
|
||||
image-color: #ffffff99
|
||||
image-clip: 26 0 26 26
|
||||
|
||||
$pressed:
|
||||
image-clip: 52 0 26 26
|
||||
|
||||
$disabled:
|
||||
image-color: #ffffff44
|
||||
icon-color: #ffffff44
|
||||
|
||||
TopToggleButton < UIButton
|
||||
size: 26 26
|
||||
image-source: /images/ui/button_topgame
|
||||
image-clip: 26 0 26 26
|
||||
image-color: #ffffffff
|
||||
image-border: 3
|
||||
icon-color: #ffffffff
|
||||
|
||||
$on:
|
||||
image-clip: 0 0 26 26
|
||||
image-color: #ffffffff
|
||||
icon-color: #ffffffff
|
||||
|
||||
TopMenuButtonsPanel < Panel
|
||||
layout:
|
||||
type: horizontalBox
|
||||
spacing: 4
|
||||
fit-children: true
|
||||
padding: 6 4
|
||||
|
||||
TopMenuPanel < Panel
|
||||
height: 36
|
||||
image-source: /images/ui/panel_top
|
||||
image-repeated: true
|
||||
focusable: false
|
||||
|
||||
TopMenuFrameCounterLabel < FrameCounterLabel
|
||||
color: white
|
||||
margin-top: 4
|
||||
margin-left: 5
|
30
data/styles/30-inputboxes.otui
Normal file
30
data/styles/30-inputboxes.otui
Normal file
@@ -0,0 +1,30 @@
|
||||
InputBoxLabel < Label
|
||||
fixed-size: true
|
||||
text-align: left
|
||||
InputBoxLineEdit < TextEdit
|
||||
InputBoxTextEdit < MultilineTextEdit
|
||||
text-wrap: true
|
||||
InputBoxSpinBox < SpinBox
|
||||
InputBoxCheckBox < CheckBox
|
||||
InputBoxComboBox < ComboBox
|
||||
InputBoxComboBoxPopupMenu < ComboBoxPopupMenu
|
||||
InputBoxComboBoxPopupMenuButton < ComboBoxPopupMenuButton
|
||||
InputBoxButton < Button
|
||||
margin-left: 10
|
||||
fixed-size: true
|
||||
|
||||
InputBoxButtonsPanel < Panel
|
||||
height: 20
|
||||
margin-top: 4
|
||||
focusable: false
|
||||
layout:
|
||||
type: horizontalBox
|
||||
align-right: true
|
||||
|
||||
InputBoxWindow < MainWindow
|
||||
__class: UIInputBox
|
||||
width: 260
|
||||
layout:
|
||||
type: verticalBox
|
||||
fit-children: true
|
||||
spacing: 2
|
14
data/styles/30-messageboxes.otui
Normal file
14
data/styles/30-messageboxes.otui
Normal file
@@ -0,0 +1,14 @@
|
||||
MessageBoxLabel < Label
|
||||
id: messageBoxLabel
|
||||
text-auto-resize: true
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
anchors.top: parent.top
|
||||
|
||||
MessageBoxButtonHolder < UIWidget
|
||||
id: buttonHolder
|
||||
margin-top: 10
|
||||
anchors.bottom: parent.bottom
|
||||
|
||||
MessageBoxButton < Button
|
||||
margin-left: 10
|
||||
width: 80
|
106
data/styles/30-miniwindow.otui
Normal file
106
data/styles/30-miniwindow.otui
Normal file
@@ -0,0 +1,106 @@
|
||||
MiniWindow < UIMiniWindow
|
||||
font: verdana-11px-antialised
|
||||
icon-rect: 4 4 16 16
|
||||
width: 192
|
||||
height: 200
|
||||
text-offset: 24 5
|
||||
text-align: topLeft
|
||||
image-source: /images/ui/miniwindow
|
||||
image-border: 4
|
||||
image-border-top: 23
|
||||
image-border-bottom: 4
|
||||
focusable: false
|
||||
&minimizedHeight: 24
|
||||
|
||||
$on:
|
||||
image-border-bottom: 2
|
||||
|
||||
UIWidget
|
||||
id: miniwindowTopBar
|
||||
anchors.top: parent.top
|
||||
anchors.right: parent.right
|
||||
anchors.left: parent.left
|
||||
margin-right: 3
|
||||
margin-left: 3
|
||||
margin-top: 3
|
||||
size: 258 18
|
||||
phantom: true
|
||||
|
||||
UIButton
|
||||
id: closeButton
|
||||
anchors.top: parent.top
|
||||
anchors.right: parent.right
|
||||
margin-top: 5
|
||||
margin-right: 5
|
||||
size: 14 14
|
||||
image-source: /images/ui/miniwindow_buttons
|
||||
image-clip: 28 0 14 14
|
||||
|
||||
$hover:
|
||||
image-clip: 28 14 14 14
|
||||
|
||||
$pressed:
|
||||
image-clip: 28 28 14 14
|
||||
|
||||
UIButton
|
||||
id: minimizeButton
|
||||
anchors.top: closeButton.top
|
||||
anchors.right: closeButton.left
|
||||
margin-right: 3
|
||||
size: 14 14
|
||||
image-source: /images/ui/miniwindow_buttons
|
||||
image-clip: 0 0 14 14
|
||||
|
||||
$hover:
|
||||
image-clip: 0 14 14 14
|
||||
|
||||
$pressed:
|
||||
image-clip: 0 28 14 14
|
||||
|
||||
$on:
|
||||
image-clip: 14 0 14 14
|
||||
|
||||
$on hover:
|
||||
image-clip: 14 14 14 14
|
||||
|
||||
$on pressed:
|
||||
image-clip: 14 28 14 14
|
||||
|
||||
VerticalScrollBar
|
||||
id: miniwindowScrollBar
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
step: 14
|
||||
margin-top: 22
|
||||
margin-right: 3
|
||||
margin-bottom: 3
|
||||
pixels-scroll: true
|
||||
|
||||
$!on:
|
||||
width: 0
|
||||
|
||||
ResizeBorder
|
||||
id: bottomResizeBorder
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: 3
|
||||
minimum: 48
|
||||
margin-left: 3
|
||||
margin-right: 3
|
||||
background: #ffffff88
|
||||
|
||||
MiniWindowContents < ScrollablePanel
|
||||
id: contentsPanel
|
||||
anchors.fill: parent
|
||||
anchors.right: miniwindowScrollBar.left
|
||||
margin-left: 3
|
||||
margin-bottom: 3
|
||||
margin-top: 22
|
||||
margin-right: 1
|
||||
vertical-scrollbar: miniwindowScrollBar
|
||||
|
||||
BorderlessGameWindow < UIWindow
|
||||
focusable: false
|
||||
margin: 2
|
Reference in New Issue
Block a user