For example you have something like that:
Code:
local button = g_ui.createWidget('HotkeyButton', spellsPanel)
Then in your otui file at the beggining declare it:
Code:
HotkeyButton < UIButton
image-source: /images/ui/item
size: 34 34
font: verdana-11px-rounded
opacity: 0.7
text-align: bottomLeft
text-offset: 1 0
$hover !disabled:
opacity: 0.8
$pressed:
opacity: 1.0