Here is an example that shows it working:
-- Get the displays
local displays = GetDisplays()
-- Create window
local window = CreateWindow("Ultra Engine", 0, 0, 800, 600, displays[1], WINDOW_TITLEBAR | WINDOW_RESIZABLE)
window:SetMinSize(640, 480)
-- Create user interface
local ui = CreateInterface(window)
-- Create widgets
local sz = ui.background:ClientSize()
local leftpanel = CreatePanel(10, 10, 200, sz.y - 20, ui.background)
leftpanel:SetLayout(1, 0, 1, 1)
leftpanel:SetColor(0, 0, 0, 1)
local rightpanel = CreatePanel(sz.x - 10 - 200, 10, 200, sz.y - 20, ui.background)
rightpanel:SetLayout(0, 1, 1, 1)
rightpanel:SetColor(0, 0, 0, 1)
local mainpanel = CreatePanel(10 + 200 + 10, 10, sz.x - 10 * 4 - 200 * 2, sz.y - 10 * 3 - 100, ui.background)
mainpanel:SetLayout(1, 1, 1, 1)
mainpanel:SetColor(0, 0, 0, 1)
local bottompanel = CreatePanel(10 + 200 + 10, sz.y - 10 - 100, sz.x - 10 * 4 - 200 * 2, 100, ui.background)
bottompanel:SetLayout(1, 1, 0, 1)
bottompanel:SetColor(0, 0, 0, 1)
while true do
local ev = WaitEvent()
if ev.id == EVENT_KEYDOWN and ev.data == KEY_SPACE then
ui:SetScale(1.25)
end
if ev.id == EVENT_WINDOWCLOSE and ev.source == window then
break
end
end