Panel:onResize()event


This event is fired when the Panel has been resized.

Return value

The event returns no value.

Example

--! luart-extensions import ui -- create a fixed Window local win = ui.Window("Panel:onResize() event sample", "fixed", 320, 200) -- create a Panel local panel = ui.Panel(win, 0, 0, 100, 100) panel.bgcolor = 0xF0A000 panel:center() ui.Button(panel, "To the left", 5, 36).onClick = function() panel.align = "left" end function panel:onResize() win:status("Panel size is "..self.width.." x "..self.height) end panel:onResize() await win:showasync()