conde2
Active Member
- Joined
- Jun 22, 2008
- Messages
- 348
- Reaction score
- 44
So my problem is that the MiniWindow is not showing the scrollbar as default (it comes as default show the scrollbar),
So I found a solution looking in anothers modules, here it is:
With this it was possible see the scroll bar, but its not scrolling
Note: I also tried that:
Someone have any idea why its not scrolling??
The .otui:
- - - Updated - - -
Solved !!
You can't use
Instead use:
and in the layout use:
So I found a solution looking in anothers modules, here it is:
PHP:
-- this disables scrollbar auto hiding
local scrollbar = spellsWindow:getChildById('miniwindowScrollBar')
scrollbar:mergeStyle({ ['$!on'] = { } })
With this it was possible see the scroll bar, but its not scrolling
Note: I also tried that:
PHP:
-- this disables scrollbar auto hiding
local scrollbar = spellsWindow:getChildById('miniwindowScrollBar')
scrollbar:mergeStyle({
['$!on'] = { },
['step'] = {20},
['pixels-scroll'] = {true}
})
Someone have any idea why its not scrolling??
The .otui:
Lua:
SpellFilterIcon < UICheckBox
size: 20 20
image-color: white
image-rect: 0 0 20 20
@onCheckChange: modules.game_spells.onSpellFilterChange()
$hover !disabled:
color: #cccccc
$!checked:
image-clip: 0 0 20 20
$hover !checked:
image-clip: 0 40 20 20
$checked:
image-clip: 0 20 20 20
$hover checked:
image-clip: 0 60 20 20
$disabled:
image-color: #ffffff88
SpellCooldownRect < UIProgressRect
background: #585858AA
percent: 100
focusable: false
ExhaustionSpellBar < ProgressBar
id: exhaustionSpellBar
background-color: #B6E866
anchors.top: prev.bottom
anchors.left: parent.left
anchors.right: miniwindowScrollBar.left
margin: 1
margin-top: 4
SpellCounter < Label
text-align: center
font: sans-bold-16px
focusable: false
SpellsButton < UIWidget
size: 40 40
image-size: 40 40
image-smooth: true
@onMouseRelease: modules.game_spells.onUseSpell(self:getId())
on: true
$!on:
image-color: #1A1A1A80
//#ffffff99
MiniWindow
id: spellsWindow
!text: tr('Spells')
height: 200
icon: /images/topbuttons/spells
@onClose: modules.game_spells.onMiniWindowClose()
&save: true
Label
margin-top: 25
margin-left: 3
anchors.top: parent.top
anchors.left: parent.left
text: Group Exhaust:
ExhaustionSpellBar
Panel
margin-top: 4
anchors.top: prev.bottom
anchors.left: parent.left
anchors.right: miniwindowScrollBar.left
height: 20
Panel
id: spellsFilters
anchors.top: parent.top
anchors.horizontalCenter: parent.horizontalCenter
height: 20
width: 120
layout:
type: horizontalBox
spacing: 5
HorizontalSeparator
anchors.top: prev.bottom
anchors.left: parent.left
anchors.right: miniwindowScrollBar.left
margin-right: 1
margin-top: 4
MiniWindowContents
anchors.top: prev.bottom
margin-top: 2
Panel
id: spellsContent
margin-top: 5
margin-left: 0
anchors.fill: parent
padding-right: 0
layout:
type: grid
cell-size: 42 42
flow: true
- - - Updated - - -
Solved !!
You can't use
Lua:
anchors.fill: parent
Instead use:
Lua:
anchors.top: parent.top
anchors.left: parent.left
anchors.right: parent.right
and in the layout use:
Lua:
fit-children: true
Last edited: