47 #ifndef LEGATO_IMAGESCALE_H 48 #define LEGATO_IMAGESCALE_H 52 #if LE_IMAGESCALE_WIDGET_ENABLED == 1 61 typedef struct leImageScaleWidget leImageScaleWidget;
69 typedef struct leImageScaleWidget leImageScaleWidget;
75 #define LE_IMAGEPLUSWIDGET_VTABLE(THIS_TYPE) \ 76 LE_WIDGET_VTABLE(THIS_TYPE) \ 78 leImage* (*getImage)(const THIS_TYPE* _this); \ 79 leResult (*setImage)(THIS_TYPE* _this, const leImage* img); \ 80 int32_t (*getTransformX)(const THIS_TYPE* _this); \ 81 leResult (*setTransformX)(THIS_TYPE* _this, int32_t x); \ 82 int32_t (*getTransformY)(const THIS_TYPE* _this); \ 83 leResult (*setTransformY)(THIS_TYPE* _this, int32_t y); \ 84 int32_t (*getTransformWidth)(const THIS_TYPE* _this); \ 85 leResult (*setTransformWidth)(THIS_TYPE* _this, int32_t w); \ 86 int32_t (*getTransformHeight)(const THIS_TYPE* _this); \ 87 leResult (*setTransformHeight)(THIS_TYPE* _this, int32_t h); \ 88 leResult (*resetTransform)(THIS_TYPE* _this); \ 89 leBool (*getStretchEnabled)(const THIS_TYPE* _this); \ 90 leResult (*setStretchEnabled)(THIS_TYPE* _this, leBool b); \ 91 leBool (*getPreserveAspectEnabled)(const THIS_TYPE* _this); \ 92 leResult (*setPreserveAspectEnabled)(THIS_TYPE* _this, leBool b); \ 93 leImageFilterMode (*getFilter)(const THIS_TYPE* _this); \ 94 leResult (*setFilter)(THIS_TYPE* _this, leImageFilterMode filter); \ 96 typedef struct leImageScaleWidgetVTable
98 LE_IMAGEPLUSWIDGET_VTABLE(leImageScaleWidget)
99 } leImageScaleWidgetVTable;
111 typedef struct leImageScaleWidget
115 const leImageScaleWidgetVTable* fn;
121 int32_t transformWidth;
122 int32_t transformHeight;
130 } leImageScaleWidget;
138 void _leImageScaleWidget_Destructor(leImageScaleWidget* img);
140 void _leImageScaleWidget_Paint(leImageScaleWidget* img);
160 leImageScaleWidget* leImageScaleWidget_New(
void);
172 void leImageScaleWidget_Constructor(leImageScaleWidget* wgt);
175 #define THIS_TYPE struct leWidget 206 virtual leImage* getImage(
const leImageScaleWidget* _this);
242 virtual leResult setImage(leImageScaleWidget* _this,
274 virtual int32_t getTransformX(
const leImageScaleWidget* _this);
311 virtual leResult setTransformX(leImageScaleWidget* _this,
344 virtual int32_t getTransformY(
const leImageScaleWidget* _this);
381 virtual leResult setTransformY(leImageScaleWidget* _this,
413 virtual int32_t getTransformWidth(
const leImageScaleWidget* _this);
449 virtual leResult setTransformWidth(leImageScaleWidget* _this,
482 virtual int32_t getTransformHeight(
const leImageScaleWidget* _this);
519 virtual leResult setTransformHeight(leImageScaleWidget* _this,
551 virtual leResult resetTransform(leImageScaleWidget* _this);
582 virtual leBool getStretchEnabled(
const leImageScaleWidget* _this);
618 virtual leResult setStretchEnabled(leImageScaleWidget* _this,
650 virtual leBool getPreserveAspectEnabled(
const leImageScaleWidget* _this);
686 virtual leResult setPreserveAspectEnabled(leImageScaleWidget* _this,
718 virtual leImageScaleWidget_ResizeFilter getResizeFilter(
const leImageScaleWidget* _this);
754 virtual leResult setResizeFilter(leImageScaleWidget* _this,
755 leImageScaleWidget_ResizeFilter filter);
764 #endif // LE_IMAGESCALE_WIDGET_ENABLED Common macros and definitions used by Legato.
Image functions and defintions.
Definition: legato_image.h:181
leResult
This enum represents function call results.
Definition: legato_common.h:123
leImageFilterMode
This enum represents image filter modes.
Definition: legato_image.h:110
leBool
This enum represents booleans.
Definition: legato_common.h:146