Go to the source code of this file.
|
#define | GSLC_TYPEX_SLIDER |
|
#define | gslc_ElemXSliderCreate_P(pGui, nElemId, nPage, nX, nY, nW, nH, nPosMin_, nPosMax_, nPos_, nThumbSz_, bVert_, colFrame_, colFill_) |
| Create a Slider Element in Flash. More...
|
|
|
gslc_tsElemRef * | gslc_ElemXSliderCreate (gslc_tsGui *pGui, int16_t nElemId, int16_t nPage, gslc_tsXSlider *pXData, gslc_tsRect rElem, int16_t nPosMin, int16_t nPosMax, int16_t nPos, uint16_t nThumbSz, bool bVert) |
| Create a Slider Element. More...
|
|
void | gslc_ElemXSliderSetStyle (gslc_tsGui *pGui, gslc_tsElemRef *pElemRef, bool bTrim, gslc_tsColor colTrim, uint16_t nTickDiv, int16_t nTickLen, gslc_tsColor colTick) |
| Set a Slider element's current position. More...
|
|
void | gslc_ElemXSliderSetSnapEn (gslc_tsGui *pGui, gslc_tsElemRef *pElemRef, bool bSnapEn) |
| Enable touch to snap to the nearest tick mark. More...
|
|
int | gslc_ElemXSliderGetPos (gslc_tsGui *pGui, gslc_tsElemRef *pElemRef) |
| Get a Slider element's current position. More...
|
|
void | gslc_ElemXSliderSetPos (gslc_tsGui *pGui, gslc_tsElemRef *pElemRef, int16_t nPos) |
| Set a Slider element's current position. More...
|
|
void | gslc_ElemXSliderSetPosFunc (gslc_tsGui *pGui, gslc_tsElemRef *pElemRef, GSLC_CB_XSLIDER_POS funcCb) |
| Assign the position callback function for a slider. More...
|
|
bool | gslc_ElemXSliderDraw (void *pvGui, void *pvElemRef, gslc_teRedrawType eRedraw) |
| Draw a Slider element on the screen. More...
|
|
bool | gslc_ElemXSliderTouch (void *pvGui, void *pvElemRef, gslc_teTouch eTouch, int16_t nRelX, int16_t nRelY) |
| Handle touch events to Slider element. More...
|
|
#define gslc_ElemXSliderCreate_P |
( |
|
pGui, |
|
|
|
nElemId, |
|
|
|
nPage, |
|
|
|
nX, |
|
|
|
nY, |
|
|
|
nW, |
|
|
|
nH, |
|
|
|
nPosMin_, |
|
|
|
nPosMax_, |
|
|
|
nPos_, |
|
|
|
nThumbSz_, |
|
|
|
bVert_, |
|
|
|
colFrame_, |
|
|
|
colFill_ |
|
) |
| |
Create a Slider Element in Flash.
- Parameters
-
[in] | pGui | Pointer to GUI |
[in] | nElemId | Unique element ID to assign |
[in] | nPage | Page ID to attach element to |
[in] | nX | X coordinate of element |
[in] | nY | Y coordinate of element |
[in] | nW | Width of element |
[in] | nH | Height of element |
[in] | nPosMin_ | Minimum position value |
[in] | nPosMax_ | Maximum position value |
[in] | nPos_ | Starting position value |
[in] | nThumbSz_ | Size of the thumb control |
[in] | bVert_ | Orientation (true for vertical) |
[in] | colFrame_ | Color of the element frame |
[in] | colFill_ | Color of the element fill |
- Returns
- none
#define GSLC_TYPEX_SLIDER |
typedef bool(* GSLC_CB_XSLIDER_POS) (void *pvGui, void *pvElem, int16_t nPos) |
Callback function for slider feedback.
Create a Slider Element.
- Parameters
-
[in] | pGui | Pointer to GUI |
[in] | nElemId | Element ID to assign (0..16383 or GSLC_ID_AUTO to autogen) |
[in] | nPage | Page ID to attach element to |
[in] | pXData | Ptr to extended element data structure |
[in] | rElem | Rectangle coordinates defining checkbox size |
[in] | nPosMin | Minimum position value |
[in] | nPosMax | Maximum position value |
[in] | nPos | Starting position value |
[in] | nThumbSz | Size of the thumb control |
[in] | bVert | Orientation (true for vertical) |
- Returns
- Pointer to Element reference or NULL if failure
bool gslc_ElemXSliderDraw |
( |
void * |
pvGui, |
|
|
void * |
pvElemRef, |
|
|
gslc_teRedrawType |
eRedraw |
|
) |
| |
Draw a Slider element on the screen.
- Parameters
-
[in] | pvGui | Void ptr to GUI (typecast to gslc_tsGui*) |
[in] | pvElemRef | Void ptr to Element reference (typecast to gslc_tsElemRef*) |
[in] | eRedraw | Redraw mode |
- Returns
- true if success, false otherwise
Get a Slider element's current position.
- Parameters
-
[in] | pGui | Pointer to GUI |
[in] | pElemRef | Pointer to Element reference |
- Returns
- Current slider position
Set a Slider element's current position.
- Parameters
-
[in] | pGui | Pointer to GUI |
[in] | pGui | Pointer to GUI |
[in] | pElemRef | Pointer to Element reference |
[in] | nPos | New position value |
- Returns
- none
Assign the position callback function for a slider.
- Parameters
-
[in] | pGui | Pointer to GUI |
[in] | pElemRef | Pointer to Element reference |
[in] | funcCb | Function pointer to position routine (or NULL for none) |
- Returns
- none
Enable touch to snap to the nearest tick mark.
- nTickDiv (in SetStyle) must be non-zero for snap to be active
- Parameters
-
[in] | pGui | Pointer to GUI |
[in] | pElemRef | Pointer to Element reference |
[in] | bSnapEn | Enable snap function if true |
- Returns
- none
Set a Slider element's current position.
- Parameters
-
[in] | pGui | Pointer to GUI |
[in] | pElemRef | Pointer to Element reference |
[in] | bTrim | Show a colored trim? |
[in] | colTrim | Color of trim |
[in] | nTickDiv | Number of tick divisions to show (0 for none) |
[in] | nTickLen | Length of tickmarks |
[in] | colTick | Color of ticks |
- Returns
- none
bool gslc_ElemXSliderTouch |
( |
void * |
pvGui, |
|
|
void * |
pvElemRef, |
|
|
gslc_teTouch |
eTouch, |
|
|
int16_t |
nRelX, |
|
|
int16_t |
nRelY |
|
) |
| |
Handle touch events to Slider element.
- Parameters
-
[in] | pvGui | Void ptr to GUI (typecast to gslc_tsGui*) |
[in] | pvElemRef | Void ptr to Element reference (typecast to gslc_tsElemRef*) |
[in] | eTouch | Touch event type |
[in] | nRelX | Touch X coord relative to element |
[in] | nRelY | Touch Y coord relative to element |
- Returns
- true if success, false otherwise