add get_colors function
This commit is contained in:
@@ -25,9 +25,8 @@ For most network scripts `on_alarm()` should be used.
|
||||
* `ui:show_toast(string)` - shows informational message in Android style;
|
||||
* `ui:get_default_title()` - returns the standard widget title (set in the `name` metadata);
|
||||
* `ui:set_title()` - changes the title of the widget, should be called before the data display function (empty line - reset to the standard title);
|
||||
* `ui:get_primary_text_color()` - returns the color of the theme text in #XXXXXX format;
|
||||
* `ui:get_secondary_text_color()` - returns the secondary text color (usually gray) in #XXXXXX format;
|
||||
* `ui:set_folding_flag(boolean)` - sets or clears the flag of the folded mode of the widget, the function should be called before the data display functions;
|
||||
* `ui:get_colors()` - returns table with current theme colors;
|
||||
|
||||
When you click on any element of the interface, the `on_click(number)` callback will be executed, where number is the ordinal number of the element. A long click calls `on_long_click(number)`. For example, if you use `ui:show_buttons` to show three buttons, then clicking the first button will call `on_click` with argument 1, the second with arguments 2, and so on. If there is only one element on the screen, the argument will always be equal to one and can be omitted.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user