2020-03-29 17:34:08 +00:00
|
|
|
#ifndef __qwaq_ui_rect_h
|
|
|
|
#define __qwaq_ui_rect_h
|
2020-03-01 09:25:02 +00:00
|
|
|
|
2020-03-23 11:14:32 +00:00
|
|
|
typedef struct Point_s {
|
2020-03-01 09:25:02 +00:00
|
|
|
int x;
|
|
|
|
int y;
|
|
|
|
} Point;
|
|
|
|
|
2020-03-23 11:14:32 +00:00
|
|
|
typedef struct Extent_s {
|
2020-03-05 06:44:53 +00:00
|
|
|
int width;
|
|
|
|
int height;
|
|
|
|
} Extent;
|
|
|
|
|
|
|
|
typedef struct Rect_s {
|
|
|
|
Point offset;
|
|
|
|
Extent extent;
|
|
|
|
} Rect;
|
|
|
|
|
2020-03-06 04:54:46 +00:00
|
|
|
#ifdef __QFCC__
|
2020-03-27 09:17:24 +00:00
|
|
|
Rect makeRect (int xpos, int ypos, int xlen, int ylen);
|
|
|
|
Point makePoint (int x, int y);
|
|
|
|
Extent makeExtent (int width, int height);
|
|
|
|
Extent mergeExtents (Extent a, Extent b);
|
|
|
|
int rectContainsPoint (Rect rect, Point point);
|
|
|
|
Rect clipRect (Rect clipRect, Rect rect);
|
2020-03-06 04:54:46 +00:00
|
|
|
#endif
|
2020-03-01 09:25:02 +00:00
|
|
|
|
2020-03-29 17:34:08 +00:00
|
|
|
#endif//__qwaq_ui_rect_h
|