Window

Methods
1
Fields
None

Methods

MethodReturnsDescription
viewport(string, string, number, number, (Panel) -> ())booleanOpen a separate OS window and draw into it.

Method details

viewport

viewport: (Window, string, string, number, number, (Panel) -> ()) -> boolean

Open a separate OS window and draw into it.

Its body may open another; the nesting runs on the native stack, so keep it shallow.

id
Identity between frames; must be unique in this plugin.
title
Window title.
width
Initial width in points.
height
Initial height in points.
body
Called immediately, with the window's own ui.
Returns
true on the pass the window's close button was pressed: if win:viewport(...) then open = false end.