Skip to content
CI edited this page Feb 27, 2022 · 2 revisions

Helpful functions for layout, widget info, and debugging.


Util.GetName(widget)

Iterates through the widget hierarchy, starting with the given widget, until a viable global name is found. This is primarily useful when the template for a widget that assumes it has a global name, when it actually doesn't due to modern naming practices.

Args:

  • widget - the widget to fine a name for (Widget)

Returns:

  • widgetName - the name of the given widget (string)

Util.GetTextureKit(textureKit)

Provides the skin colors for a given textureKit.

Args:

  • textureKit - the widget to fine a name for (string)

Returns:

  • kit - the name of the given widget (table)

    The table colors contains the following keys:

    • color - the primary kit color (ColorMixin)
    • backdrop - a backdrop color (ColorMixin)
    • title - a title text color (ColorMixin)
    • text - a regular text color (ColorMixin)
    • emblem - an atlas name (string)
Clone this wiki locally