uEZ GUI Start Here Guide
UEZGUI-1788-43WQR
Rev. 1.11 Aug 31, 2016
Page 13
2.
Replace the definitions with the names and values associated with the new button
being created:
/*---------------------------------------------------------------------------*
* Constants:
*--------------------------------------------------------------------------*/
#define
ID_WINDOW (GUI_I 0x00)
#define
ID_TITLE_TEXT (GUI_I 0x01)
#define
ID_MYBUTTON_BUTTON (GUI_I 0x02)
#define
ID_FDIINFO_TEXT (GUI_I 0x03)
#define
WINDOW_XSIZE (UEZ_LCD_DISPLAY_WIDTH)
#define
WINDOW_YSIZE (UEZ_LCD_DISPLAY_HEIGHT)
#define
WINDOW_XPOS (0)
#define
WINDOW_YPOS (0)
#if
(UEZ_DEFAULT_LCD == LCD_RES_WVGA)
#define
SPACING (10)
#define
FONTSIZE &FONT_LARGE
#else
#define
SPACING (5)
#define
FONTSIZE &FONT_SMALL
#endif
#define
TITLE_TEXT_XSIZE (WINDOW_XSIZE)
#define
TITLE_TEXT_YSIZE ((WINDOW_YSIZE/10))
#define
TITLE_TEXT_XPOS (0)
#define
TITLE_TEXT_YPOS (0)
#define
FDIINFO_TEXT_XSIZE (WINDOW_XSIZE)
#define
FDIINFO_TEXT_YSIZE ((WINDOW_YSIZE/10))
#define
FDIINFO_TEXT_XPOS (0)
#define
FDIINFO_TEXT_YPOS ((WINDOW_YSIZE/10)*9 + 0)
#define
MYBUTTON_BUTTON_XSIZE (WINDOW_XSIZE/3 + 20)
#define
MYBUTTON_BUTTON_YSIZE ((WINDOW_YSIZE/5))
#define
MYBUTTON_BUTTON_XPOS (WINDOW_XSIZE/3 - 10)
#define
MYBUTTON_BUTTON_YPOS ((WINDOW_YSIZE/10)*4)