Samir
when you change object position inside groupbox and then change groupbox position it will fix
local ui = require "ui"
local win = ui.Window("test", 600, 600)
win.bgcolor = 0x58e0d3
local testgbox1 = ui.Groupbox(win,"broken")
local testlabel1 = ui.Label(testgbox1,"sda")
testlabel1.bgcolor = 0xfff
function testlabel1:onClick()
testlabel1.y = math.random(0,testgbox1.height-testlabel1.height)
testlabel1.x = math.random(0,testgbox1.width-testlabel1.width)
end
local testgbox2 = ui.Groupbox(win,"broken"); testgbox2.x = 300
local testlabel2 = ui.Label(testgbox2,"sda")
function testlabel2:onClick()
testlabel2.y = testlabel2.y + 10
end
local testgbox3 = ui.Groupbox(win,"fixed"); testgbox3.y = 300
local testlabel3 = ui.Label(testgbox3,"sda")
testlabel3.bgcolor = 0xfff
function testlabel3:onClick()
testlabel3.y = math.random(0,testgbox3.height-testlabel3.height)
testlabel3.x = math.random(0,testgbox3.width-testlabel3.width)
testgbox3.x = testgbox3.x + 1
testgbox3.x = testgbox3.x - 1
end
local testgbox4 = ui.Groupbox(win,"fixed"); testgbox4.x = 300; testgbox4.y = 300
local testlabel4 = ui.Label(testgbox4,"sda")
function testlabel4:onClick()
testlabel4.y = testlabel4.y + 10
testgbox4.x = testgbox4.x + 1
testgbox4.x = testgbox4.x - 1
end
win:show()
repeat
ui.update()
until not win.visible