GUIslice  0.16.0
Embedded GUI in C
XTemplate.h File Reference
#include "GUIslice.h"
Include dependency graph for XTemplate.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  gslc_tsXTemplate
 Callback function for slider feedback. More...
 

Macros

#define GSLC_TYPEX_TEMPLATE
 

Functions

gslc_tsElemRefgslc_ElemXTemplateCreate (gslc_tsGui *pGui, int16_t nElemId, int16_t nPage, gslc_tsXTemplate *pXData, gslc_tsRect rElem, char *pStrBuf, uint8_t nStrBufMax, int16_t nFontId)
 Create an Extended Text Field Element. More...
 
bool gslc_ElemXTemplateDraw (void *pvGui, void *pvElemRef, gslc_teRedrawType eRedraw)
 Draw the template element on the screen. More...
 
bool gslc_ElemXTemplateTouch (void *pvGui, void *pvElemRef, gslc_teTouch eTouch, int16_t nRelX, int16_t nRelY)
 Handle touch events to template element. More...
 

Macro Definition Documentation

#define GSLC_TYPEX_TEMPLATE

Function Documentation

gslc_tsElemRef* gslc_ElemXTemplateCreate ( gslc_tsGui pGui,
int16_t  nElemId,
int16_t  nPage,
gslc_tsXTemplate pXData,
gslc_tsRect  rElem,
char *  pStrBuf,
uint8_t  nStrBufMax,
int16_t  nFontId 
)

Create an Extended Text Field Element.

Parameters
[in]pGuiPointer to GUI
[in]nElemIdElement ID to assign (0..16383 or GSLC_ID_AUTO to autogen)
[in]nPagePage ID to attach element to
[in]pXDataPtr to extended element data structure
[in]rElemRectangle coordinates defining element size
[in]pStrBufPtr to string buffer
[in]nStrBufMaxMaximum buffer alength allocated to pStrBuf
[in]nFontIdID of font to use for text output
Returns
Pointer to Element reference or NULL if failure
bool gslc_ElemXTemplateDraw ( void *  pvGui,
void *  pvElemRef,
gslc_teRedrawType  eRedraw 
)

Draw the template element on the screen.

Parameters
[in]pvGuiVoid ptr to GUI (typecast to gslc_tsGui*)
[in]pvElemRefVoid ptr to Element reference (typecast to gslc_tsElemRef*)
[in]eRedrawRedraw mode
Returns
true if success, false otherwise
bool gslc_ElemXTemplateTouch ( void *  pvGui,
void *  pvElemRef,
gslc_teTouch  eTouch,
int16_t  nRelX,
int16_t  nRelY 
)

Handle touch events to template element.

Parameters
[in]pvGuiVoid ptr to GUI (typecast to gslc_tsGui*)
[in]pvElemRefVoid ptr to Element reference (typecast to gslc_tsElemRef*)
[in]eTouchTouch event type
[in]nRelXTouch X coord relative to element
[in]nRelYTouch Y coord relative to element
Returns
true if success, false otherwise