Groupbox.height read/write property
Get or set the height of the Groupbox area. The height starts from 0 (top side of the Groupbox) and increase to the bottom direction.
Example
local ui = require "ui"
-- create a simple Window
local win = ui.Window("Groupbox.height sample", 320, 200)
local groupbox = ui.Groupbox(win, "Resize my height !", 10, 50, 300, 140)
local inc_btn = ui.Button(win, "Increase Groupbox.height !", 15, 10)
local dec_btn = ui.Button(win, "Decrease Groupbox.height", inc_btn.x+150, inc_btn.y)
ui.Button(groupbox, "Child Button", 110, 50)
function inc_btn:onClick()
local delta
if self == inc_btn then
delta = 10
else
delta = -10
end
groupbox.height = groupbox.height + delta
end
dec_btn.onClick = inc_btn.onClick
-- shows the Window
win:show()
-- update user interface
repeat
ui.update()
until not win.visible