Theme

    Category: Core

    Theme for controls.

    Properties

    Description

    Theme for skinning controls. Controls can be skinned individually, but for complex applications it’s more efficient to just create a global theme that defines everything. This theme can be applied to any , and it and its children will automatically use it.

    Theme resources can be alternatively loaded by writing them in a .theme file, see docs for more info.

    Property Descriptions

    • default_font

    The theme’s default font.

    • void clear ( )

    • void clear_color ( String name, type )

    Clears theme Color at if Theme has type.


    • void clear_constant ( name, String type )

    Clears theme constant at name if Theme has type.


    Clears at name if Theme has type.


    • void clear_icon ( String name, type )

    Clears icon at name if Theme has type.


    • void clear_stylebox ( String name, type )

    Clears StyleBox at name if Theme has type.


    • void copy_default_theme ( )

    Sets theme values to a copy of the default theme values.


    • void copy_theme ( other )

    Returns the at name if Theme has type.


    Returns all of the Colors as a filled with each Color’s name, for use in , if Theme has type.


    • int get_constant ( name, String type ) const

    • get_constant_list ( String type ) const

    Returns all of the constants as a filled with each constant’s name, for use in get_constant, if Theme has type.


    • get_font ( String name, type ) const

    Returns the Font at name if Theme has type.


    • get_font_list ( String type ) const

    Returns all of the s as a PoolStringArray filled with each ’s name, for use in get_font, if Theme has type.


    • get_icon ( String name, type ) const

    Returns the icon Texture at name if Theme has type.


    • get_icon_list ( String type ) const

    Returns all of the icons as a filled with each Texture’s name, for use in , if Theme has type.


    Returns the icon StyleBox at name if Theme has type.


    • get_stylebox_list ( String type ) const

    Returns all of the s as a PoolStringArray filled with each ’s name, for use in get_stylebox, if Theme has .


    • get_stylebox_types ( ) const

    Returns all of the StyleBox types as a filled with each StyleBox’s type, for use in and/or get_stylebox_list, if Theme has type.


    • get_type_list ( String type ) const

    Returns all of the types in type as a for use in any of the get_* functions, if Theme has type.


    Returns true if with name is in type.

    Returns false if Theme does not have type.


    Returns true if constant with name is in type.

    Returns false if Theme does not have type.


    • has_font ( String name, type ) const

    Returns false if Theme does not have type.


    Returns true if icon with name is in type.

    Returns false if Theme does not have type.


    Returns if with name is in type.

    Returns false if Theme does not have type.


    Sets Theme’s to color at name in type.

    Does nothing if Theme does not have type.


    • void set_constant ( String name, type, int constant )

    Sets Theme’s constant to constant at name in type.

    Does nothing if Theme does not have type.


    • void set_font ( name, String type, font )

    Sets Theme’s Font to font at name in type.

    Does nothing if Theme does not have type.


    • void set_icon ( name, String type, texture )

    Sets Theme’s icon Texture to texture at name in type.

    Does nothing if Theme does not have type.


    Does nothing if Theme does not have .