diff options
author | inmarket <andrewh@inmarket.com.au> | 2014-12-13 18:33:53 +1000 |
---|---|---|
committer | inmarket <andrewh@inmarket.com.au> | 2014-12-13 18:33:53 +1000 |
commit | d7896289d12652039443e1bf512d7ae521542d6f (patch) | |
tree | cbc80f0e25a9fdc1d1b1cdad8d2dbd34bbb7820e /src/gwin/sys_options.h | |
parent | ce9503a1187c8ab48bd32da24cbe95be425dd533 (diff) | |
download | uGFX-d7896289d12652039443e1bf512d7ae521542d6f.tar.gz uGFX-d7896289d12652039443e1bf512d7ae521542d6f.tar.bz2 uGFX-d7896289d12652039443e1bf512d7ae521542d6f.zip |
Updates to the slider to fix positioning issues.
Also fixes negative ranges, ranges > 65536 and very small ranges.
Diffstat (limited to 'src/gwin/sys_options.h')
-rw-r--r-- | src/gwin/sys_options.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/gwin/sys_options.h b/src/gwin/sys_options.h index 199cad5b..bb7e3598 100644 --- a/src/gwin/sys_options.h +++ b/src/gwin/sys_options.h @@ -286,6 +286,34 @@ #ifndef GWIN_PROGRESSBAR_AUTO #define GWIN_PROGRESSBAR_AUTO FALSE #endif + /** + * @brief Should the slider avoid snapping to a fixed position when the mouse is released + * @details Defaults to FALSE + * @note If FALSE the slider will snap to the closest set-able position when the + * mouse is released. If TRUE it will maintain the position the + * mouse was released at, except when at the minimum and maximum slider values. + */ + #ifndef GWIN_SLIDER_NOSNAP + #define GWIN_SLIDER_NOSNAP FALSE + #endif + /** + * @brief The number of pixels of dead-band at each end of the slider + * @details Defaults to 5 + * @note A dead-band is required because fingers can often cannot + * accurately control the slider peg at the edges of the slider + */ + #ifndef GWIN_SLIDER_DEAD_BAND + #define GWIN_SLIDER_DEAD_BAND 5 + #endif + /** + * @brief How many toggles it takes to go from minimum to maximum value on a slider + * @details Defaults to 20 + * @note When the slider is being operated by a toggle device this setting describes + * how many toggles are required to go from end to end. + */ + #ifndef GWIN_SLIDER_TOGGLE_INC + #define GWIN_SLIDER_TOGGLE_INC 20 + #endif /** @} */ #endif /* _GWIN_OPTIONS_H */ |