Window - siffiejoe/lua-fltk4lua GitHub Wiki
Window:
Corresponds to:
Fl_Window
Constructors
fl.Window( int X, int Y, int W, int H, *str label ) ==> userdata Widgetfl.Window( int W, int H, *str label ) ==> userdata Widgetwindow manager positions window
fl.Window{ table entries } ==> userdata Widget( table constructor syntax )
Functions
- methods defined for the
Groupuserdata type - methods defined for the
Widgetuserdata type obj:clear_border()turn window manager border off
only works before show() is calledobj:cursor( str cursor, *int|userdata hotX, *int|userdata hotY )same cursor options as
obj:default_cursor(), below
optional hotX and hotY coords, pixel point that actually clicks on-screenobj:default_cursor( str cursor, *int|userdata hotx, *int|userdata hoty )"FL_CURSOR_DEFAULT""FL_CURSOR_ARROW""FL_CURSOR_CROSS""FL_CURSOR_WAIT""FL_CURSOR_INSERT""FL_CURSOR_HAND""FL_CURSOR_HELP""FL_CURSOR_MOVE""FL_CURSOR_NS""FL_CURSOR_WE""FL_CURSOR_NWSE""FL_CURSOR_NESW""FL_CURSOR_N""FL_CURSOR_NE""FL_CURSOR_E""FL_CURSOR_SE""FL_CURSOR_S""FL_CURSOR_SW""FL_CURSOR_W""FL_CURSOR_NW""FL_CURSOR_NONE"
obj:fullscreen()no border
obj:fullscreen_off()obj:fullscreen_off( int X, int Y, int W, int H )specifies resize
obj:iconize()call show() to restore window
obj:make_current()so that you can add extra widgets to specified obj window
obj:set_modal()remain on top, only obj window that receives events
obj:set_non_modal()on top, but other windows still receive events
obj:set_override()activates flags NOBORDER|FL_OVERRIDE
obj:show( *table )puts window on screen, optional commandline arguments
obj:size_range( int minW, int minH, *int maxW, int maxH, *incW, int incH, bool aspect )smallest, and optional largest, window can be.
incW and incH are increments. set aspect to preserve aspect ratio
Properties
- properties defined for the
Groupuserdata type - properties defined for the
Widgetuserdata type obj.label ==> str labelgetobj.label = str labelsetobj.modal ==> bool own_eventsgetobj.modal = bool own_eventssetobj.shown ==> bool onscreengetobj.border ==> bool onscreengetobj.x_root ==> int left_corner_of_windowgetobj.y_root ==> int top_corner_of_windowgetobj.xclass ==> str window_classgetobj.xclass = str window_classsetobj.override ==> bool FL_OVERRIDEgetobj.iconlabel ==> str labelgetobj.iconlabel = str labelsetobj.non_modal ==> bool if_modal_or_nonmodalgetobj.decorated_h ==> int height_of_window_including_bordergetobj.decorated_w ==> int width_of_window_including_bordergetobj.menu_window ==> bool if_window_is_menugetobj.tooltip_window ==> bool if_window_is_tooltipgetobj.fullscreen_active ==> bool if_window_is_fullscreengetobj.xid int|userdata xidgetXID of window, 0 if not shown