diff options
author | Bent Bisballe Nyeng <deva@aasimon.org> | 2013-03-30 17:44:20 +0100 |
---|---|---|
committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2013-03-30 17:44:20 +0100 |
commit | 4b7414b3f6869f2bdeb097e4f997498bae9f0aee (patch) | |
tree | 53e9741d7d40f1ff6f77d47fc308b18168dca330 /plugingui/painter.h | |
parent | a1fba9ba11a13f94c524f2ac78206b3fdfb3be74 (diff) |
New box rendering of all widgets. Minor tweaks still missing.
Diffstat (limited to 'plugingui/painter.h')
-rw-r--r-- | plugingui/painter.h | 24 |
1 files changed, 8 insertions, 16 deletions
diff --git a/plugingui/painter.h b/plugingui/painter.h index 02b8aba..6d5c297 100644 --- a/plugingui/painter.h +++ b/plugingui/painter.h @@ -37,20 +37,6 @@ namespace GUI { -struct __img__ { - size_t width; - size_t height; - unsigned int pixels[128000]; - unsigned int order; -}; -/* -struct __img__ { - size_t width; - size_t height; - unsigned int *pixels; - unsigned int order; -}; -*/ class Painter { public: Painter(Widget *widget); @@ -67,10 +53,9 @@ public: void drawPoint(int x, int y); void drawCircle(int x, int y, double r); void drawFilledCircle(int x, int y, int r); - void drawImage(int x, int y, struct __img__ * img); void drawImage(int x, int y, Image *image); void drawImageStretched(int x0, int y0, GUI::Image *image, - size_t width, size_t height); + int width, int height); typedef struct { Image *topLeft; @@ -85,6 +70,13 @@ public: } Box; void drawBox(int x, int y, Box *box, int width, int height); + typedef struct { + Image *left; + Image *right; + Image *center; + } Bar; + void drawBar(int x, int y, Bar *bar, int width, int height); + void clear(); private: |