  | 
  
    MPLABĀ® Harmony Graphics Suite
    
   | 
 
 
 
 
Go to the documentation of this file.
   46 #ifndef LEGATO_SCROLLBAR_H 
   47 #define LEGATO_SCROLLBAR_H 
   51 #if LE_SCROLLBAR_WIDGET_ENABLED == 1 
   79 typedef enum leScrollBarState
 
   81     LE_SCROLLBAR_STATE_NONE,
 
   82     LE_SCROLLBAR_STATE_TOP_PRESSED,
 
   83     LE_SCROLLBAR_STATE_TOP_INSIDE,
 
   84     LE_SCROLLBAR_STATE_BOTTOM_PRESSED,
 
   85     LE_SCROLLBAR_STATE_BOTTOM_INSIDE,
 
   86     LE_SCROLLBAR_STATE_HANDLE_DOWN
 
   89 typedef struct leScrollBarWidget leScrollBarWidget;
 
   98 typedef void (*leScrollBarWidget_ValueChangedEvent)(leScrollBarWidget*);
 
  100 typedef struct leScrollBarWidget leScrollBarWidget;
 
  106 #define LE_SCROLLBARWIDGET_VTABLE(THIS_TYPE) \ 
  107     LE_WIDGET_VTABLE(THIS_TYPE) \ 
  109     leOrientation (*getOrientation)(const THIS_TYPE* _this); \ 
  110     leResult      (*setOrientation)(THIS_TYPE* _this, leOrientation align, leBool swapDimensions); \ 
  111     uint32_t      (*getMaximumValue)(const THIS_TYPE* _this); \ 
  112     leResult      (*setMaximumValue)(THIS_TYPE* _this, uint32_t val); \ 
  113     uint32_t      (*getExtentValue)(const THIS_TYPE* _this); \ 
  114     leResult      (*setExtentValue)(THIS_TYPE* _this, uint32_t val); \ 
  115     uint32_t      (*getScrollPercentage)(const THIS_TYPE* _this); \ 
  116     leResult      (*setScrollPercentage)(THIS_TYPE* _this, uint32_t val); \ 
  117     uint32_t      (*getScrollValue)(const THIS_TYPE* _this); \ 
  118     leResult      (*setScrollValue)(THIS_TYPE* _this, uint32_t val); \ 
  119     uint32_t      (*getStepSize)(const THIS_TYPE* _this); \ 
  120     leResult      (*setStepSize)(THIS_TYPE* _this, uint32_t val); \ 
  121     leResult      (*stepBackward)(THIS_TYPE* _this); \ 
  122     leResult      (*stepForward)(THIS_TYPE* _this); \ 
  123     leScrollBarWidget_ValueChangedEvent (*getValueChangedEventCallback)(const THIS_TYPE* _this); \ 
  124     leResult      (*setValueChangedEventCallback)(THIS_TYPE* _this, leScrollBarWidget_ValueChangedEvent cb); \ 
  126 typedef struct leScrollBarWidgetVTable
 
  128     LE_SCROLLBARWIDGET_VTABLE(leScrollBarWidget)
 
  129 } leScrollBarWidgetVTable; 
 
  144 typedef struct leScrollBarWidget
 
  148     const leScrollBarWidgetVTable* fn;
 
  150     leScrollBarState state; 
 
  158     leScrollBarWidget_ValueChangedEvent valueChangedEvent; 
 
  200 LIB_EXPORT leScrollBarWidget* leScrollBarWidget_New();
 
  212 LIB_EXPORT 
void leScrollBarWidget_Constructor(leScrollBarWidget* wgt);
 
  215 #define THIS_TYPE struct leWidget 
  247 leOrientation getOrientation(
const leScrollBarWidget* _this);
 
  288 virtual leResult setOrientation(leScrollBarWidget* _this,
 
  321 virtual uint32_t getMaximumValue(
const leScrollBarWidget* _this);
 
  357 virtual leResult setMaximumValue(leScrollBarWidget* _this,
 
  389 virtual uint32_t getExtentValue(
const leScrollBarWidget* _this);
 
  425 virtual leResult setExtentValue(leScrollBarWidget* _this,
 
  458 virtual uint32_t getScrollPercentage(
const leScrollBarWidget* _this);
 
  495 virtual leResult setScrollPercentage(leScrollBarWidget* _this,
 
  527 virtual uint32_t getScrollValue(
const leScrollBarWidget* _this);
 
  563 virtual leResult setScrollValue(leScrollBarWidget* _this,
 
  595 virtual uint32_t getStepSize(
const leScrollBarWidget* _this);
 
  632 virtual leResult setStepSize(leScrollBarWidget* _this,
 
  664 virtual leResult stepBackward(leScrollBarWidget* _this);
 
  695 virtual leResult stepForward(leScrollBarWidget* _this);
 
  707 virtual leScrollBarWidget_ValueChangedEvent getValueChangedEventCallback
 
  708                                           (
const leScrollBarWidget* _this);
 
  723 virtual leResult setValueChangedEventCallback(leScrollBarWidget* _this,
 
  724                                               leScrollBarWidget_ValueChangedEvent cb);
 
  730 #endif // LE_SCROLLBAR_WIDGET_ENABLED 
  
Defines common math functions for general use.
 
Error functions, macros and definitions.
 
leResult
This enum represents function call results.
Definition: legato_common.h:134
 
LIB_EXPORT uint32_t lePercentWholeRounded(uint32_t l, uint32_t r)
Calculate percent whole rounded.
Definition: legato_math.c:204
 
This struct represents a rectangle.
Definition: legato_common.h:405
 
Memory functions and definitions.
 
LIB_EXPORT uint32_t lePercentOf(uint32_t num, uint32_t percent)
Calculate percent of a number.
Definition: legato_math.c:218
 
leOrientation
This enum represents the orientation modes for objects.
Definition: legato_common.h:340
 
leBool
This enum represents booleans.
Definition: legato_common.h:157
 
@ LE_FALSE
Definition: legato_common.h:158
 
LIB_EXPORT leBool leRectContainsPoint(const leRect *rect, const lePoint *point)
Determines if a point is inside a rectangle.
Definition: legato_rect.c:31
 
General internal utilities for the library.
 
Fixed string functions and definitions.
 
The header file joins all header files used in the graphics object library.
 
leColor leScheme_GetRenderColor(const leScheme *schm, leSchemeColor clr)
Gets a scheme render color for the current layer color mode.
Definition: legato_scheme.c:68
 
@ LE_TRUE
Definition: legato_common.h:159
 
Common macros and definitions used by Legato.
 
virtual void destructor(leString *_this)
Destruct string.
 
This structure represents a integer Cartesian point.
Definition: legato_common.h:357