Access information about the current theme.


local color = app.theme.color.color_name

The color can be used to paint in an Image or a GraphicsContext.

List of possible colors:


local value = app.theme.dimension.dimension_name

Returns a number identified in the dimensions of the theme. List of possible dimensions:


local data = app.theme:styleMetrics(style_id)
local leftBorder = data.border.left
local topBorder =
local rightBorder = data.border.right
local bottomBorder = data.border.bottom

Returns information about the given style ID (style_id must be a string). The returned information at the moment includes a border field which is a table with left/top/right/bottom border dimension in pixels (they already have app.uiScale applied).

List of possible styles: