aboutsummaryrefslogtreecommitdiffstats
path: root/src/gwin
diff options
context:
space:
mode:
authorinmarket <andrewh@inmarket.com.au>2018-07-08 10:54:19 +1000
committerinmarket <andrewh@inmarket.com.au>2018-07-08 10:54:19 +1000
commit2ab2d77fcba42467b62f2be732cb8dc00510fe19 (patch)
tree8dbd616faa116a2946ad47c62c20d4a34fb749b2 /src/gwin
parent7e95acb7310d83284288a6e89a6b3fe4bf4e8668 (diff)
downloaduGFX-2ab2d77fcba42467b62f2be732cb8dc00510fe19.tar.gz
uGFX-2ab2d77fcba42467b62f2be732cb8dc00510fe19.tar.bz2
uGFX-2ab2d77fcba42467b62f2be732cb8dc00510fe19.zip
Change coord_t to gCoord
Diffstat (limited to 'src/gwin')
-rw-r--r--src/gwin/gwin.c52
-rw-r--r--src/gwin/gwin.h72
-rw-r--r--src/gwin/gwin_button.c8
-rw-r--r--src/gwin/gwin_checkbox.c8
-rw-r--r--src/gwin/gwin_class.h22
-rw-r--r--src/gwin/gwin_console.c6
-rw-r--r--src/gwin/gwin_console.h2
-rw-r--r--src/gwin/gwin_container.c8
-rw-r--r--src/gwin/gwin_container.h4
-rw-r--r--src/gwin/gwin_frame.c20
-rw-r--r--src/gwin/gwin_graph.c18
-rw-r--r--src/gwin/gwin_graph.h16
-rw-r--r--src/gwin/gwin_image.c2
-rw-r--r--src/gwin/gwin_keyboard.c8
-rw-r--r--src/gwin/gwin_keyboard.h4
-rw-r--r--src/gwin/gwin_label.c8
-rw-r--r--src/gwin/gwin_label.h4
-rw-r--r--src/gwin/gwin_list.c20
-rw-r--r--src/gwin/gwin_list.h6
-rw-r--r--src/gwin/gwin_progressbar.c2
-rw-r--r--src/gwin/gwin_progressbar.h2
-rw-r--r--src/gwin/gwin_radio.c8
-rw-r--r--src/gwin/gwin_slider.c10
-rw-r--r--src/gwin/gwin_slider.h2
-rw-r--r--src/gwin/gwin_tabset.c42
-rw-r--r--src/gwin/gwin_tabset.h2
-rw-r--r--src/gwin/gwin_textedit.c4
-rw-r--r--src/gwin/gwin_widget.c8
-rw-r--r--src/gwin/gwin_wm.c20
29 files changed, 194 insertions, 194 deletions
diff --git a/src/gwin/gwin.c b/src/gwin/gwin.c
index 9fbc304e..8b093851 100644
--- a/src/gwin/gwin.c
+++ b/src/gwin/gwin.c
@@ -237,44 +237,44 @@ void gwinClear(GHandle gh) {
gh->vmt->AfterClear(gh);
}
-void gwinDrawPixel(GHandle gh, coord_t x, coord_t y) {
+void gwinDrawPixel(GHandle gh, gCoord x, gCoord y) {
if (!_gwinDrawStart(gh)) return;
gdispGDrawPixel(gh->display, gh->x+x, gh->y+y, gh->color);
_gwinDrawEnd(gh);
}
-void gwinDrawLine(GHandle gh, coord_t x0, coord_t y0, coord_t x1, coord_t y1) {
+void gwinDrawLine(GHandle gh, gCoord x0, gCoord y0, gCoord x1, gCoord y1) {
if (!_gwinDrawStart(gh)) return;
gdispGDrawLine(gh->display, gh->x+x0, gh->y+y0, gh->x+x1, gh->y+y1, gh->color);
_gwinDrawEnd(gh);
}
-void gwinDrawBox(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy) {
+void gwinDrawBox(GHandle gh, gCoord x, gCoord y, gCoord cx, gCoord cy) {
if (!_gwinDrawStart(gh)) return;
gdispGDrawBox(gh->display, gh->x+x, gh->y+y, cx, cy, gh->color);
_gwinDrawEnd(gh);
}
-void gwinFillArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy) {
+void gwinFillArea(GHandle gh, gCoord x, gCoord y, gCoord cx, gCoord cy) {
if (!_gwinDrawStart(gh)) return;
gdispGFillArea(gh->display, gh->x+x, gh->y+y, cx, cy, gh->color);
_gwinDrawEnd(gh);
}
-void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coord_t srcx, coord_t srcy, coord_t srccx, const pixel_t *buffer) {
+void gwinBlitArea(GHandle gh, gCoord x, gCoord y, gCoord cx, gCoord cy, gCoord srcx, gCoord srcy, gCoord srccx, const pixel_t *buffer) {
if (!_gwinDrawStart(gh)) return;
gdispGBlitArea(gh->display, gh->x+x, gh->y+y, cx, cy, srcx, srcy, srccx, buffer);
_gwinDrawEnd(gh);
}
#if GDISP_NEED_CIRCLE
- void gwinDrawCircle(GHandle gh, coord_t x, coord_t y, coord_t radius) {
+ void gwinDrawCircle(GHandle gh, gCoord x, gCoord y, gCoord radius) {
if (!_gwinDrawStart(gh)) return;
gdispGDrawCircle(gh->display, gh->x+x, gh->y+y, radius, gh->color);
_gwinDrawEnd(gh);
}
- void gwinFillCircle(GHandle gh, coord_t x, coord_t y, coord_t radius) {
+ void gwinFillCircle(GHandle gh, gCoord x, gCoord y, gCoord radius) {
if (!_gwinDrawStart(gh)) return;
gdispGFillCircle(gh->display, gh->x+x, gh->y+y, radius, gh->color);
_gwinDrawEnd(gh);
@@ -282,7 +282,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
#endif
#if GDISP_NEED_DUALCIRCLE
- void gwinFillDualCircle(GHandle gh, coord_t x, coord_t y, coord_t radius1, coord_t radius2) {
+ void gwinFillDualCircle(GHandle gh, gCoord x, gCoord y, gCoord radius1, gCoord radius2) {
if (!_gwinDrawStart(gh)) return;
gdispGFillDualCircle(gh->display, gh->x+x, gh->y+y, radius1, gh->bgcolor, radius2, gh->color);
_gwinDrawEnd(gh);
@@ -290,13 +290,13 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
#endif
#if GDISP_NEED_ELLIPSE
- void gwinDrawEllipse(GHandle gh, coord_t x, coord_t y, coord_t a, coord_t b) {
+ void gwinDrawEllipse(GHandle gh, gCoord x, gCoord y, gCoord a, gCoord b) {
if (!_gwinDrawStart(gh)) return;
gdispGDrawEllipse(gh->display, gh->x+x, gh->y+y, a, b, gh->color);
_gwinDrawEnd(gh);
}
- void gwinFillEllipse(GHandle gh, coord_t x, coord_t y, coord_t a, coord_t b) {
+ void gwinFillEllipse(GHandle gh, gCoord x, gCoord y, gCoord a, gCoord b) {
if (!_gwinDrawStart(gh)) return;
gdispGFillEllipse(gh->display, gh->x+x, gh->y+y, a, b, gh->color);
_gwinDrawEnd(gh);
@@ -304,19 +304,19 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
#endif
#if GDISP_NEED_ARC
- void gwinDrawArc(GHandle gh, coord_t x, coord_t y, coord_t radius, coord_t startangle, coord_t endangle) {
+ void gwinDrawArc(GHandle gh, gCoord x, gCoord y, gCoord radius, gCoord startangle, gCoord endangle) {
if (!_gwinDrawStart(gh)) return;
gdispGDrawArc(gh->display, gh->x+x, gh->y+y, radius, startangle, endangle, gh->color);
_gwinDrawEnd(gh);
}
- void gwinFillArc(GHandle gh, coord_t x, coord_t y, coord_t radius, coord_t startangle, coord_t endangle) {
+ void gwinFillArc(GHandle gh, gCoord x, gCoord y, gCoord radius, gCoord startangle, gCoord endangle) {
if (!_gwinDrawStart(gh)) return;
gdispGFillArc(gh->display, gh->x+x, gh->y+y, radius, startangle, endangle, gh->color);
_gwinDrawEnd(gh);
}
- void gwinDrawThickArc(GHandle gh, coord_t x, coord_t y, coord_t startradius, coord_t endradius, coord_t startangle, coord_t endangle) {
+ void gwinDrawThickArc(GHandle gh, gCoord x, gCoord y, gCoord startradius, gCoord endradius, gCoord startangle, gCoord endangle) {
if (!_gwinDrawStart(gh)) return;
gdispGDrawThickArc(gh->display, gh->x+x, gh->y+y, startradius, endradius, startangle, endangle, gh->color);
_gwinDrawEnd(gh);
@@ -324,13 +324,13 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
#endif
#if GDISP_NEED_ARCSECTORS
- void gwinDrawArcSectors(GHandle gh, coord_t x, coord_t y, coord_t radius, uint8_t sectors) {
+ void gwinDrawArcSectors(GHandle gh, gCoord x, gCoord y, gCoord radius, uint8_t sectors) {
if (!_gwinDrawStart(gh)) return;
gdispGDrawArcSectors(gh->display, gh->x+x, gh->y+y, radius, sectors, gh->color);
_gwinDrawEnd(gh);
}
- void gwinFillArcSectors(GHandle gh, coord_t x, coord_t y, coord_t radius, uint8_t sectors) {
+ void gwinFillArcSectors(GHandle gh, gCoord x, gCoord y, gCoord radius, uint8_t sectors) {
if (!_gwinDrawStart(gh)) return;
gdispGFillArcSectors(gh->display, gh->x+x, gh->y+y, radius, sectors, gh->color);
_gwinDrawEnd(gh);
@@ -338,7 +338,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
#endif
#if GDISP_NEED_PIXELREAD
- color_t gwinGetPixelColor(GHandle gh, coord_t x, coord_t y) {
+ color_t gwinGetPixelColor(GHandle gh, gCoord x, gCoord y) {
if (!_gwinDrawStart(gh)) return (color_t)0;
return gdispGGetPixelColor(gh->display, gh->x+x, gh->y+y);
_gwinDrawEnd(gh);
@@ -346,37 +346,37 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
#endif
#if GDISP_NEED_TEXT
- void gwinDrawChar(GHandle gh, coord_t x, coord_t y, char c) {
+ void gwinDrawChar(GHandle gh, gCoord x, gCoord y, char c) {
if (!gh->font || !_gwinDrawStart(gh)) return;
gdispGDrawChar(gh->display, gh->x+x, gh->y+y, c, gh->font, gh->color);
_gwinDrawEnd(gh);
}
- void gwinFillChar(GHandle gh, coord_t x, coord_t y, char c) {
+ void gwinFillChar(GHandle gh, gCoord x, gCoord y, char c) {
if (!gh->font || !_gwinDrawStart(gh)) return;
gdispGFillChar(gh->display, gh->x+x, gh->y+y, c, gh->font, gh->color, gh->bgcolor);
_gwinDrawEnd(gh);
}
- void gwinDrawString(GHandle gh, coord_t x, coord_t y, const char *str) {
+ void gwinDrawString(GHandle gh, gCoord x, gCoord y, const char *str) {
if (!gh->font || !_gwinDrawStart(gh)) return;
gdispGDrawString(gh->display, gh->x+x, gh->y+y, str, gh->font, gh->color);
_gwinDrawEnd(gh);
}
- void gwinFillString(GHandle gh, coord_t x, coord_t y, const char *str) {
+ void gwinFillString(GHandle gh, gCoord x, gCoord y, const char *str) {
if (!gh->font || !_gwinDrawStart(gh)) return;
gdispGFillString(gh->display, gh->x+x, gh->y+y, str, gh->font, gh->color, gh->bgcolor);
_gwinDrawEnd(gh);
}
- void gwinDrawStringBox(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, const char* str, justify_t justify) {
+ void gwinDrawStringBox(GHandle gh, gCoord x, gCoord y, gCoord cx, gCoord cy, const char* str, justify_t justify) {
if (!gh->font || !_gwinDrawStart(gh)) return;
gdispGDrawStringBox(gh->display, gh->x+x, gh->y+y, cx, cy, str, gh->font, gh->color, justify);
_gwinDrawEnd(gh);
}
- void gwinFillStringBox(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, const char* str, justify_t justify) {
+ void gwinFillStringBox(GHandle gh, gCoord x, gCoord y, gCoord cx, gCoord cy, const char* str, justify_t justify) {
if (!gh->font || !_gwinDrawStart(gh)) return;
gdispGFillStringBox(gh->display, gh->x+x, gh->y+y, cx, cy, str, gh->font, gh->color, gh->bgcolor, justify);
_gwinDrawEnd(gh);
@@ -384,18 +384,18 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
#endif
#if GDISP_NEED_CONVEX_POLYGON
- void gwinDrawPoly(GHandle gh, coord_t tx, coord_t ty, const gPoint *pntarray, unsigned cnt) {
+ void gwinDrawPoly(GHandle gh, gCoord tx, gCoord ty, const gPoint *pntarray, unsigned cnt) {
if (!_gwinDrawStart(gh)) return;
gdispGDrawPoly(gh->display, tx+gh->x, ty+gh->y, pntarray, cnt, gh->color);
_gwinDrawEnd(gh);
}
- void gwinFillConvexPoly(GHandle gh, coord_t tx, coord_t ty, const gPoint *pntarray, unsigned cnt) {
+ void gwinFillConvexPoly(GHandle gh, gCoord tx, gCoord ty, const gPoint *pntarray, unsigned cnt) {
if (!_gwinDrawStart(gh)) return;
gdispGFillConvexPoly(gh->display, tx+gh->x, ty+gh->y, pntarray, cnt, gh->color);
_gwinDrawEnd(gh);
}
- void gwinDrawThickLine(GHandle gh, coord_t x0, coord_t y0, coord_t x1, coord_t y1, coord_t width, gBool round) {
+ void gwinDrawThickLine(GHandle gh, gCoord x0, gCoord y0, gCoord x1, gCoord y1, gCoord width, gBool round) {
if (!_gwinDrawStart(gh)) return;
gdispGDrawThickLine(gh->display, gh->x+x0, gh->y+y0, gh->x+x1, gh->y+y1, gh->color, width, round);
_gwinDrawEnd(gh);
@@ -403,7 +403,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
#endif
#if GDISP_NEED_IMAGE
- gdispImageError gwinDrawImage(GHandle gh, gdispImage *img, coord_t x, coord_t y, coord_t cx, coord_t cy, coord_t sx, coord_t sy) {
+ gdispImageError gwinDrawImage(GHandle gh, gdispImage *img, gCoord x, gCoord y, gCoord cx, gCoord cy, gCoord sx, gCoord sy) {
gdispImageError ret;
if (!_gwinDrawStart(gh)) return GDISP_IMAGE_ERR_OK;
diff --git a/src/gwin/gwin.h b/src/gwin/gwin.h
index e313743a..c27aadc3 100644
--- a/src/gwin/gwin.h
+++ b/src/gwin/gwin.h
@@ -44,10 +44,10 @@ typedef struct GWindowObject {
#endif
const struct gwinVMT* vmt; /**< The VMT for this GWIN */
GDisplay * display; /**< The display this window is on */
- coord_t x; /**< The position relative to the screen */
- coord_t y; /**< The position relative to the screen */
- coord_t width; /**< The width of this window */
- coord_t height; /**< The height of this window */
+ gCoord x; /**< The position relative to the screen */
+ gCoord y; /**< The position relative to the screen */
+ gCoord width; /**< The width of this window */
+ gCoord height; /**< The height of this window */
color_t color; /**< The current foreground drawing color */
color_t bgcolor; /**< The current background drawing color */
uint32_t flags; /**< Window flags (the meaning is private to the GWIN class) */
@@ -73,10 +73,10 @@ typedef struct GWindowObject {
* @{
*/
typedef struct GWindowInit {
- coord_t x; /**< The initial position relative to its parent */
- coord_t y; /**< The initial position relative to its parent */
- coord_t width; /**< The width */
- coord_t height; /**< The height */
+ gCoord x; /**< The initial position relative to its parent */
+ gCoord y; /**< The initial position relative to its parent */
+ gCoord width; /**< The width */
+ gCoord height; /**< The height */
gBool show; /**< Should the window be visible initially */
#if GWIN_NEED_CONTAINERS
GHandle parent; /**< The parent - must be a container or NULL */
@@ -437,7 +437,7 @@ gBool gwinGetEnabled(GHandle gh);
*
* @api
*/
-void gwinMove(GHandle gh, coord_t x, coord_t y);
+void gwinMove(GHandle gh, gCoord x, gCoord y);
/**
* @brief Resize a window
@@ -455,7 +455,7 @@ void gwinMove(GHandle gh, coord_t x, coord_t y);
*
* @api
*/
-void gwinResize(GHandle gh, coord_t width, coord_t height);
+void gwinResize(GHandle gh, gCoord width, gCoord height);
/**
* @brief Redraw a window
@@ -622,7 +622,7 @@ void gwinClear(GHandle gh);
*
* @api
*/
-void gwinDrawPixel(GHandle gh, coord_t x, coord_t y);
+void gwinDrawPixel(GHandle gh, gCoord x, gCoord y);
/**
* @brief Draw a line in the window
@@ -635,7 +635,7 @@ void gwinDrawPixel(GHandle gh, coord_t x, coord_t y);
*
* @api
*/
-void gwinDrawLine(GHandle gh, coord_t x0, coord_t y0, coord_t x1, coord_t y1);
+void gwinDrawLine(GHandle gh, gCoord x0, gCoord y0, gCoord x1, gCoord y1);
/**
* @brief Draw a box in the window
@@ -648,7 +648,7 @@ void gwinDrawLine(GHandle gh, coord_t x0, coord_t y0, coord_t x1, coord_t y1);
*
* @api
*/
-void gwinDrawBox(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy);
+void gwinDrawBox(GHandle gh, gCoord x, gCoord y, gCoord cx, gCoord cy);
/**
* @brief Fill an rectangular area in the window
@@ -661,7 +661,7 @@ void gwinDrawBox(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy);
*
* @api
*/
-void gwinFillArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy);
+void gwinFillArea(GHandle gh, gCoord x, gCoord y, gCoord cx, gCoord cy);
/**
* @brief Fill an area in the window using the supplied bitmap.
@@ -680,7 +680,7 @@ void gwinFillArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy);
*
* @api
*/
-void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coord_t srcx, coord_t srcy, coord_t srccx, const pixel_t *buffer);
+void gwinBlitArea(GHandle gh, gCoord x, gCoord y, gCoord cx, gCoord cy, gCoord srcx, gCoord srcy, gCoord srccx, const pixel_t *buffer);
/*-------------------------------------------------
* Circle, ellipse, arc and arc-sectors functions
@@ -698,7 +698,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinDrawCircle(GHandle gh, coord_t x, coord_t y, coord_t radius);
+ void gwinDrawCircle(GHandle gh, gCoord x, gCoord y, gCoord radius);
/**
* @brief Draw a filled circle in the window.
@@ -711,7 +711,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinFillCircle(GHandle gh, coord_t x, coord_t y, coord_t radius);
+ void gwinFillCircle(GHandle gh, gCoord x, gCoord y, gCoord radius);
#endif
#if GDISP_NEED_DUALCIRCLE || defined(__DOXYGEN__)
@@ -729,7 +729,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinFillDualCircle(GHandle gh, coord_t x, coord_t y, coord_t radius1, coord_t radius2);
+ void gwinFillDualCircle(GHandle gh, gCoord x, gCoord y, gCoord radius1, gCoord radius2);
#endif
#if GDISP_NEED_ELLIPSE || defined(__DOXYGEN__)
@@ -744,7 +744,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinDrawEllipse(GHandle gh, coord_t x, coord_t y, coord_t a, coord_t b);
+ void gwinDrawEllipse(GHandle gh, gCoord x, gCoord y, gCoord a, gCoord b);
/**
* @brief Draw an filled ellipse.
@@ -757,7 +757,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinFillEllipse(GHandle gh, coord_t x, coord_t y, coord_t a, coord_t b);
+ void gwinFillEllipse(GHandle gh, gCoord x, gCoord y, gCoord a, gCoord b);
#endif
#if GDISP_NEED_ARC || defined(__DOXYGEN__)
@@ -774,7 +774,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinDrawArc(GHandle gh, coord_t x, coord_t y, coord_t radius, coord_t startangle, coord_t endangle);
+ void gwinDrawArc(GHandle gh, gCoord x, gCoord y, gCoord radius, gCoord startangle, gCoord endangle);
/*
* @brief Draw a filled arc in the window.
@@ -789,7 +789,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinFillArc(GHandle gh, coord_t x, coord_t y, coord_t radius, coord_t startangle, coord_t endangle);
+ void gwinFillArc(GHandle gh, gCoord x, gCoord y, gCoord radius, gCoord startangle, gCoord endangle);
/*
* @brief Draw a thick arc in the window.
@@ -805,7 +805,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinDrawThickArc(GHandle gh, coord_t x, coord_t y, coord_t startradius, coord_t endradius, coord_t startangle, coord_t endangle);
+ void gwinDrawThickArc(GHandle gh, gCoord x, gCoord y, gCoord startradius, gCoord endradius, gCoord startangle, gCoord endangle);
#endif
#if GDISP_NEED_ARCSECTORS || defined(__DOXYGEN__)
@@ -830,7 +830,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinDrawArcSectors(GHandle gh, coord_t x, coord_t y, coord_t radius, uint8_t sectors);
+ void gwinDrawArcSectors(GHandle gh, gCoord x, gCoord y, gCoord radius, uint8_t sectors);
/*
* @brief Draw a filled selection of 45 degree arcs of a circle in the window.
@@ -853,7 +853,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinFillArcSectors(GHandle gh, coord_t x, coord_t y, coord_t radius, uint8_t sectors);
+ void gwinFillArcSectors(GHandle gh, gCoord x, gCoord y, gCoord radius, uint8_t sectors);
#endif
/*-------------------------------------------------
@@ -871,7 +871,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- color_t gwinGetPixelColor(GHandle gh, coord_t x, coord_t y);
+ color_t gwinGetPixelColor(GHandle gh, gCoord x, gCoord y);
#endif
/*-------------------------------------------------
@@ -891,7 +891,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinDrawChar(GHandle gh, coord_t x, coord_t y, char c);
+ void gwinDrawChar(GHandle gh, gCoord x, gCoord y, char c);
/**
* @brief Draw a text character with a filled background at the specified position in the window.
@@ -905,7 +905,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinFillChar(GHandle gh, coord_t x, coord_t y, char c);
+ void gwinFillChar(GHandle gh, gCoord x, gCoord y, char c);
/**
* @brief Draw a text string in the window
@@ -919,7 +919,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinDrawString(GHandle gh, coord_t x, coord_t y, const char *str);
+ void gwinDrawString(GHandle gh, gCoord x, gCoord y, const char *str);
/**
* @brief Draw a text string with a filled background in the window
@@ -933,7 +933,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinFillString(GHandle gh, coord_t x, coord_t y, const char *str);
+ void gwinFillString(GHandle gh, gCoord x, gCoord y, const char *str);
/**
* @brief Draw a text string verticly centered within the specified box.
@@ -950,7 +950,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinDrawStringBox(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, const char* str, justify_t justify);
+ void gwinDrawStringBox(GHandle gh, gCoord x, gCoord y, gCoord cx, gCoord cy, const char* str, justify_t justify);
/**
* @brief Draw a text string verticly centered within the specified filled box.
@@ -967,7 +967,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinFillStringBox(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, const char* str, justify_t justify);
+ void gwinFillStringBox(GHandle gh, gCoord x, gCoord y, gCoord cx, gCoord cy, const char* str, justify_t justify);
#endif
/*-------------------------------------------------
@@ -987,7 +987,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinDrawPoly(GHandle gh, coord_t tx, coord_t ty, const gPoint *pntarray, unsigned cnt);
+ void gwinDrawPoly(GHandle gh, gCoord tx, gCoord ty, const gPoint *pntarray, unsigned cnt);
/**
* @brief Fill a convex polygon
@@ -1010,7 +1010,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinFillConvexPoly(GHandle gh, coord_t tx, coord_t ty, const gPoint *pntarray, unsigned cnt);
+ void gwinFillConvexPoly(GHandle gh, gCoord tx, gCoord ty, const gPoint *pntarray, unsigned cnt);
/**
* @brief Draw a thick line in the window
@@ -1027,7 +1027,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- void gwinDrawThickLine(GHandle gh, coord_t x0, coord_t y0, coord_t x1, coord_t y1, coord_t width, gBool round);
+ void gwinDrawThickLine(GHandle gh, gCoord x0, gCoord y0, gCoord x1, gCoord y1, gCoord width, gBool round);
#endif
/*-------------------------------------------------
@@ -1056,7 +1056,7 @@ void gwinBlitArea(GHandle gh, coord_t x, coord_t y, coord_t cx, coord_t cy, coor
*
* @api
*/
- gdispImageError gwinDrawImage(GHandle gh, gdispImage *img, coord_t x, coord_t y, coord_t cx, coord_t cy, coord_t sx, coord_t sy);
+ gdispImageError gwinDrawImage(GHandle gh, gdispImage *img, gCoord x, gCoord y, gCoord cx, gCoord cy, gCoord sx, gCoord sy);
#endif
/*-------------------------------------------------
diff --git a/src/gwin/gwin_button.c b/src/gwin/gwin_button.c
index 2c4b598e..2e637140 100644
--- a/src/gwin/gwin_button.c
+++ b/src/gwin/gwin_button.c
@@ -25,14 +25,14 @@
#if GINPUT_NEED_MOUSE
// A mouse down has occurred over the button
- static void ButtonMouseDown(GWidgetObject *gw, coord_t x, coord_t y) {
+ static void ButtonMouseDown(GWidgetObject *gw, gCoord x, gCoord y) {
(void) x; (void) y;
gw->g.flags |= GBUTTON_FLG_PRESSED;
_gwinUpdate((GHandle)gw);
}
// A mouse up has occurred (it may or may not be over the button)
- static void ButtonMouseUp(GWidgetObject *gw, coord_t x, coord_t y) {
+ static void ButtonMouseUp(GWidgetObject *gw, gCoord x, gCoord y) {
(void) x; (void) y;
gw->g.flags &= ~GBUTTON_FLG_PRESSED;
_gwinUpdate((GHandle)gw);
@@ -183,7 +183,7 @@ static const GColorSet *getButtonColors(GWidgetObject *gw) {
const GColorSet * pcol;
fixed alpha;
fixed dalpha;
- coord_t i;
+ gCoord i;
color_t tcol, bcol;
(void) param;
@@ -453,7 +453,7 @@ static const GColorSet *getButtonColors(GWidgetObject *gw) {
#if GDISP_NEED_IMAGE || defined(__DOXYGEN__)
void gwinButtonDraw_Image(GWidgetObject *gw, void *param) {
const GColorSet * pcol;
- coord_t sy;
+ gCoord sy;
if (gw->g.vmt != (gwinVMT *)&buttonVMT) return;
pcol = getButtonColors(gw);
diff --git a/src/gwin/gwin_checkbox.c b/src/gwin/gwin_checkbox.c
index 21d2ba86..42734626 100644
--- a/src/gwin/gwin_checkbox.c
+++ b/src/gwin/gwin_checkbox.c
@@ -44,7 +44,7 @@ static void SendCheckboxEvent(GWidgetObject *gw) {
}
#if GINPUT_NEED_MOUSE
- static void CheckboxMouseDown(GWidgetObject *gw, coord_t x, coord_t y) {
+ static void CheckboxMouseDown(GWidgetObject *gw, gCoord x, gCoord y) {
(void) x; (void) y;
gw->g.flags ^= GCHECKBOX_FLG_CHECKED;
_gwinUpdate((GHandle)gw);
@@ -173,7 +173,7 @@ static const GColorSet *getCheckboxColors(GWidgetObject *gw) {
void gwinCheckboxDraw_CheckOnLeft(GWidgetObject *gw, void *param) {
#define gcw ((GCheckboxObject *)gw)
- coord_t ld, df;
+ gCoord ld, df;
const GColorSet * pcol;
(void) param;
@@ -202,7 +202,7 @@ void gwinCheckboxDraw_CheckOnLeft(GWidgetObject *gw, void *param) {
void gwinCheckboxDraw_CheckOnRight(GWidgetObject *gw, void *param) {
#define gcw ((GCheckboxObject *)gw)
- coord_t ep, ld, df;
+ gCoord ep, ld, df;
const GColorSet * pcol;
(void) param;
@@ -254,7 +254,7 @@ void gwinCheckboxDraw_CheckOnRight(GWidgetObject *gw, void *param) {
const GColorSet * pcol;
fixed alpha;
fixed dalpha;
- coord_t i;
+ gCoord i;
color_t tcol, bcol;
(void) param;
diff --git a/src/gwin/gwin_class.h b/src/gwin/gwin_class.h
index c161c0f6..a38f0378 100644
--- a/src/gwin/gwin_class.h
+++ b/src/gwin/gwin_class.h
@@ -87,9 +87,9 @@ typedef struct gwinVMT {
void (*DefaultDraw) (GWidgetObject *gw, void *param); /**< The default drawing routine (mandatory) */
#if GINPUT_NEED_MOUSE
struct {
- void (*MouseDown) (GWidgetObject *gw, coord_t x, coord_t y); /**< Process mouse down events (optional) */
- void (*MouseUp) (GWidgetObject *gw, coord_t x, coord_t y); /**< Process mouse up events (optional) */
- void (*MouseMove) (GWidgetObject *gw, coord_t x, coord_t y); /**< Process mouse move events (optional) */
+ void (*MouseDown) (GWidgetObject *gw, gCoord x, gCoord y); /**< Process mouse down events (optional) */
+ void (*MouseUp) (GWidgetObject *gw, gCoord x, gCoord y); /**< Process mouse up events (optional) */
+ void (*MouseMove) (GWidgetObject *gw, gCoord x, gCoord y); /**< Process mouse move events (optional) */
};
#endif
#if GINPUT_NEED_KEYBOARD || GWIN_NEED_KEYBOARD
@@ -131,10 +131,10 @@ typedef struct gwinVMT {
*/
typedef struct gcontainerVMT {
gwidgetVMT gw;
- coord_t (*LeftBorder) (GHandle gh); /**< The size of the left border (mandatory) */
- coord_t (*TopBorder) (GHandle gh); /**< The size of the top border (mandatory) */
- coord_t (*RightBorder) (GHandle gh); /**< The size of the right border (mandatory) */
- coord_t (*BottomBorder) (GHandle gh); /**< The size of the bottom border (mandatory) */
+ gCoord (*LeftBorder) (GHandle gh); /**< The size of the left border (mandatory) */
+ gCoord (*TopBorder) (GHandle gh); /**< The size of the top border (mandatory) */
+ gCoord (*RightBorder) (GHandle gh); /**< The size of the right border (mandatory) */
+ gCoord (*BottomBorder) (GHandle gh); /**< The size of the bottom border (mandatory) */
void (*NotifyAdd) (GHandle gh, GHandle ghChild); /**< Notification that a child has been added (optional) */
void (*NotifyDelete) (GHandle gh, GHandle ghChild); /**< Notification that a child has been deleted (optional) */
} gcontainerVMT;
@@ -157,8 +157,8 @@ typedef struct gwinVMT {
gBool (*Add) (GHandle gh, const GWindowInit *pInit); /**< A window has been added */
void (*Delete) (GHandle gh); /**< A window has been deleted */
void (*Redraw) (GHandle gh); /**< A window needs to be redraw (or undrawn) */
- void (*Size) (GHandle gh, coord_t w, coord_t h); /**< A window wants to be resized */
- void (*Move) (GHandle gh, coord_t x, coord_t y); /**< A window wants to be moved */
+ void (*Size) (GHandle gh, gCoord w, gCoord h); /**< A window wants to be resized */
+ void (*Move) (GHandle gh, gCoord x, gCoord y); /**< A window wants to be moved */
void (*Raise) (GHandle gh); /**< A window wants to be on top */
void (*MinMax) (GHandle gh, GWindowMinMax minmax); /**< A window wants to be minimized/maximised */
} gwmVMT;
@@ -353,7 +353,7 @@ gBool _gwinWMAdd(GHandle gh, const GWindowInit *pInit);
*
* @notapi
*/
- void _gwidgetDrawFocusRect(GWidgetObject *gw, coord_t x, coord_t y, coord_t cx, coord_t cy);
+ void _gwidgetDrawFocusRect(GWidgetObject *gw, gCoord x, gCoord y, gCoord cx, gCoord cy);
/**
* @brief Draw a simple focus circle in the default style.
@@ -368,7 +368,7 @@ gBool _gwinWMAdd(GHandle gh, const GWindowInit *pInit);
* @notapi
*/
#if GDISP_NEED_CIRCLE
- void _gwidgetDrawFocusCircle(GWidgetObject *gx, coord_t radius);
+ void _gwidgetDrawFocusCircle(GWidgetObject *gx, gCoord radius);
#endif
#else
diff --git a/src/gwin/gwin_console.c b/src/gwin/gwin_console.c
index 7bd0780e..d2b55f5d 100644
--- a/src/gwin/gwin_console.c
+++ b/src/gwin/gwin_console.c
@@ -193,7 +193,7 @@
static void HistoryRedraw(GWindowObject *gh) {
#define gcw ((GConsoleObject *)gh)
- coord_t fy;
+ gCoord fy;
// No redrawing if there is no history
if (!gcw->buffer)
@@ -229,7 +229,7 @@
#if GWIN_CONSOLE_USE_CLEAR_LINES
// Clear the remaining space
{
- coord_t y;
+ gCoord y;
y = gcw->cy;
if (gcw->cx)
@@ -563,7 +563,7 @@ void gwinPutChar(GHandle gh, char c) {
// Set the cursor to the start of the last line
gcw->cx = 0;
- gcw->cy = (((coord_t)(gh->height/fy))-1)*fy;
+ gcw->cy = (((gCoord)(gh->height/fy))-1)*fy;
}
#else
{
diff --git a/src/gwin/gwin_console.h b/src/gwin/gwin_console.h
index 208ab16b..922a20a9 100644
--- a/src/gwin/gwin_console.h
+++ b/src/gwin/gwin_console.h
@@ -31,7 +31,7 @@
// A console window. Supports wrapped text writing and a cursor.
typedef struct GConsoleObject {
GWindowObject g;
- coord_t cx, cy; // Cursor position
+ gCoord cx, cy; // Cursor position
#if GWIN_CONSOLE_ESCSEQ
uint8_t startattr; // ANSI-like escape sequences
diff --git a/src/gwin/gwin_container.c b/src/gwin/gwin_container.c
index f680f6fb..9b1bd3c4 100644
--- a/src/gwin/gwin_container.c
+++ b/src/gwin/gwin_container.c
@@ -59,13 +59,13 @@ GHandle gwinGetSibling(GHandle gh) {
return 0;
}
-coord_t gwinGetInnerWidth(GHandle gh) {
+gCoord gwinGetInnerWidth(GHandle gh) {
if (!(gh->flags & GWIN_FLG_CONTAINER))
return 0;
return gh->width - ((const gcontainerVMT *)gh->vmt)->LeftBorder(gh) - ((const gcontainerVMT *)gh->vmt)->RightBorder(gh);
}
-coord_t gwinGetInnerHeight(GHandle gh) {
+gCoord gwinGetInnerHeight(GHandle gh) {
if (!(gh->flags & GWIN_FLG_CONTAINER))
return 0;
return gh->height - ((const gcontainerVMT *)gh->vmt)->TopBorder(gh) - ((const gcontainerVMT *)gh->vmt)->BottomBorder(gh);
@@ -92,7 +92,7 @@ coord_t gwinGetInnerHeight(GHandle gh) {
#define BORDER_WIDTH 2
-static coord_t ContainerBorderSize(GHandle gh) { return (gh->flags & GWIN_CONTAINER_BORDER) ? BORDER_WIDTH : 0; }
+static gCoord ContainerBorderSize(GHandle gh) { return (gh->flags & GWIN_CONTAINER_BORDER) ? BORDER_WIDTH : 0; }
// The container VMT table
static const gcontainerVMT containerVMT = {
@@ -169,7 +169,7 @@ void gwinContainerDraw_Std(GWidgetObject *gw, void *param) {
#if GDISP_NEED_IMAGE
void gwinContainerDraw_Image(GWidgetObject *gw, void *param) {
#define gi ((gdispImage *)param)
- coord_t x, y, iw, ih, mx, my;
+ gCoord x, y, iw, ih, mx, my;
if (gw->g.vmt != (gwinVMT *)&containerVMT)
return;
diff --git a/src/gwin/gwin_container.h b/src/gwin/gwin_container.h
index a4a3afa2..cdb4b818 100644
--- a/src/gwin/gwin_container.h
+++ b/src/gwin/gwin_container.h
@@ -81,7 +81,7 @@ GHandle gwinGetSibling(GHandle gh);
*
* @api
*/
-coord_t gwinGetInnerWidth(GHandle gh);
+gCoord gwinGetInnerWidth(GHandle gh);
/**
* @brief Get the inner height of a container window
@@ -92,7 +92,7 @@ coord_t gwinGetInnerWidth(GHandle gh);
*
* @api
*/
-coord_t gwinGetInnerHeight(GHandle gh);
+gCoord gwinGetInnerHeight(GHandle gh);
/**
diff --git a/src/gwin/gwin_frame.c b/src/gwin/gwin_frame.c
index 9aed4c06..c79e813d 100644
--- a/src/gwin/gwin_frame.c
+++ b/src/gwin/gwin_frame.c
@@ -37,10 +37,10 @@
#error "GWIN Frame: - Flag definitions don't match"
#endif
-static coord_t FrameBorderSizeL(GHandle gh) { (void)gh; return FRM_BORDER_L; }
-static coord_t FrameBorderSizeR(GHandle gh) { (void)gh; return FRM_BORDER_R; }
-static coord_t FrameBorderSizeT(GHandle gh) { (void)gh; return FRM_BORDER_T; }
-static coord_t FrameBorderSizeB(GHandle gh) { (void)gh; return FRM_BORDER_B; }
+static gCoord FrameBorderSizeL(GHandle gh) { (void)gh; return FRM_BORDER_L; }
+static gCoord FrameBorderSizeR(GHandle gh) { (void)gh; return FRM_BORDER_R; }
+static gCoord FrameBorderSizeT(GHandle gh) { (void)gh; return FRM_BORDER_T; }
+static gCoord FrameBorderSizeB(GHandle gh) { (void)gh; return FRM_BORDER_B; }
static void forceFrameRedraw(GWidgetObject *gw) {
// Force a redraw of just the frame.
@@ -51,8 +51,8 @@ static void forceFrameRedraw(GWidgetObject *gw) {
}
#if GINPUT_NEED_MOUSE
- static void FrameMouseDown(GWidgetObject *gw, coord_t x, coord_t y) {
- coord_t pos;
+ static void FrameMouseDown(GWidgetObject *gw, gCoord x, gCoord y) {
+ gCoord pos;
// We must be clicking on the frame button area to be of interest
if (y < FRM_BUTTON_T || y >= FRM_BUTTON_T+FRM_BUTTON_Y)
@@ -86,7 +86,7 @@ static void forceFrameRedraw(GWidgetObject *gw) {
}
}
- static void FrameMouseUp(GWidgetObject *gw, coord_t x, coord_t y) {
+ static void FrameMouseUp(GWidgetObject *gw, gCoord x, gCoord y) {
#if GWIN_BUTTON_LAZY_RELEASE
if ((gw->g.flags & GWIN_FRAME_CLOSE_PRESSED)) {
// Close is released - destroy the window
@@ -118,7 +118,7 @@ static void forceFrameRedraw(GWidgetObject *gw) {
// We must be releasing over the button
if (y >= FRM_BUTTON_T && y < FRM_BUTTON_T+FRM_BUTTON_Y) {
- coord_t pos;
+ gCoord pos;
pos = gw->g.width - (FRM_BORDER_R+FRM_BUTTON_X);
if ((gw->g.flags & GWIN_FRAME_CLOSE_BTN)) {
@@ -229,7 +229,7 @@ GHandle gwinGFrameCreate(GDisplay *g, GFrameObject *fo, GWidgetInit *pInit, uint
void gwinFrameDraw_Transparent(GWidgetObject *gw, void *param) {
const GColorSet *pcol;
- coord_t pos;
+ gCoord pos;
color_t contrast;
color_t btn;
(void)param;
@@ -295,7 +295,7 @@ void gwinFrameDraw_Std(GWidgetObject *gw, void *param) {
#if GDISP_NEED_IMAGE
void gwinFrameDraw_Image(GWidgetObject *gw, void *param) {
#define gi ((gdispImage *)param)
- coord_t x, y, iw, ih, mx, my;
+ gCoord x, y, iw, ih, mx, my;
if (gw->g.vmt != (gwinVMT *)&frameVMT)
return;
diff --git a/src/gwin/gwin_graph.c b/src/gwin/gwin_graph.c
index 217f1755..6c7a6932 100644
--- a/src/gwin/gwin_graph.c
+++ b/src/gwin/gwin_graph.c
@@ -37,7 +37,7 @@ static const gwinVMT graphVMT = {
0, // The after-clear routine
};
-static void pointto(GGraphObject *gg, coord_t x, coord_t y, const GGraphPointStyle *style) {
+static void pointto(GGraphObject *gg, gCoord x, gCoord y, const GGraphPointStyle *style) {
if (style->type == GGRAPH_POINT_NONE)
return;
@@ -66,11 +66,11 @@ static void pointto(GGraphObject *gg, coord_t x, coord_t y, const GGraphPointSty
}
}
-static void lineto(GGraphObject *gg, coord_t x0, coord_t y0, coord_t x1, coord_t y1, const GGraphLineStyle *style) {
- coord_t dy, dx;
- coord_t addx, addy;
- coord_t P, diff, i;
- coord_t run_on, run_off, run;
+static void lineto(GGraphObject *gg, gCoord x0, gCoord y0, gCoord x1, gCoord y1, const GGraphLineStyle *style) {
+ gCoord dy, dx;
+ gCoord addx, addy;
+ gCoord P, diff, i;
+ gCoord run_on, run_off, run;
if (style->type == GGRAPH_LINE_NONE)
return;
@@ -193,7 +193,7 @@ void gwinGraphSetStyle(GHandle gh, const GGraphStyle *pstyle) {
#undef gg
}
-void gwinGraphSetOrigin(GHandle gh, coord_t x, coord_t y) {
+void gwinGraphSetOrigin(GHandle gh, gCoord x, gCoord y) {
#define gg ((GGraphObject *)gh)
if (gh->vmt != &graphVMT)
@@ -207,7 +207,7 @@ void gwinGraphSetOrigin(GHandle gh, coord_t x, coord_t y) {
void gwinGraphDrawAxis(GHandle gh) {
#define gg ((GGraphObject *)gh)
- coord_t i, xmin, ymin, xmax, ymax;
+ gCoord i, xmin, ymin, xmax, ymax;
if (gh->vmt != &graphVMT || !_gwinDrawStart(gh))
return;
@@ -274,7 +274,7 @@ void gwinGraphStartSet(GHandle gh) {
gh->flags &= ~GGRAPH_FLG_CONNECTPOINTS;
}
-void gwinGraphDrawPoint(GHandle gh, coord_t x, coord_t y) {
+void gwinGraphDrawPoint(GHandle gh, gCoord x, gCoord y) {
#define gg ((GGraphObject *)gh)
if (gh->vmt != &graphVMT || !_gwinDrawStart(gh))
diff --git a/src/gwin/gwin_graph.h b/src/gwin/gwin_graph.h
index d13fd1c5..eaaa82ab 100644
--- a/src/gwin/gwin_graph.h
+++ b/src/gwin/gwin_graph.h
@@ -33,7 +33,7 @@ typedef enum GGraphPointType_e {
typedef struct GGraphPointStyle_t {
GGraphPointType type;
- coord_t size;
+ gCoord size;
color_t color;
} GGraphPointStyle;
@@ -43,15 +43,15 @@ typedef enum GGraphLineType_e {
typedef struct GGraphLineStyle_t {
GGraphLineType type;
- coord_t size;
+ gCoord size;
color_t color;
} GGraphLineStyle;
typedef struct GGraphGridStyle_t {
GGraphLineType type;
- coord_t size;
+ gCoord size;
color_t color;
- coord_t spacing;
+ gCoord spacing;
} GGraphGridStyle;
typedef struct GGraphStyle_t {
@@ -77,8 +77,8 @@ typedef struct GGraphStyle_t {
typedef struct GGraphObject {
GWindowObject g;
GGraphStyle style;
- coord_t xorigin, yorigin;
- coord_t lastx, lasty;
+ gCoord xorigin, yorigin;
+ gCoord lastx, lasty;
} GGraphObject;
/*===========================================================================*/
@@ -130,7 +130,7 @@ void gwinGraphSetStyle(GHandle gh, const GGraphStyle *pstyle);
*
* @api
*/
-void gwinGraphSetOrigin(GHandle gh, coord_t x, coord_t y);
+void gwinGraphSetOrigin(GHandle gh, gCoord x, gCoord y);
/**
* @brief Draw the axis and the background grid.
@@ -161,7 +161,7 @@ void gwinGraphStartSet(GHandle gh);
*
* @api
*/
-void gwinGraphDrawPoint(GHandle gh, coord_t x, coord_t y);
+void gwinGraphDrawPoint(GHandle gh, gCoord x, gCoord y);
/**
* @brief Draw multiple graph points.
diff --git a/src/gwin/gwin_image.c b/src/gwin/gwin_image.c
index a4cc5028..73db206e 100644
--- a/src/gwin/gwin_image.c
+++ b/src/gwin/gwin_image.c
@@ -34,7 +34,7 @@ static void ImageDestroy(GWindowObject *gh) {
#endif
static void ImageRedraw(GHandle gh) {
- coord_t x, y, w, h, dx, dy;
+ gCoord x, y, w, h, dx, dy;
color_t bg;
#if GWIN_NEED_IMAGE_ANIMATION
delaytime_t delay;
diff --git a/src/gwin/gwin_keyboard.c b/src/gwin/gwin_keyboard.c
index b8a54e8e..f75c2bee 100644
--- a/src/gwin/gwin_keyboard.c
+++ b/src/gwin/gwin_keyboard.c
@@ -174,7 +174,7 @@ static void SendVirtualKeyEvent(GKeyboardObject *gk) {
#if GINPUT_NEED_MOUSE
// Find the key from the keyset and the x, y position
- static void KeyFindKey(GKeyboardObject *gk, coord_t x, coord_t y) {
+ static void KeyFindKey(GKeyboardObject *gk, gCoord x, gCoord y) {
const utf8 *krow;
fixed f;
int idx;
@@ -210,7 +210,7 @@ static void SendVirtualKeyEvent(GKeyboardObject *gk) {
}
// A mouse up has occurred (it may or may not be over the button)
- static void KeyMouseUp(GWidgetObject *gw, coord_t x, coord_t y) {
+ static void KeyMouseUp(GWidgetObject *gw, gCoord x, gCoord y) {
#define gk ((GKeyboardObject *)gw)
KeyFindKey(gk, x, y);
@@ -281,7 +281,7 @@ static void SendVirtualKeyEvent(GKeyboardObject *gk) {
}
// A mouse move has occurred (it may or may not be over the button)
- static void KeyMouseMove(GWidgetObject *gw, coord_t x, coord_t y) {
+ static void KeyMouseMove(GWidgetObject *gw, gCoord x, gCoord y) {
#define gk ((GKeyboardObject *)gw)
KeyFindKey(gk, x, y);
@@ -392,7 +392,7 @@ void gwinKeyboardDraw_Normal(GWidgetObject *gw, void *param) {
char cap[5];
const char *pcap;
const utf8 *krow;
- coord_t x, y, cx, cy;
+ gCoord x, y, cx, cy;
uint8_t rows, cols, row, col, kcols;
ucode key;
fixed fx, fy;
diff --git a/src/gwin/gwin_keyboard.h b/src/gwin/gwin_keyboard.h
index 0f4185ab..d048453f 100644
--- a/src/gwin/gwin_keyboard.h
+++ b/src/gwin/gwin_keyboard.h
@@ -57,8 +57,8 @@ typedef struct GKeyboardObject {
GWidgetObject w;
const struct GVKeyTable *keytable;
const char **keyset;
- coord_t keyx, keyy;
- coord_t keycx, keycy;
+ gCoord keyx, keyy;
+ gCoord keycx, keycy;
uint8_t lastkeyrow, lastkeycol;
uint8_t keyrow, keycol;
uint32_t key;
diff --git a/src/gwin/gwin_label.c b/src/gwin/gwin_label.c
index b522768a..d8ca1512 100644
--- a/src/gwin/gwin_label.c
+++ b/src/gwin/gwin_label.c
@@ -21,14 +21,14 @@
#define gw2obj ((GLabelObject *)gw)
// simple: single line with no wrapping
-static coord_t getwidth(const char *text, font_t font, coord_t maxwidth) {
+static gCoord getwidth(const char *text, font_t font, gCoord maxwidth) {
(void) maxwidth;
return gdispGetStringWidth(text, font)+2; // Allow one pixel of padding on each side
}
// simple: single line with no wrapping
-static coord_t getheight(const char *text, font_t font, coord_t maxwidth) {
+static gCoord getheight(const char *text, font_t font, gCoord maxwidth) {
(void) text;
(void) maxwidth;
@@ -117,7 +117,7 @@ void gwinLabelSetBorder(GHandle gh, gBool border) {
}
#if GWIN_LABEL_ATTRIBUTE
- void gwinLabelSetAttribute(GHandle gh, coord_t tab, const char* attr) {
+ void gwinLabelSetAttribute(GHandle gh, gCoord tab, const char* attr) {
// is it a valid handle?
if (gh->vmt != (gwinVMT *)&labelVMT)
return;
@@ -130,7 +130,7 @@ void gwinLabelSetBorder(GHandle gh, gBool border) {
#endif // GWIN_LABEL_ATTRIBUTE
static void gwinLabelDraw(GWidgetObject *gw, justify_t justify) {
- coord_t w, h;
+ gCoord w, h;
color_t c;
// is it a valid handle?
diff --git a/src/gwin/gwin_label.h b/src/gwin/gwin_label.h
index 77bf5364..281fb408 100644
--- a/src/gwin/gwin_label.h
+++ b/src/gwin/gwin_label.h
@@ -48,7 +48,7 @@ typedef struct GLabelObject {
GWidgetObject w;
#if GWIN_LABEL_ATTRIBUTE
- coord_t tab;
+ gCoord tab;
const char* attr;
#endif
} GLabelObject;
@@ -102,7 +102,7 @@ void gwinLabelSetBorder(GHandle gh, gBool border);
*
* @api
*/
- void gwinLabelSetAttribute(GHandle gh, coord_t tab, const char* attr);
+ void gwinLabelSetAttribute(GHandle gh, gCoord tab, const char* attr);
#endif
/**
diff --git a/src/gwin/gwin_list.c b/src/gwin/gwin_list.c
index 8b161238..49caefe1 100644
--- a/src/gwin/gwin_list.c
+++ b/src/gwin/gwin_list.c
@@ -54,10 +54,10 @@ static void sendListEvent(GWidgetObject *gw, int item) {
}
#if GINPUT_NEED_MOUSE
- static void ListMouseSelect(GWidgetObject* gw, coord_t x, coord_t y) {
+ static void ListMouseSelect(GWidgetObject* gw, gCoord x, gCoord y) {
const gfxQueueASyncItem* qi;
int item, i;
- coord_t iheight;
+ gCoord iheight;
(void) x;
iheight = gdispGetFontMetric(gw->g.font, fontHeight) + LST_VERT_PAD;
@@ -88,8 +88,8 @@ static void sendListEvent(GWidgetObject *gw, int item) {
}
// a mouse down has occurred over the list area
- static void ListMouseDown(GWidgetObject* gw, coord_t x, coord_t y) {
- coord_t iheight, pgsz;
+ static void ListMouseDown(GWidgetObject* gw, gCoord x, gCoord y) {
+ gCoord iheight, pgsz;
// Save our mouse start position
gw2obj->start_mouse_x = x;
@@ -143,7 +143,7 @@ static void sendListEvent(GWidgetObject *gw, int item) {
ListMouseSelect(gw, x, y);
}
- static void ListMouseUp(GWidgetObject* gw, coord_t x, coord_t y) {
+ static void ListMouseUp(GWidgetObject* gw, gCoord x, gCoord y) {
// Only act when we are a smooth scrolling list
if (!(gw->g.flags & GLIST_FLG_SCROLLSMOOTH))
return;
@@ -155,7 +155,7 @@ static void sendListEvent(GWidgetObject *gw, int item) {
ListMouseSelect(gw, x, y);
}
- static void ListMouseMove(GWidgetObject* gw, coord_t x, coord_t y) {
+ static void ListMouseMove(GWidgetObject* gw, gCoord x, gCoord y) {
int iheight, oldtop;
(void) x;
@@ -184,7 +184,7 @@ static void sendListEvent(GWidgetObject *gw, int item) {
const gfxQueueASyncItem * qix;
int i;
- coord_t iheight;
+ gCoord iheight;
iheight = gdispGetFontMetric(gw->g.font, fontHeight) + LST_VERT_PAD;
switch (role) {
@@ -653,7 +653,7 @@ void gwinListSetSelected(GHandle gh, int item, gBool doSelect) {
}
void gwinListViewItem(GHandle gh, int item) {
- coord_t iheight;
+ gCoord iheight;
// is it a valid handle?
if (gh->vmt != (gwinVMT *)&listVMT)
@@ -703,11 +703,11 @@ void gwinListViewItem(GHandle gh, int item) {
void gwinListDefaultDraw(GWidgetObject* gw, void* param) {
const gfxQueueASyncItem* qi;
int i;
- coord_t x, y, iheight, iwidth;
+ gCoord x, y, iheight, iwidth;
color_t fill;
const GColorSet * ps;
#if GWIN_NEED_LIST_IMAGES
- coord_t sy;
+ gCoord sy;
#endif
#if GDISP_NEED_CONVEX_POLYGON
static const gPoint upArrow[] = { {0, LST_ARROW_SZ}, {LST_ARROW_SZ, LST_ARROW_SZ}, {LST_ARROW_SZ/2, 0} };
diff --git a/src/gwin/gwin_list.h b/src/gwin/gwin_list.h
index 9bd7075d..7c2cd1e7 100644
--- a/src/gwin/gwin_list.h
+++ b/src/gwin/gwin_list.h
@@ -52,9 +52,9 @@ typedef struct GListObject {
GWidgetObject w;
#if GINPUT_NEED_MOUSE
- coord_t start_mouse_x;
- coord_t start_mouse_y;
- coord_t last_mouse_y;
+ gCoord start_mouse_x;
+ gCoord start_mouse_y;
+ gCoord last_mouse_y;
#endif
#if GINPUT_NEED_TOGGLE
uint16_t t_up;
diff --git a/src/gwin/gwin_progressbar.c b/src/gwin/gwin_progressbar.c
index 23d1b4c7..ea3c6482 100644
--- a/src/gwin/gwin_progressbar.c
+++ b/src/gwin/gwin_progressbar.c
@@ -265,7 +265,7 @@ void gwinProgressbarDraw_Image(GWidgetObject *gw, void *param) {
#define gsw ((GProgressbarObject *)gw)
#define gi ((gdispImage *)param)
const GColorSet * pcol;
- coord_t z, v;
+ gCoord z, v;
if (gw->g.vmt != (gwinVMT *)&progressbarVMT)
return;
diff --git a/src/gwin/gwin_progressbar.h b/src/gwin/gwin_progressbar.h
index aa4deb2d..a5af2502 100644
--- a/src/gwin/gwin_progressbar.h
+++ b/src/gwin/gwin_progressbar.h
@@ -26,7 +26,7 @@
// A progressbar window
typedef struct GProgressbarObject {
GWidgetObject w;
- coord_t dpos;
+ gCoord dpos;
int min;
int max;
int res;
diff --git a/src/gwin/gwin_radio.c b/src/gwin/gwin_radio.c
index d3747762..53ca494b 100644
--- a/src/gwin/gwin_radio.c
+++ b/src/gwin/gwin_radio.c
@@ -46,7 +46,7 @@ static void SendRadioEvent(GWidgetObject *gw) {
#if GINPUT_NEED_MOUSE
// A mouse down has occurred over the button
- static void RadioMouseDown(GWidgetObject *gw, coord_t x, coord_t y) {
+ static void RadioMouseDown(GWidgetObject *gw, gCoord x, gCoord y) {
(void) x; (void) y;
gwinRadioPress((GHandle)gw);
@@ -183,7 +183,7 @@ static const GColorSet *getDrawColors(GWidgetObject *gw) {
void gwinRadioDraw_Radio(GWidgetObject *gw, void *param) {
#define gcw ((GRadioObject *)gw)
- coord_t ld, df;
+ gCoord ld, df;
const GColorSet * pcol;
(void) param;
@@ -263,7 +263,7 @@ void gwinRadioDraw_Radio(GWidgetObject *gw, void *param) {
const GColorSet * pcol;
fixed alpha;
fixed dalpha;
- coord_t i;
+ gCoord i;
color_t tcol, bcol;
(void) param;
@@ -288,7 +288,7 @@ void gwinRadioDraw_Radio(GWidgetObject *gw, void *param) {
const GColorSet * pcol;
fixed alpha;
fixed dalpha;
- coord_t i;
+ gCoord i;
color_t tcol, bcol;
(void) param;
diff --git a/src/gwin/gwin_slider.c b/src/gwin/gwin_slider.c
index d3316bc2..467ecfd3 100644
--- a/src/gwin/gwin_slider.c
+++ b/src/gwin/gwin_slider.c
@@ -92,7 +92,7 @@ static void SliderResetDisplayPos(GSliderObject *gsw) {
#if GINPUT_NEED_MOUSE
// Set the display position from the mouse position
- static void SetDisplayPosFromMouse(GSliderObject *gsw, coord_t x, coord_t y) {
+ static void SetDisplayPosFromMouse(GSliderObject *gsw, gCoord x, gCoord y) {
if (gsw->w.g.width < gsw->w.g.height)
gsw->dpos = y < 0 ? 0 : (y >= gsw->w.g.height ? gsw->w.g.height-1 : y);
else
@@ -100,7 +100,7 @@ static void SliderResetDisplayPos(GSliderObject *gsw) {
}
// A mouse up event
- static void SliderMouseUp(GWidgetObject *gw, coord_t x, coord_t y) {
+ static void SliderMouseUp(GWidgetObject *gw, gCoord x, gCoord y) {
#define gsw ((GSliderObject *)gw)
#if !GWIN_BUTTON_LAZY_RELEASE
@@ -144,7 +144,7 @@ static void SliderResetDisplayPos(GSliderObject *gsw) {
}
// A mouse down event
- static void SliderMouseDown(GWidgetObject *gw, coord_t x, coord_t y) {
+ static void SliderMouseDown(GWidgetObject *gw, gCoord x, gCoord y) {
#define gsw ((GSliderObject *)gw)
// Determine the display position
@@ -160,7 +160,7 @@ static void SliderResetDisplayPos(GSliderObject *gsw) {
}
// A mouse move event
- static void SliderMouseMove(GWidgetObject *gw, coord_t x, coord_t y) {
+ static void SliderMouseMove(GWidgetObject *gw, gCoord x, gCoord y) {
#define gsw ((GSliderObject *)gw)
// Determine the display position
@@ -391,7 +391,7 @@ void gwinSliderDraw_Image(GWidgetObject *gw, void *param) {
#define gsw ((GSliderObject *)gw)
#define gi ((gdispImage *)param)
const GColorSet * pcol;
- coord_t z, v;
+ gCoord z, v;
if (gw->g.vmt != (gwinVMT *)&sliderVMT)
return;
diff --git a/src/gwin/gwin_slider.h b/src/gwin/gwin_slider.h
index 588a39e8..fe884287 100644
--- a/src/gwin/gwin_slider.h
+++ b/src/gwin/gwin_slider.h
@@ -63,7 +63,7 @@ typedef struct GSliderObject {
#if GINPUT_NEED_DIAL
uint16_t dial;
#endif
- coord_t dpos;
+ gCoord dpos;
int min;
int max;
int pos;
diff --git a/src/gwin/gwin_tabset.c b/src/gwin/gwin_tabset.c
index 43718391..f3e07eea 100644
--- a/src/gwin/gwin_tabset.c
+++ b/src/gwin/gwin_tabset.c
@@ -45,7 +45,7 @@ static void FixTabSizePos(GHandle gh);
typedef GContainerObject GTabpageObject;
-static coord_t TabpageBorderSize(GHandle gh) { (void)gh; return 0; }
+static gCoord TabpageBorderSize(GHandle gh) { (void)gh; return 0; }
static void gwinTabpageDraw_Std(GWidgetObject *gw, void *param) {
(void)gw;
@@ -121,9 +121,9 @@ void gwinTabsetSetTitle(GHandle gh, const char *title, gBool useAlloc) {
* Tab-set stuff
*/
-static coord_t CalcTabHeight(GHandle gh) {
+static gCoord CalcTabHeight(GHandle gh) {
GHandle ph;
- coord_t x, y, w;
+ gCoord x, y, w;
x = w = 0;
y = GWIN_TABSET_TABHEIGHT;
@@ -141,7 +141,7 @@ static coord_t CalcTabHeight(GHandle gh) {
}
static void FixTabSizePos(GHandle gh) {
- coord_t w, h, oldth;
+ gCoord w, h, oldth;
GHandle vis, ph;
oldth = ((GTabsetObject *)gh)->border_top;
@@ -169,11 +169,11 @@ static void FixTabSizePos(GHandle gh) {
}
}
-static coord_t TabSetBorderSize(GHandle gh) { return (gh->flags & GWIN_TABSET_BORDER) ? GTABSET_BORDER : 0; }
-static coord_t TabSetBorderTop(GHandle gh) { return ((GTabsetObject *)gh)->border_top; }
+static gCoord TabSetBorderSize(GHandle gh) { return (gh->flags & GWIN_TABSET_BORDER) ? GTABSET_BORDER : 0; }
+static gCoord TabSetBorderTop(GHandle gh) { return ((GTabsetObject *)gh)->border_top; }
#if GINPUT_NEED_MOUSE
- static void mouseDown(GWidgetObject *gw, coord_t mx, coord_t my) {
+ static void mouseDown(GWidgetObject *gw, gCoord mx, gCoord my) {
GHandle ph, gh;
int cnt;
@@ -182,7 +182,7 @@ static coord_t TabSetBorderTop(GHandle gh) { return ((GTabsetObject *)gh)->bord
// Work out which tab was pressed
{
- coord_t x, w, y;
+ gCoord x, w, y;
cnt = 0;
x = w = 0;
@@ -395,7 +395,7 @@ void gwinTabsetSetTab(GHandle gh) {
///////////////////////////////////////////////////////////////////////////////////////////////////
#if GWIN_FLAT_STYLING
- static void fgarea(GWidgetObjset *gw, const char *text, coord_t y, coord_t x, coord_t w) {
+ static void fgarea(GWidgetObjset *gw, const char *text, gCoord y, gCoord x, gCoord w) {
const GColorSet * pcol;
pcol = (gw->g.flags & GWIN_FLG_SYSENABLED) ? &gw->pstyle->pressed : &gw->pstyle->disabled;
@@ -403,7 +403,7 @@ void gwinTabsetSetTab(GHandle gh) {
gdispGDrawBox(gw->g.display, gw->g.x+x, gw->g.y+y, w, GWIN_TABSET_TABHEIGHT, pcol->edge);
gdispGFillStringBox(gw->g.display, gw->g.x+x+1, gw->g.y+y+1, w-2, GWIN_TABSET_TABHEIGHT-1, text, gw->g.font, pcol->text, pcol->fill, justifyCenter);
}
- static void bgarea(GWidgetObjset *gw, const char *text, coord_t y, coord_t x, coord_t w) {
+ static void bgarea(GWidgetObjset *gw, const char *text, gCoord y, gCoord x, gCoord w) {
const GColorSet * pcol;
pcol = (gw->g.flags & GWIN_FLG_SYSENABLED) ? &gw->pstyle->enabled : &gw->pstyle->disabled;
@@ -412,7 +412,7 @@ void gwinTabsetSetTab(GHandle gh) {
gdispGDrawLine(gw->g.display, gw->g.x+x+w-1, gw->g.y+y, gw->g.x+x+w-1, gw->g.y+y+GWIN_TABSET_TABHEIGHT-1, pcol->edge);
gdispGDrawLine(gw->g.display, gw->g.x+x, gw->g.y+y+GWIN_TABSET_TABHEIGHT-1, gw->g.x+x+w-2, gw->g.y+y+GWIN_TABSET_TABHEIGHT-1, pcol->edge);
}
- static void ntarea(GWidgetObjset *gw, coord_t y, coord_t x, coord_t w) {
+ static void ntarea(GWidgetObjset *gw, gCoord y, gCoord x, gCoord w) {
const GColorSet * pcol;
pcol = (gw->g.flags & GWIN_FLG_SYSENABLED) ? &gw->pstyle->pressed : &gw->pstyle->disabled;
@@ -421,7 +421,7 @@ void gwinTabsetSetTab(GHandle gh) {
gdispGDrawLine(gw->g.display, gw->g.x+x, gw->g.y+y+GWIN_TABSET_TABHEIGHT-1, gw->g.x+x+w-1, gw->g.y+y+GWIN_TABSET_TABHEIGHT-1, pcol->edge);
}
#else
- static void fgarea(GWidgetObject *gw, const char *text, coord_t y, coord_t x, coord_t w) {
+ static void fgarea(GWidgetObject *gw, const char *text, gCoord y, gCoord x, gCoord w) {
const GColorSet * pcol;
color_t tcol;
@@ -435,10 +435,10 @@ void gwinTabsetSetTab(GHandle gh) {
if (!x)
gdispGDrawLine(gw->g.display, gw->g.x, gw->g.y+y, gw->g.x, gw->g.y+y+GWIN_TABSET_TABHEIGHT-1, tcol);
}
- static void bgarea(GWidgetObject *gw, const char *text, coord_t y, coord_t x, coord_t w) {
+ static void bgarea(GWidgetObject *gw, const char *text, gCoord y, gCoord x, gCoord w) {
const GColorSet * pcol;
fixed alpha;
- coord_t i;
+ gCoord i;
color_t tcol, bcol;
pcol = (gw->g.flags & GWIN_FLG_SYSENABLED) ? &gw->pstyle->enabled : &gw->pstyle->disabled;
@@ -451,7 +451,7 @@ void gwinTabsetSetTab(GHandle gh) {
gdispGDrawLine(gw->g.display, gw->g.x+x+w-1, gw->g.y+y, gw->g.x+x+w-1, gw->g.y+y+GWIN_TABSET_TABHEIGHT-1, pcol->edge);
gdispGDrawStringBox(gw->g.display, gw->g.x+x+1, gw->g.y+y+1, w-2, GWIN_TABSET_TABHEIGHT-2, text, gw->g.font, pcol->text, justifyCenter);
}
- static void ntarea(GWidgetObject *gw, coord_t y, coord_t x, coord_t w) {
+ static void ntarea(GWidgetObject *gw, gCoord y, gCoord x, gCoord w) {
const GColorSet * pcol;
pcol = (gw->g.flags & GWIN_FLG_SYSENABLED) ? &gw->pstyle->pressed : &gw->pstyle->disabled;
@@ -461,9 +461,9 @@ void gwinTabsetSetTab(GHandle gh) {
}
#endif
-static coord_t drawtabs(GWidgetObject *gw) {
+static gCoord drawtabs(GWidgetObject *gw) {
GHandle ph;
- coord_t x, y, w;
+ gCoord x, y, w;
x = w = 0;
y = 0;
@@ -487,10 +487,10 @@ static coord_t drawtabs(GWidgetObject *gw) {
return y + GWIN_TABSET_TABHEIGHT;
}
-static void drawborder(GWidgetObject *gw, coord_t y) {
+static void drawborder(GWidgetObject *gw, gCoord y) {
if ((gw->g.flags & GWIN_CONTAINER_BORDER)) {
const GColorSet * pcol;
- coord_t x, w;
+ gCoord x, w;
pcol = (gw->g.flags & GWIN_FLG_SYSENABLED) ? &gw->pstyle->enabled : &gw->pstyle->disabled;
x = gw->g.x+gw->g.width-1;
@@ -513,7 +513,7 @@ void gwinTabsetDraw_Transparent(GWidgetObject *gw, void *param) {
}
void gwinTabsetDraw_Std(GWidgetObject *gw, void *param) {
- coord_t y;
+ gCoord y;
(void) param;
if (gw->g.vmt != (gwinVMT *)&tabsetVMT)
@@ -533,7 +533,7 @@ void gwinTabsetDraw_Std(GWidgetObject *gw, void *param) {
#if GDISP_NEED_IMAGE
void gwinTabsetDraw_Image(GWidgetObject *gw, void *param) {
#define gi ((gdispImage *)param)
- coord_t x, y, iw, ih, mx, my;
+ gCoord x, y, iw, ih, mx, my;
if (gw->g.vmt != (gwinVMT *)&tabsetVMT)
return;
diff --git a/src/gwin/gwin_tabset.h b/src/gwin/gwin_tabset.h
index 8c07c7d2..0a2a1496 100644
--- a/src/gwin/gwin_tabset.h
+++ b/src/gwin/gwin_tabset.h
@@ -57,7 +57,7 @@ typedef struct GEventGWinTabset {
typedef struct GTabsetObject {
GContainerObject c;
- coord_t border_top;
+ gCoord border_top;
} GTabsetObject;
/**
diff --git a/src/gwin/gwin_textedit.c b/src/gwin/gwin_textedit.c
index 1cc168f1..098c91ca 100644
--- a/src/gwin/gwin_textedit.c
+++ b/src/gwin/gwin_textedit.c
@@ -87,7 +87,7 @@ static gBool TextEditAddChars(GHandle gh, unsigned cnt) {
// slow. An optimized version would copy the behavior of mf_get_string_width()
// and do the comparation directly inside of that loop so we only iterate
// the string once.
-static void TextEditMouseDown(GWidgetObject* gw, coord_t x, coord_t y) {
+static void TextEditMouseDown(GWidgetObject* gw, gCoord x, gCoord y) {
uint16_t i = 0;
(void)y;
@@ -269,7 +269,7 @@ GHandle gwinGTexteditCreate(GDisplay* g, GTexteditObject* wt, GWidgetInit* pInit
void gwinTexteditDefaultDraw(GWidgetObject* gw, void* param)
{
const char* p;
- coord_t cpos, tpos;
+ gCoord cpos, tpos;
const GColorSet* pcol;
(void)param;
diff --git a/src/gwin/gwin_widget.c b/src/gwin/gwin_widget.c
index d4865935..cc5bf1a1 100644
--- a/src/gwin/gwin_widget.c
+++ b/src/gwin/gwin_widget.c
@@ -317,8 +317,8 @@ static void gwidgetEvent(void *param, GEvent *pe) {
_widgetInFocus = 0;
}
- void _gwidgetDrawFocusRect(GWidgetObject *gx, coord_t x, coord_t y, coord_t cx, coord_t cy) {
- coord_t i;
+ void _gwidgetDrawFocusRect(GWidgetObject *gx, gCoord x, gCoord y, gCoord cx, gCoord cy) {
+ gCoord i;
// Don't do anything if we don't have the focus
if (&gx->g != _widgetInFocus)
@@ -331,8 +331,8 @@ static void gwidgetEvent(void *param, GEvent *pe) {
}
#if GDISP_NEED_CIRCLE
- void _gwidgetDrawFocusCircle(GWidgetObject *gx, coord_t radius) {
- coord_t i;
+ void _gwidgetDrawFocusCircle(GWidgetObject *gx, gCoord radius) {
+ gCoord i;
// Don't do anything if we don't have the focus
if (&gx->g != _widgetInFocus)
diff --git a/src/gwin/gwin_wm.c b/src/gwin/gwin_wm.c
index 6761180f..2c9f25d9 100644
--- a/src/gwin/gwin_wm.c
+++ b/src/gwin/gwin_wm.c
@@ -125,7 +125,7 @@
}
}
- void gwinMove(GHandle gh, coord_t x, coord_t y) {
+ void gwinMove(GHandle gh, gCoord x, gCoord y) {
gh->x = x; gh->y = y;
if (gh->x < 0) gh->x = 0;
if (gh->y < 0) gh->y = 0;
@@ -136,7 +136,7 @@
_gwinUpdate(gh);
}
- void gwinResize(GHandle gh, coord_t width, coord_t height) {
+ void gwinResize(GHandle gh, gCoord width, gCoord height) {
gh->width = width; gh->height = height;
if (gh->width < MIN_WIN_WIDTH) { gh->width = MIN_WIN_WIDTH; }
if (gh->height < MIN_WIN_HEIGHT) { gh->height = MIN_WIN_HEIGHT; }
@@ -553,11 +553,11 @@ void gwinRedraw(GHandle gh) {
}
#endif
-void gwinMove(GHandle gh, coord_t x, coord_t y) {
+void gwinMove(GHandle gh, gCoord x, gCoord y) {
_GWINwm->vmt->Move(gh, x, y);
}
-void gwinResize(GHandle gh, coord_t width, coord_t height) {
+void gwinResize(GHandle gh, gCoord width, gCoord height) {
_GWINwm->vmt->Size(gh, width, height);
}
@@ -691,8 +691,8 @@ static void WM_DeInit(void);
static gBool WM_Add(GHandle gh, const GWindowInit *pInit);
static void WM_Delete(GHandle gh);
static void WM_Redraw(GHandle gh);
-static void WM_Size(GHandle gh, coord_t w, coord_t h);
-static void WM_Move(GHandle gh, coord_t x, coord_t y);
+static void WM_Size(GHandle gh, gCoord w, gCoord h);
+static void WM_Move(GHandle gh, gCoord x, gCoord y);
static void WM_Raise(GHandle gh);
static void WM_MinMax(GHandle gh, GWindowMinMax minmax);
@@ -823,8 +823,8 @@ static void WM_Redraw(GHandle gh) {
}
}
-static void WM_Size(GHandle gh, coord_t w, coord_t h) {
- coord_t v;
+static void WM_Size(GHandle gh, gCoord w, gCoord h) {
+ gCoord v;
#if GWIN_NEED_CONTAINERS
if (gh->parent) {
@@ -896,8 +896,8 @@ static void WM_Size(GHandle gh, coord_t w, coord_t h) {
}
}
-static void WM_Move(GHandle gh, coord_t x, coord_t y) {
- coord_t u, v;
+static void WM_Move(GHandle gh, gCoord x, gCoord y) {
+ gCoord u, v;
#if GWIN_NEED_CONTAINERS
if (gh->parent) {