Class Layout

Layout class.

Functions

Luigi.Layout (data) Layout constructor.

Methods

Layout:setStyle (rules) Set the style from a definition table or function.
Layout:setTheme (rules) Set the theme from a definition table or function.
Layout:show () Show the layout.
Layout:hide () Hide the layout.
Layout:focusNextWidget () Focus next focusable widget.
Layout:focusPreviousWidget () Focus previous focusable widget.
Layout:getWidgetAt (x, y[, root]) Get the innermost widget at given coordinates.


Functions

Methods
Luigi.Layout (data)
Layout constructor.

Parameters:

  • data table A tree of widget data.

Returns:

    Layout A Layout instance.

Methods

Layout:setStyle (rules)
Set the style from a definition table or function.

Parameters:

  • rules table or function Style definition.
Layout:setTheme (rules)
Set the theme from a definition table or function.

Parameters:

  • rules table or function Theme definition.
Layout:show ()
Show the layout.

Hooks all appropriate Love events and callbacks.

Layout:hide ()
Hide the layout.

Unhooks Love events and callbacks.

Layout:focusNextWidget ()
Focus next focusable widget.

Traverses widgets using Widget:getNextNeighbor until a focusable widget is found, and focuses that widget.

Returns:

    Widget The widget that was focused, or nil
Layout:focusPreviousWidget ()
Focus previous focusable widget.

Traverses widgets using Widget:getPreviousNeighbor until a focusable widget is found, and focuses that widget.

Returns:

    Widget The widget that was focused, or nil
Layout:getWidgetAt (x, y[, root])
Get the innermost widget at given coordinates.

Parameters:

  • x number Number of pixels from window's left edge.
  • y number Number of pixels from window's top edge.
  • root Widget Widget to search within, defaults to layout root. (optional)
generated by LDoc 1.4.3 Last updated 2015-11-04 15:07:53