Graphic Widget Toolkit library example application.
Copyright (c) 2012-2018 Microchip Technology Inc. and its subsidiaries.
Functions | |
int | main (void) |
main example code More... | |
static void | setup_gui_root_window (void) |
Configure the root GUI window. More... | |
static void | show_out_of_memory_error (void) |
Show an out of memory error on the display. More... | |
int main | ( | void | ) |
main example code
The main function will create the widget GUI, and display the widgets to the screen. It will then enter a message loop converting touch events from the screen into touch events for the Widget Toolkit module.
References app_widget_launch(), board_init(), gfx_init, membag_init(), setup_gui_root_window(), show_out_of_memory_error(), sysclk_init(), touch_interface_init(), touch_interface_read(), win_init(), win_process_events(), and win_queue_pointer_event().
|
static |
Configure the root GUI window.
Configures the root window background to be a tiled version of the Atmel company logo, and sets it as being visible.
References win_attributes::background, WIN_ATTR_BACKGROUND, win_get_attributes(), win_get_root(), win_root, win_set_attributes(), and win_show().
Referenced by main().
|
static |
Show an out of memory error on the display.
Shows a full screen error when called, signaling that the system ran out of memory when initializing a WTK application.
References GFX_COLOR_BLACK, GFX_COLOR_RED, GFX_COLOR_TRANSPARENT, gfx_draw_filled_rect, gfx_draw_string_aligned(), gfx_get_height(), gfx_get_width(), gfx_set_clipping(), sysfont, TEXT_ALIGN_CENTER, and TEXT_POS_CENTER.
Referenced by main().