aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--demos/modules/gdisp/gdisp_images/main.c2
-rw-r--r--demos/modules/gdisp/gdisp_images/test-pal8.h587
-rw-r--r--demos/modules/gdisp/gdisp_images_animated/main.c2
-rw-r--r--demos/modules/ginput/touch_driver_test/main.c118
-rw-r--r--demos/modules/gwin/basic/main.c14
-rw-r--r--demos/modules/gwin/console/main.c41
-rw-r--r--demos/modules/gwin/slider/gfxconf.h84
-rw-r--r--demos/modules/gwin/slider/main.c97
-rw-r--r--demos/modules/gwin/slider/readme.txt6
-rw-r--r--demos/modules/gwin/slider/result_647x490.pngbin24141 -> 0 bytes
-rw-r--r--demos/modules/gwin/widgets/main.c352
-rw-r--r--demos/modules/gwin/widgets/readme.txt4
-rw-r--r--include/gdisp/gdisp.h1
-rw-r--r--include/gwin/button.h40
-rw-r--r--include/gwin/checkbox.h30
-rw-r--r--include/gwin/class_gwin.h5
-rw-r--r--include/gwin/console.h10
-rw-r--r--include/gwin/graph.h4
-rw-r--r--include/gwin/gwidget.h124
-rw-r--r--include/gwin/gwin.h83
-rw-r--r--include/gwin/image.h16
-rw-r--r--include/gwin/label.h6
-rw-r--r--include/gwin/radio.h41
-rw-r--r--include/gwin/slider.h36
-rw-r--r--src/gdisp/gdisp.c4
-rw-r--r--src/gwin/button.c150
-rw-r--r--src/gwin/checkbox.c76
-rw-r--r--src/gwin/console.c4
-rw-r--r--src/gwin/gimage.c8
-rw-r--r--src/gwin/graph.c2
-rw-r--r--src/gwin/gwidget.c138
-rw-r--r--src/gwin/gwin.c74
-rw-r--r--src/gwin/gwm.c41
-rw-r--r--src/gwin/label.c26
-rw-r--r--src/gwin/radio.c111
-rw-r--r--src/gwin/slider.c90
36 files changed, 1500 insertions, 927 deletions
diff --git a/demos/modules/gdisp/gdisp_images/main.c b/demos/modules/gdisp/gdisp_images/main.c
index e5b55a3a..c581f942 100644
--- a/demos/modules/gdisp/gdisp_images/main.c
+++ b/demos/modules/gdisp/gdisp_images/main.c
@@ -30,7 +30,7 @@
#include "gfx.h"
#ifdef WIN32
- #define USE_MEMORY_FILE FALSE // Can be true or false for Win32
+ #define USE_MEMORY_FILE TRUE // Can be true or false for Win32
#else
#define USE_MEMORY_FILE TRUE // Non-Win32 - use the compiled in image
#endif
diff --git a/demos/modules/gdisp/gdisp_images/test-pal8.h b/demos/modules/gdisp/gdisp_images/test-pal8.h
new file mode 100644
index 00000000..9d1d7e0f
--- /dev/null
+++ b/demos/modules/gdisp/gdisp_images/test-pal8.h
@@ -0,0 +1,587 @@
+/**
+ * This file was generated from "test-pal8.bmp" using...
+ *
+ * file2c -cs test-pal8.bmp test-pal8.h
+ *
+ */
+static const unsigned char test_pal8[] = {
+ 0x42, 0x4D, 0x26, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x26, 0x04, 0x00, 0x00, 0x28, 0x00,
+ 0x00, 0x00, 0x7F, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x01, 0x00, 0x08, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x13, 0x0B, 0x00, 0x00, 0x13, 0x0B, 0x00, 0x00, 0xFC, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x33, 0x00, 0x00, 0x00,
+ 0x66, 0x00, 0x00, 0x00, 0x99, 0x00, 0x00, 0x00, 0xCC, 0x00, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x2B,
+ 0x00, 0x00, 0x00, 0x2B, 0x33, 0x00, 0x00, 0x2B, 0x66, 0x00, 0x00, 0x2B, 0x99, 0x00, 0x00, 0x2B,
+ 0xCC, 0x00, 0x00, 0x2B, 0xFF, 0x00, 0x00, 0x55, 0x00, 0x00, 0x00, 0x55, 0x33, 0x00, 0x00, 0x55,
+ 0x66, 0x00, 0x00, 0x55, 0x99, 0x00, 0x00, 0x55, 0xCC, 0x00, 0x00, 0x55, 0xFF, 0x00, 0x00, 0x80,
+ 0x00, 0x00, 0x00, 0x80, 0x33, 0x00, 0x00, 0x80, 0x66, 0x00, 0x00, 0x80, 0x99, 0x00, 0x00, 0x80,
+ 0xCC, 0x00, 0x00, 0x80, 0xFF, 0x00, 0x00, 0xAA, 0x00, 0x00, 0x00, 0xAA, 0x33, 0x00, 0x00, 0xAA,
+ 0x66, 0x00, 0x00, 0xAA, 0x99, 0x00, 0x00, 0xAA, 0xCC, 0x00, 0x00, 0xAA, 0xFF, 0x00, 0x00, 0xD5,
+ 0x00, 0x00, 0x00, 0xD5, 0x33, 0x00, 0x00, 0xD5, 0x66, 0x00, 0x00, 0xD5, 0x99, 0x00, 0x00, 0xD5,
+ 0xCC, 0x00, 0x00, 0xD5, 0xFF, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x00, 0xFF, 0x33, 0x00, 0x00, 0xFF,
+ 0x66, 0x00, 0x00, 0xFF, 0x99, 0x00, 0x00, 0xFF, 0xCC, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x33, 0x00,
+ 0x00, 0x00, 0x33, 0x00, 0x33, 0x00, 0x33, 0x00, 0x66, 0x00, 0x33, 0x00, 0x99, 0x00, 0x33, 0x00,
+ 0xCC, 0x00, 0x33, 0x00, 0xFF, 0x00, 0x33, 0x2B, 0x00, 0x00, 0x33, 0x2B, 0x33, 0x00, 0x33, 0x2B,
+ 0x66, 0x00, 0x33, 0x2B, 0x99, 0x00, 0x33, 0x2B, 0xCC, 0x00, 0x33, 0x2B, 0xFF, 0x00, 0x33, 0x55,
+ 0x00, 0x00, 0x33, 0x55, 0x33, 0x00, 0x33, 0x55, 0x66, 0x00, 0x33, 0x55, 0x99, 0x00, 0x33, 0x55,
+ 0xCC, 0x00, 0x33, 0x55, 0xFF, 0x00, 0x33, 0x80, 0x00, 0x00, 0x33, 0x80, 0x33, 0x00, 0x33, 0x80,
+ 0x66, 0x00, 0x33, 0x80, 0x99, 0x00, 0x33, 0x80, 0xCC, 0x00, 0x33, 0x80, 0xFF, 0x00, 0x33, 0xAA,
+ 0x00, 0x00, 0x33, 0xAA, 0x33, 0x00, 0x33, 0xAA, 0x66, 0x00, 0x33, 0xAA, 0x99, 0x00, 0x33, 0xAA,
+ 0xCC, 0x00, 0x33, 0xAA, 0xFF, 0x00, 0x33, 0xD5, 0x00, 0x00, 0x33, 0xD5, 0x33, 0x00, 0x33, 0xD5,
+ 0x66, 0x00, 0x33, 0xD5, 0x99, 0x00, 0x33, 0xD5, 0xCC, 0x00, 0x33, 0xD5, 0xFF, 0x00, 0x33, 0xFF,
+ 0x00, 0x00, 0x33, 0xFF, 0x33, 0x00, 0x33, 0xFF, 0x66, 0x00, 0x33, 0xFF, 0x99, 0x00, 0x33, 0xFF,
+ 0xCC, 0x00, 0x33, 0xFF, 0xFF, 0x00, 0x66, 0x00, 0x00, 0x00, 0x66, 0x00, 0x33, 0x00, 0x66, 0x00,
+ 0x66, 0x00, 0x66, 0x00, 0x99, 0x00, 0x66, 0x00, 0xCC, 0x00, 0x66, 0x00, 0xFF, 0x00, 0x66, 0x2B,
+ 0x00, 0x00, 0x66, 0x2B, 0x33, 0x00, 0x66, 0x2B, 0x66, 0x00, 0x66, 0x2B, 0x99, 0x00, 0x66, 0x2B,
+ 0xCC, 0x00, 0x66, 0x2B, 0xFF, 0x00, 0x66, 0x55, 0x00, 0x00, 0x66, 0x55, 0x33, 0x00, 0x66, 0x55,
+ 0x66, 0x00, 0x66, 0x55, 0x99, 0x00, 0x66, 0x55, 0xCC, 0x00, 0x66, 0x55, 0xFF, 0x00, 0x66, 0x80,
+ 0x00, 0x00, 0x66, 0x80, 0x33, 0x00, 0x66, 0x80, 0x66, 0x00, 0x66, 0x80, 0x99, 0x00, 0x66, 0x80,
+ 0xCC, 0x00, 0x66, 0x80, 0xFF, 0x00, 0x66, 0xAA, 0x00, 0x00, 0x66, 0xAA, 0x33, 0x00, 0x66, 0xAA,
+ 0x66, 0x00, 0x66, 0xAA, 0x99, 0x00, 0x66, 0xAA, 0xCC, 0x00, 0x66, 0xAA, 0xFF, 0x00, 0x66, 0xD5,
+ 0x00, 0x00, 0x66, 0xD5, 0x33, 0x00, 0x66, 0xD5, 0x66, 0x00, 0x66, 0xD5, 0x99, 0x00, 0x66, 0xD5,
+ 0xCC, 0x00, 0x66, 0xD5, 0xFF, 0x00, 0x66, 0xFF, 0x00, 0x00, 0x66, 0xFF, 0x33, 0x00, 0x66, 0xFF,
+ 0x66, 0x00, 0x66, 0xFF, 0x99, 0x00, 0x66, 0xFF, 0xCC, 0x00, 0x66, 0xFF, 0xFF, 0x00, 0x99, 0x00,
+ 0x00, 0x00, 0x99, 0x00, 0x33, 0x00, 0x99, 0x00, 0x66, 0x00, 0x99, 0x00, 0x99, 0x00, 0x99, 0x00,
+ 0xCC, 0x00, 0x99, 0x00, 0xFF, 0x00, 0x99, 0x2B, 0x00, 0x00, 0x99, 0x2B, 0x33, 0x00, 0x99, 0x2B,
+ 0x66, 0x00, 0x99, 0x2B, 0x99, 0x00, 0x99, 0x2B, 0xCC, 0x00, 0x99, 0x2B, 0xFF, 0x00, 0x99, 0x55,
+ 0x00, 0x00, 0x99, 0x55, 0x33, 0x00, 0x99, 0x55, 0x66, 0x00, 0x99, 0x55, 0x99, 0x00, 0x99, 0x55,
+ 0xCC, 0x00, 0x99, 0x55, 0xFF, 0x00, 0x99, 0x80, 0x00, 0x00, 0x99, 0x80, 0x33, 0x00, 0x99, 0x80,
+ 0x66, 0x00, 0x99, 0x80, 0x99, 0x00, 0x99, 0x80, 0xCC, 0x00, 0x99, 0x80, 0xFF, 0x00, 0x99, 0xAA,
+ 0x00, 0x00, 0x99, 0xAA, 0x33, 0x00, 0x99, 0xAA, 0x66, 0x00, 0x99, 0xAA, 0x99, 0x00, 0x99, 0xAA,
+ 0xCC, 0x00, 0x99, 0xAA, 0xFF, 0x00, 0x99, 0xD5, 0x00, 0x00, 0x99, 0xD5, 0x33, 0x00, 0x99, 0xD5,
+ 0x66, 0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x99, 0x00, 0xFF, 0xFF,
+ 0xCC, 0x00, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x30, 0x30, 0x30, 0x30, 0x36,
+ 0x36, 0x60, 0x60, 0x66, 0x66, 0x90, 0x66, 0x90, 0x90, 0x96, 0x96, 0x96, 0x96, 0xC6, 0xC0, 0xC6,
+ 0xC6, 0xC6, 0xC6, 0xF6, 0xF6, 0xF6, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2B, 0x2B, 0x2B, 0x2B, 0x2B,
+ 0x2B, 0x56, 0x56, 0x56, 0x56, 0x81, 0x56, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0xAC, 0xAC, 0xAC,
+ 0xAC, 0xAC, 0xAC, 0xD7, 0xD7, 0xD7, 0x00, 0x00, 0x00, 0x06, 0x00, 0x07, 0x07, 0x07, 0x07, 0x0D,
+ 0x0D, 0x0E, 0x0E, 0x14, 0x14, 0x15, 0x14, 0x15, 0x15, 0x1B, 0x1B, 0x1B, 0x1B, 0x22, 0x1C, 0x22,
+ 0x22, 0x22, 0x22, 0x29, 0x29, 0x29, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62,
+ 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62,
+ 0x62, 0x62, 0x62, 0x62, 0x62, 0x00, 0x00, 0x00, 0x30, 0x00, 0x30, 0x06, 0x36, 0x30, 0x60, 0x30,
+ 0x60, 0x36, 0x66, 0x60, 0x90, 0x66, 0x90, 0x66, 0x96, 0x90, 0xC0, 0x96, 0xC6, 0x96, 0xC6, 0xC0,
+ 0xF0, 0xC6, 0xF6, 0xC6, 0xF6, 0xF6, 0x00, 0x00, 0x2B, 0x00, 0x2B, 0x00, 0x2B, 0x2B, 0x56, 0x2B,
+ 0x56, 0x2B, 0x56, 0x56, 0x81, 0x56, 0x81, 0x56, 0x81, 0x81, 0xAC, 0x81, 0xAC, 0x81, 0xAC, 0xAC,
+ 0xD7, 0xAC, 0xD7, 0xAC, 0xD7, 0xD7, 0x00, 0x00, 0x07, 0x00, 0x07, 0x06, 0x0D, 0x07, 0x0E, 0x07,
+ 0x0E, 0x0D, 0x14, 0x0E, 0x15, 0x14, 0x15, 0x14, 0x1B, 0x15, 0x1C, 0x1B, 0x22, 0x1B, 0x22, 0x1C,
+ 0x23, 0x22, 0x29, 0x22, 0x29, 0x29, 0x68, 0x37, 0x68, 0x62, 0x68, 0x61, 0x68, 0x62, 0x68, 0x61,
+ 0x68, 0x62, 0x68, 0x61, 0x92, 0x62, 0x92, 0x61, 0x92, 0x62, 0x92, 0x61, 0x92, 0x62, 0x92, 0x61,
+ 0x92, 0x62, 0x92, 0x61, 0x92, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x30, 0x30, 0x30, 0x30, 0x60,
+ 0x36, 0x60, 0x60, 0x66, 0x60, 0x66, 0x66, 0x90, 0x90, 0x96, 0x96, 0xC0, 0x96, 0xC0, 0xC6, 0xC6,
+ 0xC6, 0xC6, 0xC6, 0xF6, 0xF6, 0xF6, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2B, 0x2B, 0x2B, 0x2B, 0x56,
+ 0x2B, 0x56, 0x56, 0x56, 0x56, 0x56, 0x56, 0x81, 0x81, 0x81, 0x81, 0xAC, 0x81, 0xAC, 0xAC, 0xAC,
+ 0xAC, 0xAC, 0xAC, 0xD7, 0xD7, 0xD7, 0x00, 0x00, 0x00, 0x00, 0x06, 0x07, 0x07, 0x07, 0x07, 0x0E,
+ 0x0D, 0x0E, 0x0E, 0x14, 0x0E, 0x14, 0x14, 0x15, 0x15, 0x1B, 0x1B, 0x1C, 0x1B, 0x1C, 0x22, 0x22,
+ 0x22, 0x22, 0x22, 0x29, 0x29, 0x29, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62,
+ 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x8C, 0x62, 0x62, 0x62, 0x8C,
+ 0x62, 0x62, 0x62, 0x8C, 0x62, 0x00, 0x01, 0x00, 0x06, 0x00, 0x31, 0x06, 0x30, 0x30, 0x61, 0x30,
+ 0x60, 0x36, 0x67, 0x60, 0x66, 0x60, 0x97, 0x66, 0x96, 0x90, 0xC1, 0x96, 0xC6, 0x96, 0xC7, 0xC6,
+ 0xC6, 0xC6, 0xF7, 0xC6, 0xF6, 0xF6, 0x06, 0x00, 0x00, 0x00, 0x31, 0x00, 0x2B, 0x2B, 0x5C, 0x2B,
+ 0x56, 0x2B, 0x5C, 0x56, 0x56, 0x56, 0x87, 0x56, 0x81, 0x81, 0xB2, 0x81, 0xAC, 0x81, 0xB2, 0xAC,
+ 0xAC, 0xAC, 0xDD, 0xAC, 0xD7, 0xD7, 0x2A, 0x00, 0x06, 0x00, 0x31, 0x06, 0x07, 0x07, 0x38, 0x07,
+ 0x0E, 0x0D, 0x3E, 0x0E, 0x14, 0x0E, 0x45, 0x14, 0x1B, 0x15, 0x46, 0x1B, 0x22, 0x1B, 0x4C, 0x22,
+ 0x22, 0x22, 0x53, 0x22, 0x29, 0x29, 0x68, 0x62, 0x68, 0x61, 0x68, 0x62, 0x68, 0x61, 0x92, 0x62,
+ 0x68, 0x61, 0x92, 0x62, 0x68, 0x61, 0x92, 0x62, 0x92, 0x61, 0x92, 0x62, 0x92, 0x61, 0x92, 0x62,
+ 0x92, 0x61, 0x92, 0x62, 0x92, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x30, 0x30, 0x30, 0x30, 0x36,
+ 0x36, 0x60, 0x60, 0x66, 0x66, 0x66, 0x66, 0x90, 0x90, 0x96, 0x96, 0x96, 0x96, 0xC6, 0xC0, 0xC6,
+ 0xC6, 0xF0, 0xC6, 0xF6, 0xF6, 0xF6, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2B, 0x2B, 0x2B, 0x2B, 0x2B,
+ 0x2B, 0x56, 0x56, 0x56, 0x56, 0x56, 0x56, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0xAC, 0xAC, 0xAC,
+ 0xAC, 0xD7, 0xAC, 0xD7, 0xD7, 0xD7, 0x00, 0x00, 0x00, 0x06, 0x00, 0x07, 0x07, 0x07, 0x07, 0x0D,
+ 0x0D, 0x0E, 0x0E, 0x14, 0x14, 0x14, 0x14, 0x15, 0x15, 0x1B, 0x1B, 0x1B, 0x1B, 0x22, 0x1C, 0x22,
+ 0x22, 0x23, 0x22, 0x29, 0x29, 0x29, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62,
+ 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x62, 0x8C,
+ 0x62, 0x8C, 0x62, 0x8C, 0x62, 0x00, 0x01, 0x00, 0x31, 0x00, 0x31, 0x06, 0x31, 0x30, 0x61, 0x30,
+ 0x61, 0x36, 0x67, 0x60, 0x91, 0x66, 0x91, 0x66, 0x97, 0x90, 0xC1, 0x96, 0xC7, 0x96, 0xC7, 0xC0,
+ 0xF1, 0xC6, 0xF7, 0xC6, 0xF7, 0xF6, 0x06, 0x00, 0x31, 0x00, 0x31, 0x00, 0x31, 0x2B, 0x5C, 0x2B,
+ 0x5C, 0x2B, 0x5C, 0x56, 0x87, 0x56, 0x87, 0x56, 0x87, 0x81, 0xB2, 0x81, 0xB2, 0x81, 0xB2, 0xAC,
+ 0xDD, 0xAC, 0xDD, 0xAC, 0xDD, 0xD7, 0x2A, 0x00, 0x31, 0x00, 0x31, 0x06, 0x31, 0x07, 0x38, 0x07,
+ 0x38, 0x0D, 0x3E, 0x0E, 0x3F, 0x14, 0x3F, 0x14, 0x45, 0x15, 0x46, 0x1B, 0x4C, 0x1B, 0x4C, 0x1C,
+ 0x4D, 0x22, 0x53, 0x22, 0x53, 0x29, 0x68, 0x62, 0x68, 0x62, 0x68, 0x62, 0x68, 0x62, 0x68, 0x62,
+ 0x92, 0x62, 0x68, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62,
+ 0x92, 0x62, 0x92, 0x62, 0x92, 0x00, 0x00, 0x01, 0x00, 0x00, 0x06, 0x30, 0x30, 0x30, 0x30, 0x61,
+ 0x36, 0x60, 0x60, 0x66, 0x60, 0x66, 0x90, 0x91, 0x90, 0x96, 0x96, 0xC0, 0x96, 0xC0, 0xC6, 0xC7,
+ 0xC6, 0xC6, 0xC6, 0xF6, 0xF6, 0xF6, 0x00, 0x06, 0x00, 0x00, 0x00, 0x31, 0x2B, 0x2B, 0x2B, 0x5C,
+ 0x2B, 0x56, 0x56, 0x5C, 0x56, 0x56, 0x81, 0x87, 0x81, 0x81, 0x81, 0xB2, 0x81, 0xAC, 0xAC, 0xB2,
+ 0xAC, 0xAC, 0xAC, 0xDD, 0xD7, 0xD7, 0x00, 0x2A, 0x00, 0x00, 0x06, 0x07, 0x07, 0x07, 0x07, 0x38,
+ 0x0D, 0x0E, 0x0E, 0x14, 0x0E, 0x14, 0x15, 0x3F, 0x15, 0x1B, 0x1B, 0x1C, 0x1B, 0x1C, 0x22, 0x4C,
+ 0x22, 0x22, 0x22, 0x29, 0x29, 0x29, 0x62, 0x68, 0x62, 0x62, 0x62, 0x68, 0x62, 0x62, 0x62, 0x68,
+ 0x62, 0x62, 0x62, 0x68, 0x62, 0x62, 0x62, 0x92, 0x62, 0x62, 0x62, 0x92, 0x62, 0x62, 0x62, 0x92,
+ 0x62, 0x8C, 0x62, 0x92, 0x62, 0x00, 0x01, 0x00, 0x07, 0x00, 0x31, 0x06, 0x31, 0x30, 0x61, 0x30,
+ 0x61, 0x36, 0x67, 0x60, 0x67, 0x60, 0x97, 0x66, 0x97, 0x90, 0xC1, 0x96, 0xC1, 0x96, 0xC7, 0xC6,
+ 0xC7, 0xC6, 0xF7, 0xC6, 0xF7, 0xF6, 0x06, 0x00, 0x06, 0x00, 0x31, 0x00, 0x31, 0x2B, 0x5C, 0x2B,
+ 0x5C, 0x2B, 0x5C, 0x56, 0x5C, 0x56, 0x87, 0x56, 0x87, 0x81, 0xB2, 0x81, 0xB2, 0x81, 0xB2, 0xAC,
+ 0xB2, 0xAC, 0xDD, 0xAC, 0xDD, 0xD7, 0x2A, 0x00, 0x30, 0x00, 0x31, 0x06, 0x31, 0x07, 0x38, 0x07,
+ 0x38, 0x0D, 0x3E, 0x0E, 0x3E, 0x0E, 0x45, 0x14, 0x45, 0x15, 0x46, 0x1B, 0x46, 0x1B, 0x4C, 0x22,
+ 0x4C, 0x22, 0x53, 0x22, 0x53, 0x29, 0x93, 0x62, 0x68, 0x62, 0x92, 0x62, 0x68, 0x62, 0x93, 0x62,
+ 0x68, 0x62, 0x92, 0x62, 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x93, 0x62,
+ 0x92, 0x62, 0x92, 0x62, 0x92, 0x00, 0x00, 0x01, 0x00, 0x07, 0x00, 0x31, 0x30, 0x31, 0x30, 0x37,
+ 0x36, 0x61, 0x60, 0x67, 0x66, 0x91, 0x66, 0x91, 0x90, 0x97, 0x96, 0x97, 0x96, 0xC7, 0xC0, 0xC7,
+ 0xC6, 0xC7, 0xC6, 0xF7, 0xF6, 0xF7, 0x00, 0x06, 0x06, 0x06, 0x00, 0x31, 0x31, 0x31, 0x2B, 0x31,
+ 0x31, 0x5C, 0x56, 0x5C, 0x5C, 0x87, 0x56, 0x87, 0x87, 0x87, 0x81, 0x87, 0x87, 0xB2, 0xAC, 0xB2,
+ 0xB2, 0xB2, 0xAC, 0xDD, 0xDD, 0xDD, 0x00, 0x2A, 0x00, 0x30, 0x00, 0x31, 0x07, 0x31, 0x07, 0x37,
+ 0x0D, 0x38, 0x0E, 0x3E, 0x14, 0x3F, 0x14, 0x3F, 0x15, 0x45, 0x1B, 0x45, 0x1B, 0x4C, 0x1C, 0x4C,
+ 0x22, 0x4C, 0x22, 0x53, 0x29, 0x53, 0x62, 0x62, 0x62, 0x68, 0x62, 0x62, 0x62, 0x68, 0x62, 0x62,
+ 0x62, 0x68, 0x62, 0x62, 0x62, 0x68, 0x62, 0x62, 0x62, 0x68, 0x62, 0x62, 0x62, 0x92, 0x62, 0x8C,
+ 0x62, 0x92, 0x62, 0x8C, 0x62, 0x00, 0x01, 0x00, 0x31, 0x00, 0x31, 0x06, 0x37, 0x30, 0x61, 0x30,
+ 0x61, 0x36, 0x67, 0x60, 0x91, 0x66, 0x91, 0x66, 0x97, 0x90, 0xC1, 0x96, 0xC7, 0x96, 0xC7, 0xC0,
+ 0xF1, 0xC6, 0xF7, 0xC6, 0xF7, 0xF6, 0x06, 0x00, 0x31, 0x00, 0x31, 0x00, 0x31, 0x2B, 0x5C, 0x2B,
+ 0x5C, 0x2B, 0x5C, 0x56, 0x87, 0x56, 0x87, 0x56, 0x87, 0x81, 0xB2, 0x81, 0xB2, 0x81, 0xB2, 0xAC,
+ 0xDD, 0xAC, 0xDD, 0xAC, 0xDD, 0xD7, 0x2A, 0x00, 0x31, 0x00, 0x31, 0x06, 0x37, 0x07, 0x38, 0x07,
+ 0x38, 0x0D, 0x3E, 0x0E, 0x3F, 0x14, 0x3F, 0x14, 0x45, 0x15, 0x46, 0x1B, 0x4C, 0x1B, 0x4C, 0x1C,
+ 0x4D, 0x22, 0x53, 0x22, 0x53, 0x29, 0x68, 0x62, 0x68, 0x62, 0x68, 0x62, 0x92, 0x62, 0x92, 0x62,
+ 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62,
+ 0x92, 0x62, 0x92, 0x62, 0x92, 0x00, 0x01, 0x01, 0x00, 0x01, 0x07, 0x31, 0x30, 0x31, 0x31, 0x61,
+ 0x36, 0x61, 0x61, 0x67, 0x60, 0x67, 0x67, 0x91, 0x90, 0x97, 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0D, 0x3E, 0x38, 0x3E, 0x0E, 0x45, 0x14, 0x45, 0x15, 0x46, 0x45, 0x4C, 0x1B, 0x4C, 0x22,
+ 0x4C, 0x22, 0x53, 0x4C, 0x53, 0x29, 0x93, 0x62, 0x68, 0x62, 0x93, 0x62, 0x68, 0x62, 0x93, 0x62,
+ 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62,
+ 0x92, 0x62, 0x93, 0x62, 0x92, 0x00, 0x01, 0x01, 0x01, 0x07, 0x01, 0x31, 0x31, 0x31, 0x31, 0x37,
+ 0x37, 0x61, 0x61, 0x67, 0x67, 0x67, 0x67, 0x91, 0x91, 0x97, 0x97, 0x97, 0x97, 0xC7, 0xC1, 0xC7,
+ 0xC7, 0xF1, 0xC7, 0xF7, 0xF7, 0xF7, 0x06, 0x06, 0x06, 0x06, 0x06, 0x31, 0x31, 0x31, 0x31, 0x31,
+ 0x31, 0x5C, 0x5C, 0x5C, 0x5C, 0x5C, 0x5C, 0x87, 0x87, 0x87, 0x87, 0x87, 0x87, 0xB2, 0xB2, 0xB2,
+ 0xB2, 0xDD, 0xB2, 0xDD, 0xDD, 0xDD, 0x2A, 0x2A, 0x2A, 0x30, 0x2A, 0x31, 0x31, 0x31, 0x31, 0x37,
+ 0x37, 0x38, 0x38, 0x3E, 0x3E, 0x3E, 0x3E, 0x3F, 0x3F, 0x45, 0x45, 0x45, 0x45, 0x4C, 0x46, 0x4C,
+ 0x4C, 0x4D, 0x4C, 0x53, 0x53, 0x53, 0x62, 0x68, 0x62, 0x68, 0x62, 0x68, 0x62, 0x68, 0x62, 0x68,
+ 0x62, 0x68, 0x62, 0x68, 0x62, 0x68, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92,
+ 0x62, 0x92, 0x62, 0x92, 0x8C, 0x00, 0x01, 0x01, 0x31, 0x01, 0x31, 0x07, 0x31, 0x31, 0x61, 0x31,
+ 0x61, 0x37, 0x67, 0x61, 0x91, 0x67, 0x91, 0x67, 0x97, 0x91, 0xC1, 0x97, 0xC7, 0x97, 0xC7, 0xC1,
+ 0xF1, 0xC7, 0xF7, 0xC7, 0xF7, 0xF7, 0x0C, 0x06, 0x37, 0x06, 0x31, 0x06, 0x37, 0x31, 0x62, 0x31,
+ 0x62, 0x31, 0x5C, 0x5C, 0x8D, 0x5C, 0x8D, 0x5C, 0x8D, 0x87, 0xB2, 0x87, 0xB8, 0x87, 0xB8, 0xB2,
+ 0xE3, 0xB2, 0xDD, 0xB2, 0xE3, 0xDD, 0x2A, 0x2A, 0x31, 0x2A, 0x31, 0x30, 0x31, 0x31, 0x38, 0x31,
+ 0x38, 0x37, 0x3E, 0x38, 0x3F, 0x3E, 0x3F, 0x3E, 0x45, 0x3F, 0x46, 0x45, 0x4C, 0x45, 0x4C, 0x46,
+ 0x4D, 0x4C, 0x53, 0x4C, 0x53, 0x53, 0x68, 0x62, 0x93, 0x62, 0x68, 0x62, 0x92, 0x62, 0x92, 0x62,
+ 0x93, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62,
+ 0x93, 0x62, 0x92, 0x62, 0x92, 0x00, 0x01, 0x01, 0x01, 0x01, 0x07, 0x31, 0x31, 0x31, 0x31, 0x61,
+ 0x37, 0x61, 0x61, 0x67, 0x61, 0x67, 0x91, 0x91, 0x91, 0x97, 0x97, 0xC1, 0x97, 0xC1, 0xC7, 0xC7,
+ 0xC7, 0xC7, 0xC7, 0xF7, 0xF7, 0xF7, 0x06, 0x06, 0x06, 0x06, 0x06, 0x31, 0x31, 0x31, 0x31, 0x5C,
+ 0x31, 0x5C, 0x5C, 0x5C, 0x5C, 0x5C, 0x87, 0x87, 0x87, 0x87, 0x87, 0xB2, 0x87, 0xB2, 0xB2, 0xB2,
+ 0xB2, 0xB2, 0xB2, 0xDD, 0xDD, 0xDD, 0x2A, 0x2A, 0x2A, 0x2A, 0x30, 0x31, 0x31, 0x31, 0x31, 0x38,
+ 0x37, 0x38, 0x38, 0x3E, 0x38, 0x3E, 0x3F, 0x3F, 0x3F, 0x45, 0x45, 0x46, 0x45, 0x46, 0x4C, 0x4C,
+ 0x4C, 0x4C, 0x4C, 0x53, 0x53, 0x53, 0x68, 0x68, 0x62, 0x68, 0x62, 0x68, 0x62, 0x68, 0x68, 0x92,
+ 0x62, 0x68, 0x62, 0x92, 0x62, 0x68, 0x68, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x92, 0x92,
+ 0x62, 0x92, 0x8C, 0x92, 0x62, 0x00, 0x02, 0x01, 0x07, 0x01, 0x32, 0x07, 0x31, 0x31, 0x62, 0x31,
+ 0x61, 0x37, 0x68, 0x61, 0x67, 0x61, 0x98, 0x67, 0x97, 0x91, 0xC2, 0x97, 0xC1, 0x97, 0xC8, 0xC7,
+ 0xC7, 0xC7, 0xF8, 0xC7, 0xF7, 0xF7, 0x0C, 0x06, 0x0C, 0x06, 0x37, 0x06, 0x37, 0x31, 0x62, 0x31,
+ 0x62, 0x31, 0x62, 0x5C, 0x62, 0x5C, 0x8D, 0x5C, 0x8D, 0x87, 0xB8, 0x87, 0xB8, 0x87, 0xB8, 0xB2,
+ 0xB8, 0xB2, 0xE3, 0xB2, 0xE3, 0xDD, 0x54, 0x2A, 0x30, 0x2A, 0x5B, 0x30, 0x31, 0x31, 0x62, 0x31,
+ 0x38, 0x37, 0x68, 0x38, 0x3E, 0x38, 0x6F, 0x3E, 0x45, 0x3F, 0x70, 0x45, 0x46, 0x45, 0x76, 0x4C,
+ 0x4C, 0x4C, 0x7D, 0x4C, 0x53, 0x53, 0x93, 0x62, 0x68, 0x62, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62,
+ 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62,
+ 0x92, 0x62, 0x93, 0x62, 0x92, 0x00, 0x01, 0x01, 0x01, 0x07, 0x01, 0x31, 0x31, 0x31, 0x31, 0x37,
+ 0x37, 0x61, 0x61, 0x67, 0x67, 0x91, 0x67, 0x91, 0x91, 0x97, 0x97, 0x97, 0x97, 0xC7, 0xC1, 0xC7,
+ 0xC7, 0xC7, 0xC7, 0xF7, 0xF7, 0xF7, 0x06, 0x0C, 0x06, 0x0C, 0x06, 0x37, 0x31, 0x37, 0x31, 0x37,
+ 0x31, 0x62, 0x5C, 0x62, 0x5C, 0x8D, 0x5C, 0x8D, 0x87, 0x8D, 0x87, 0x8D, 0x87, 0xB8, 0xB2, 0xB8,
+ 0xB2, 0xB8, 0xB2, 0xE3, 0xDD, 0xE3, 0x2A, 0x2A, 0x2A, 0x30, 0x2A, 0x31, 0x31, 0x31, 0x31, 0x37,
+ 0x37, 0x38, 0x38, 0x3E, 0x3E, 0x3F, 0x3E, 0x3F, 0x3F, 0x45, 0x45, 0x45, 0x45, 0x4C, 0x46, 0x4C,
+ 0x4C, 0x4C, 0x4C, 0x53, 0x53, 0x53, 0x62, 0x68, 0x62, 0x68, 0x62, 0x68, 0x62, 0x68, 0x62, 0x68,
+ 0x62, 0x68, 0x62, 0x68, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92, 0x62, 0x92,
+ 0x8C, 0x92, 0x8C, 0x92, 0x8C, 0x00, 0x02, 0x01, 0x32, 0x01, 0x32, 0x07, 0x38, 0x31, 0x62, 0x31,
+ 0x62, 0x37, 0x68, 0x61, 0x92, 0x67, 0x92, 0x67, 0x98, 0x91, 0xC2, 0x97, 0xC8, 0x97, 0xC8, 0xC1,
+ 0xF2, 0xC7, 0xF8, 0xC7, 0xF8, 0xF7, 0x0C, 0x06, 0x37, 0x06, 0x37, 0x06, 0x37, 0x31, 0x62, 0x31,
+ 0x62, 0x31, 0x62, 0x5C, 0x8D, 0x5C, 0x8D, 0x5C, 0x8D, 0x87, 0xB8, 0x87, 0xB8, 0x87, 0xB8, 0xB2,
+ 0xE3, 0xB2, 0xE3, 0xB2, 0xE3, 0xDD, 0x54, 0x2A, 0x5B, 0x2A, 0x5B, 0x30, 0x61, 0x31, 0x62, 0x31,
+ 0x62, 0x37, 0x68, 0x38, 0x69, 0x3E, 0x69, 0x3E, 0x6F, 0x3F, 0x70, 0x45, 0x76, 0x45, 0x76, 0x46,
+ 0x77, 0x4C, 0x7D, 0x4C, 0x7D, 0x53, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62,
+ 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62,
+ 0x93, 0x62, 0x93, 0x62, 0x93, 0x00, 0x01, 0x02, 0x01, 0x01, 0x07, 0x32, 0x31, 0x31, 0x31, 0x62,
+ 0x37, 0x61, 0x61, 0x68, 0x61, 0x67, 0x67, 0x92, 0x91, 0x97, 0x97, 0xC2, 0x97, 0xC1, 0xC7, 0xC8,
+ 0xC7, 0xC7, 0xC7, 0xF8, 0xF7, 0xF7, 0x0C, 0x0C, 0x06, 0x0C, 0x0C, 0x37, 0x31, 0x37, 0x37, 0x62,
+ 0x31, 0x62, 0x62, 0x62, 0x5C, 0x62, 0x62, 0x8D, 0x87, 0x8D, 0x8D, 0xB8, 0x87, 0xB8, 0xB8, 0xB8,
+ 0xB2, 0xB8, 0xB8, 0xE3, 0xDD, 0xE3, 0x2A, 0x54, 0x2A, 0x2A, 0x30, 0x5B, 0x31, 0x31, 0x31, 0x62,
+ 0x37, 0x38, 0x38, 0x68, 0x38, 0x3E, 0x3E, 0x69, 0x3F, 0x45, 0x45, 0x70, 0x45, 0x46, 0x4C, 0x76,
+ 0x4C, 0x4C, 0x4C, 0x7D, 0x53, 0x53, 0x68, 0x68, 0x62, 0x68, 0x68, 0x92, 0x62, 0x68, 0x68, 0x92,
+ 0x62, 0x68, 0x68, 0x92, 0x62, 0x92, 0x68, 0x92, 0x62, 0x92, 0x92, 0x92, 0x62, 0x92, 0x92, 0x92,
+ 0x62, 0x92, 0x92, 0x92, 0x8C, 0x00, 0x02, 0x01, 0x08, 0x01, 0x32, 0x07, 0x32, 0x31, 0x62, 0x31,
+ 0x62, 0x37, 0x68, 0x61, 0x68, 0x61, 0x98, 0x67, 0x98, 0x91, 0xC2, 0x97, 0xC8, 0x97, 0xC8, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x5C, 0x62, 0x5C, 0x8D, 0x5C, 0x8D, 0x87, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0xB8, 0xB2, 0xE3, 0xB2, 0xE3, 0xDD, 0x54, 0x2A, 0x5A, 0x2A, 0x5B, 0x30, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x68, 0x38, 0x68, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x45, 0x76, 0x45, 0x76, 0x4C,
+ 0x76, 0x4C, 0x7D, 0x4C, 0x7D, 0x53, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62,
+ 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62, 0x92, 0x62, 0x93, 0x62,
+ 0x92, 0x62, 0x93, 0x8C, 0x92, 0x00, 0x01, 0x02, 0x01, 0x08, 0x01, 0x32, 0x31, 0x32, 0x31, 0x38,
+ 0x37, 0x62, 0x61, 0x68, 0x67, 0x68, 0x67, 0x92, 0x91, 0x98, 0x97, 0x98, 0x97, 0xC8, 0xC1, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x62, 0x62, 0x8D, 0x8D, 0x8D, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0xB8, 0xE3, 0xB8, 0xE3, 0xE3, 0xE3, 0x2A, 0x54, 0x2A, 0x5A, 0x2A, 0x5B, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x38, 0x68, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6F, 0x45, 0x76, 0x46, 0x76,
+ 0x4C, 0x77, 0x4C, 0x7D, 0x53, 0x7D, 0x68, 0x68, 0x68, 0x68, 0x68, 0x68, 0x68, 0x68, 0x68, 0x92,
+ 0x68, 0x92, 0x68, 0x92, 0x68, 0x92, 0x68, 0x92, 0x68, 0x92, 0x68, 0x92, 0x92, 0x92, 0x92, 0x92,
+ 0x92, 0x92, 0x92, 0x92, 0x92, 0x00, 0x02, 0x01, 0x32, 0x01, 0x32, 0x07, 0x32, 0x31, 0x62, 0x31,
+ 0x62, 0x37, 0x68, 0x61, 0x92, 0x67, 0x92, 0x67, 0x98, 0x91, 0xC2, 0x97, 0xC8, 0x97, 0xC8, 0x00,
+ 0x00, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB,
+ 0xFB, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x8D, 0x62, 0x8D, 0x8D, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xE3, 0xB8, 0xE3, 0xB8, 0xE3, 0xE3, 0x54, 0x2A, 0x5B, 0x2A, 0x5B, 0x30, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x68, 0x38, 0x69, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x45, 0x76, 0x45, 0x76, 0x46,
+ 0x77, 0x4C, 0x7D, 0x4C, 0x7D, 0x53, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62,
+ 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62,
+ 0x93, 0x62, 0x93, 0x62, 0x93, 0x00, 0x02, 0x02, 0x01, 0x02, 0x08, 0x32, 0x31, 0x32, 0x32, 0x62,
+ 0x37, 0x62, 0x62, 0x68, 0x61, 0x68, 0x92, 0x92, 0x91, 0x98, 0x98, 0xC2, 0x97, 0xC2, 0xC8, 0x00,
+ 0x00, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB,
+ 0xFB, 0xFB, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x8D, 0x8D, 0x8D, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xB8, 0xB8, 0xB8, 0xE3, 0xE3, 0xE3, 0x54, 0x54, 0x2A, 0x54, 0x5A, 0x5B, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x62, 0x68, 0x38, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x70, 0x45, 0x70, 0x76, 0x76,
+ 0x4C, 0x76, 0x76, 0x7D, 0x53, 0x7D, 0x68, 0x93, 0x68, 0x68, 0x68, 0x92, 0x62, 0x68, 0x68, 0x93,
+ 0x68, 0x92, 0x68, 0x92, 0x62, 0x92, 0x92, 0x93, 0x68, 0x92, 0x92, 0x92, 0x62, 0x92, 0x92, 0x93,
+ 0x92, 0x92, 0x92, 0x92, 0x8C, 0x00, 0x02, 0x02, 0x08, 0x01, 0x32, 0x07, 0x32, 0x31, 0x62, 0x32,
+ 0x62, 0x37, 0x68, 0x61, 0x68, 0x61, 0x98, 0x68, 0x98, 0x91, 0xC2, 0x97, 0xC2, 0x97, 0xC8, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0xFB, 0xFB, 0xFB, 0x00, 0x00, 0x62, 0x8D, 0x8D, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xB8, 0xB8, 0xE9, 0xB8, 0xE3, 0xE3, 0x54, 0x54, 0x5A, 0x2A, 0x5B, 0x30, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x68, 0x38, 0x68, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x45, 0x70, 0x45, 0x76, 0x76,
+ 0x76, 0x4C, 0x7D, 0x4C, 0x7D, 0x53, 0x93, 0x68, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x68,
+ 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x68, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x92,
+ 0x93, 0x62, 0x93, 0x8C, 0x93, 0x00, 0x02, 0x02, 0x02, 0x08, 0x02, 0x32, 0x32, 0x32, 0x32, 0x38,
+ 0x38, 0x62, 0x62, 0x68, 0x68, 0x92, 0x68, 0x92, 0x92, 0x98, 0x98, 0x98, 0x98, 0xC8, 0xC2, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x8D, 0x8D, 0x8D, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xB8, 0xB8, 0xB8, 0xE3, 0xE3, 0xE3, 0x54, 0x54, 0x54, 0x5A, 0x54, 0x5B, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x62, 0x68, 0x68, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x6F, 0x6F, 0x76, 0x70, 0x76,
+ 0x76, 0x76, 0x76, 0x7D, 0x7D, 0x7D, 0x68, 0x68, 0x68, 0x68, 0x68, 0x68, 0x68, 0x92, 0x68, 0x92,
+ 0x68, 0x92, 0x68, 0x92, 0x68, 0x92, 0x68, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92,
+ 0x92, 0x92, 0x92, 0x92, 0x92, 0x00, 0x02, 0x02, 0x32, 0x02, 0x32, 0x08, 0x38, 0x32, 0x62, 0x32,
+ 0x62, 0x38, 0x68, 0x62, 0x92, 0x68, 0x92, 0x68, 0x98, 0x92, 0xC2, 0x98, 0xC8, 0x98, 0xC8, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0xF8, 0x12, 0x0C, 0x3D, 0x0C, 0x3D, 0x0C, 0x3D, 0x37, 0x68, 0x37,
+ 0x00, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x62, 0x93, 0x8D, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xE9, 0xB8, 0xE9, 0xB8, 0xE9, 0xE3, 0x54, 0x54, 0x5B, 0x54, 0x5B, 0x5A, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x68, 0x62, 0x69, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x6F, 0x76, 0x6F, 0x76, 0x70,
+ 0x77, 0x76, 0x7D, 0x76, 0x7D, 0x7D, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62,
+ 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62, 0x93, 0x62,
+ 0x93, 0x8C, 0x93, 0x8C, 0x93, 0x00, 0x02, 0x02, 0x02, 0x02, 0x08, 0x32, 0x32, 0x32, 0x32, 0x62,
+ 0x38, 0x62, 0x62, 0x68, 0x62, 0x68, 0x68, 0x92, 0x92, 0x98, 0x98, 0xC2, 0x98, 0xC2, 0xC8, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0xF8, 0x0C, 0x12, 0x0C, 0x0C, 0x0C, 0x3D, 0x37, 0x37, 0x37, 0x68,
+ 0x37, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x93, 0x8D, 0x8D, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xB8, 0xB8, 0xB8, 0xE9, 0xE3, 0xE3, 0x54, 0x54, 0x54, 0x54, 0x5A, 0x5B, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x62, 0x68, 0x62, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x70, 0x6F, 0x70, 0x76, 0x76,
+ 0x76, 0x76, 0x76, 0x7D, 0x7D, 0x7D, 0x68, 0x93, 0x68, 0x68, 0x68, 0x93, 0x68, 0x92, 0x68, 0x93,
+ 0x68, 0x92, 0x92, 0x93, 0x68, 0x92, 0x92, 0x93, 0x68, 0x92, 0x92, 0x93, 0x92, 0x92, 0x92, 0x93,
+ 0x92, 0x92, 0x92, 0x93, 0x92, 0x00, 0x03, 0x02, 0x08, 0x02, 0x33, 0x08, 0x32, 0x32, 0x63, 0x32,
+ 0x62, 0x38, 0x69, 0x62, 0x68, 0x62, 0x99, 0x68, 0x98, 0x92, 0xC3, 0x98, 0xC8, 0x98, 0xC9, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0xF8, 0x12, 0x0C, 0x12, 0x0C, 0x3D, 0x0C, 0x3D, 0x37, 0x68, 0x37,
+ 0x68, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x62, 0x93, 0x8D, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xBE, 0xB8, 0xE9, 0xB8, 0xE9, 0xE3, 0x7E, 0x54, 0x5A, 0x54, 0x85, 0x5A, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x92, 0x62, 0x68, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x6F, 0x76, 0x6F, 0xA0, 0x76,
+ 0x76, 0x76, 0xA7, 0x76, 0x7D, 0x7D, 0x93, 0x68, 0x93, 0x62, 0x93, 0x68, 0x93, 0x62, 0x93, 0x68,
+ 0x93, 0x62, 0x93, 0x68, 0x93, 0x62, 0x93, 0x68, 0x93, 0x62, 0x93, 0x92, 0x93, 0x62, 0x93, 0x92,
+ 0x93, 0x62, 0x93, 0x92, 0x93, 0x00, 0x02, 0x02, 0x02, 0x08, 0x02, 0x32, 0x32, 0x32, 0x32, 0x38,
+ 0x38, 0x62, 0x62, 0x68, 0x68, 0x68, 0x68, 0x92, 0x92, 0x98, 0x98, 0x98, 0x98, 0xC8, 0xC2, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0xF8, 0x0C, 0x12, 0x12, 0x12, 0x0C, 0x3D, 0x37, 0x3D, 0x37, 0x3D,
+ 0x00, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x93, 0x93, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xBE, 0xE9, 0xB8, 0xE9, 0xE3, 0xE9, 0x54, 0x54, 0x54, 0x5A, 0x54, 0x5B, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x62, 0x68, 0x68, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x6F, 0x6F, 0x76, 0x70, 0x76,
+ 0x76, 0x77, 0x76, 0x7D, 0x7D, 0x7D, 0x68, 0x92, 0x68, 0x93, 0x68, 0x92, 0x68, 0x93, 0x68, 0x92,
+ 0x68, 0x93, 0x68, 0x92, 0x92, 0x93, 0x92, 0x92, 0x92, 0x93, 0x92, 0x92, 0x92, 0x93, 0x92, 0x92,
+ 0x92, 0x93, 0x92, 0x92, 0x92, 0x00, 0x03, 0x02, 0x33, 0x02, 0x33, 0x08, 0x33, 0x32, 0x63, 0x32,
+ 0x63, 0x38, 0x69, 0x62, 0x93, 0x68, 0x93, 0x68, 0x99, 0x92, 0xC3, 0x98, 0xC9, 0x98, 0xC9, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x93, 0x62, 0x93, 0x8D, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xE9, 0xB8, 0xE9, 0xB8, 0xE9, 0x00, 0x00, 0x54, 0x85, 0x54, 0x85, 0x5A, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x92, 0x62, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x68, 0x93, 0x62, 0x93, 0x68, 0x93, 0x68,
+ 0x93, 0x68, 0x93, 0x62, 0x93, 0x68, 0x93, 0x68, 0x93, 0x68, 0x93, 0x62, 0x93, 0x92, 0x93, 0x92,
+ 0x93, 0x92, 0x93, 0x8C, 0x93, 0x00, 0x02, 0x03, 0x02, 0x02, 0x08, 0x33, 0x32, 0x32, 0x32, 0x63,
+ 0x38, 0x62, 0x62, 0x69, 0x62, 0x68, 0x92, 0x93, 0x92, 0x98, 0x98, 0xC3, 0x98, 0xC2, 0xC8, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x93, 0x93, 0x93, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xBE, 0xBE, 0xBE, 0xE9, 0x00, 0x00, 0x00, 0x00, 0x54, 0x54, 0x5A, 0x85, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x62, 0x92, 0x62, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x93, 0x68, 0x92, 0x92, 0x93,
+ 0x68, 0x92, 0x92, 0x93, 0x68, 0x92, 0x92, 0x93, 0x92, 0x92, 0x92, 0x93, 0x92, 0x92, 0x92, 0x93,
+ 0x92, 0x92, 0x92, 0x93, 0x92, 0x00, 0x03, 0x02, 0x09, 0x02, 0x33, 0x08, 0x33, 0x32, 0x63, 0x32,
+ 0x63, 0x38, 0x69, 0x62, 0x69, 0x62, 0x99, 0x68, 0x99, 0x92, 0xC3, 0x98, 0xC3, 0x98, 0xC9, 0x00,
+ 0x00, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB,
+ 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x62, 0x93, 0x68, 0x93, 0x8D, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xBE, 0xB8, 0xE9, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x54, 0x85, 0x5A, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x92, 0x62, 0x92, 0x00, 0x00, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB,
+ 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x93, 0x62, 0x93, 0x68,
+ 0x93, 0x68, 0x93, 0x68, 0x93, 0x62, 0x93, 0x92, 0x93, 0x68, 0x93, 0x92, 0x93, 0x62, 0x93, 0x92,
+ 0x93, 0x92, 0x93, 0x92, 0x93, 0x00, 0x02, 0x03, 0x02, 0x09, 0x02, 0x33, 0x32, 0x33, 0x32, 0x39,
+ 0x38, 0x63, 0x62, 0x69, 0x68, 0x93, 0x68, 0x93, 0x92, 0x99, 0x98, 0x99, 0x98, 0xC9, 0xC2, 0x00,
+ 0x00, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB,
+ 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x93, 0x68, 0x93, 0x93, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xBE, 0xBE, 0x00, 0x00, 0xFB, 0xFB, 0xFB, 0xFB, 0x00, 0x00, 0x54, 0x85, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x62, 0x92, 0x68, 0x00, 0x00, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB,
+ 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x93, 0x68, 0x93,
+ 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93,
+ 0x92, 0x93, 0x92, 0x93, 0x92, 0x00, 0x03, 0x02, 0x33, 0x02, 0x33, 0x08, 0x39, 0x32, 0x63, 0x32,
+ 0x63, 0x38, 0x69, 0x62, 0x93, 0x68, 0x93, 0x68, 0x99, 0x92, 0xC3, 0x98, 0xC9, 0x98, 0xC9, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x93, 0x68, 0x99, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xEF, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x5A, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x92, 0x62, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFB, 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x93, 0x68,
+ 0x93, 0x68, 0x93, 0x68, 0x93, 0x68, 0x93, 0x68, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92,
+ 0x93, 0x92, 0x93, 0x92, 0xBD, 0x00, 0x03, 0x03, 0x02, 0x03, 0x09, 0x33, 0x32, 0x33, 0x33, 0x63,
+ 0x38, 0x63, 0x63, 0x69, 0x62, 0x69, 0x69, 0x93, 0x92, 0x99, 0x99, 0xC3, 0x98, 0xC3, 0xC9, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x93, 0x93, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x8C, 0x92, 0x62, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x93, 0x92, 0x93,
+ 0x68, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93,
+ 0x92, 0x93, 0x92, 0x93, 0x92, 0x00, 0x03, 0x02, 0x09, 0x02, 0x33, 0x08, 0x33, 0x32, 0x63, 0x32,
+ 0x63, 0x38, 0x69, 0x62, 0x69, 0x62, 0x99, 0x68, 0x99, 0x92, 0xC3, 0x98, 0xC9, 0x98, 0xC9, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0xF8, 0x18, 0x12, 0x18, 0x12, 0x43, 0x12, 0x43, 0x3D, 0x6E, 0x3D,
+ 0x00, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x99, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0xE9, 0x7E, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x92, 0x62, 0x92, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x6F, 0xA0, 0x6F, 0xA0, 0x76,
+ 0xA0, 0x76, 0xA7, 0x76, 0xA7, 0x7D, 0x00, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x99, 0x68,
+ 0x93, 0x68, 0x99, 0x92, 0x93, 0x68, 0x99, 0x92, 0x93, 0x68, 0x99, 0x92, 0x93, 0x92, 0x99, 0x92,
+ 0x93, 0x92, 0xC3, 0x92, 0x93, 0x00, 0x03, 0x03, 0x03, 0x09, 0x03, 0x33, 0x33, 0x33, 0x33, 0x39,
+ 0x39, 0x63, 0x63, 0x69, 0x69, 0x69, 0x69, 0x93, 0x93, 0x99, 0x99, 0x99, 0x99, 0xC9, 0xC3, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0xF9, 0x12, 0x18, 0x12, 0x18, 0x12, 0x3D, 0x3D, 0x43, 0x3D, 0x43,
+ 0x3D, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x99, 0x93, 0x99, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xFB, 0xFB, 0x00, 0x00, 0xE9, 0xEF, 0x7E, 0x7E, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x8C, 0x92, 0x92, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x99, 0x99, 0xA0, 0x9A, 0xA0,
+ 0xA0, 0xA1, 0xA0, 0xA7, 0xA7, 0xA7, 0x68, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x93, 0x92, 0x93,
+ 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93,
+ 0x92, 0x93, 0x92, 0x93, 0x92, 0x00, 0x03, 0x03, 0x33, 0x03, 0x33, 0x08, 0x33, 0x33, 0x63, 0x33,
+ 0x63, 0x39, 0x69, 0x62, 0x93, 0x69, 0x93, 0x69, 0x99, 0x93, 0xC3, 0x98, 0xC9, 0x99, 0xC9, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0xF9, 0x18, 0x12, 0x43, 0x12, 0x43, 0x12, 0x43, 0x3D, 0x6E, 0x3D,
+ 0x6E, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x99, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0xFB,
+ 0xFB, 0x00, 0x00, 0xBE, 0xEF, 0xE9, 0x7E, 0x7E, 0x85, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x92, 0x62, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x6F, 0xA0, 0x99, 0xA0, 0x9A,
+ 0xA1, 0xA0, 0xA7, 0x76, 0xA7, 0xA7, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x93, 0x68,
+ 0x99, 0x68, 0x93, 0x68, 0x93, 0x92, 0x93, 0x92, 0x99, 0x92, 0x93, 0x92, 0x93, 0x92, 0x93, 0x92,
+ 0xC3, 0x92, 0x93, 0x92, 0xBD, 0x00, 0x03, 0x03, 0x03, 0x03, 0x09, 0x33, 0x33, 0x33, 0x33, 0x63,
+ 0x39, 0x63, 0x63, 0x69, 0x63, 0x69, 0x93, 0x93, 0x93, 0x99, 0x99, 0xC3, 0x99, 0xC3, 0xC9, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0xF9, 0x18, 0x18, 0x12, 0x18, 0x18, 0x43, 0x3D, 0x43, 0x43, 0x6E,
+ 0x00, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x99, 0x93, 0x99, 0x00, 0x00, 0xFB, 0xFB, 0xFB, 0xFB,
+ 0x00, 0x00, 0xC4, 0xEF, 0xE9, 0xEF, 0x7E, 0x7E, 0x7E, 0x7E, 0x00, 0x00, 0xFB, 0xFB, 0xFB, 0xFB,
+ 0x00, 0x00, 0x8C, 0x92, 0x8C, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x9A, 0x99, 0x9A, 0xA0, 0xA0,
+ 0xA0, 0xA0, 0xA0, 0xA7, 0xA7, 0xA7, 0x00, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x93, 0x93, 0x93,
+ 0x92, 0x93, 0x93, 0x93, 0x92, 0x93, 0x93, 0x93, 0x92, 0x93, 0x93, 0x93, 0x92, 0x93, 0x93, 0x93,
+ 0x92, 0x93, 0x93, 0x93, 0x92, 0x00, 0x04, 0x03, 0x09, 0x03, 0x34, 0x09, 0x33, 0x33, 0x64, 0x33,
+ 0x63, 0x39, 0x6A, 0x63, 0x69, 0x63, 0x9A, 0x69, 0x99, 0x93, 0xC4, 0x99, 0xC3, 0x99, 0xCA, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x99, 0x93, 0x00, 0x00, 0xFB, 0xFB, 0xFB, 0x00,
+ 0x00, 0xBE, 0xEF, 0xBE, 0xEF, 0xE9, 0xA8, 0x7E, 0x84, 0x7E, 0xAF, 0x00, 0x00, 0xFB, 0xFB, 0xFB,
+ 0x00, 0x00, 0xBC, 0x8C, 0x92, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x68, 0x99, 0x92,
+ 0x93, 0x68, 0x99, 0x92, 0x93, 0x68, 0x99, 0x92, 0x93, 0x92, 0x99, 0x92, 0x93, 0x92, 0xC3, 0x92,
+ 0x93, 0x92, 0xC3, 0x92, 0x93, 0x00, 0x03, 0x03, 0x03, 0x09, 0x03, 0x33, 0x33, 0x33, 0x33, 0x39,
+ 0x39, 0x63, 0x63, 0x69, 0x69, 0x93, 0x69, 0x93, 0x93, 0x99, 0x99, 0x99, 0x99, 0xC9, 0xC3, 0x00,
+ 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0xFB, 0xFB, 0xFB, 0x00, 0x00, 0x99, 0x99, 0x99, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00,
+ 0xC4, 0xC4, 0xC4, 0xEF, 0xEF, 0xEF, 0x7E, 0x7E, 0x7E, 0x84, 0x7E, 0x85, 0x00, 0x00, 0xFB, 0xFB,
+ 0x00, 0x00, 0x8C, 0x92, 0x92, 0x00, 0x00, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFB, 0xFB, 0xFB, 0x00, 0x00, 0x93, 0x92, 0x93,
+ 0x93, 0x93, 0x92, 0x93, 0x93, 0x93, 0x92, 0x93, 0x93, 0x93, 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FB,
+ 0xFB, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x6E, 0x99, 0x99, 0x99, 0x00, 0x00, 0x00, 0x00, 0xC4, 0xC4,
+ 0xC4, 0xC4, 0xC4, 0xEF, 0xEF, 0xEF, 0x7E, 0xA8, 0x7E, 0x7E, 0x84, 0xAF, 0x85, 0x85, 0x00, 0x00,
+ 0x00, 0x00, 0x8C, 0xBC, 0x8C, 0x00, 0x00, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB,
+ 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0x00, 0x00, 0x00, 0x92, 0x93, 0x93, 0x93,
+ 0x92, 0x93, 0x93, 0x93, 0x92, 0x93, 0x93, 0x93, 0x92, 0x93, 0x93, 0x93, 0x92, 0x93, 0x93, 0x93,
+ 0x92, 0x93, 0x93, 0x93, 0x92, 0x00, 0x04, 0x03, 0x0A, 0x03, 0x34, 0x09, 0x34, 0x33, 0x64, 0x33,
+ 0x64, 0x39, 0x6A, 0x63, 0x6A, 0x63, 0x9A, 0x69, 0x9A, 0x93, 0xC4, 0x99, 0xCA, 0x99, 0xCA, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x6E, 0x9F, 0x6E, 0x99, 0x99, 0x00, 0x00, 0x00, 0x99, 0xCA, 0xC4,
+ 0xC4, 0xC4, 0xF5, 0xC4, 0xEF, 0xEF, 0xA8, 0x7E, 0xAE, 0x7E, 0xAF, 0x84, 0xAF, 0x85, 0xB6, 0x00,
+ 0x00, 0x00, 0xBC, 0x8C, 0xBC, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x92, 0x99, 0x68, 0x99, 0x92,
+ 0x99, 0x68, 0x99, 0x92, 0x99, 0x92, 0x99, 0x92, 0x99, 0x92, 0xC3, 0x92, 0x99, 0x92, 0xC3, 0x92,
+ 0x99, 0x92, 0xC3, 0x92, 0xC3, 0x00, 0x03, 0x04, 0x03, 0x0A, 0x03, 0x34, 0x33, 0x34, 0x33, 0x3A,
+ 0x39, 0x64, 0x63, 0x6A, 0x69, 0x6A, 0x69, 0x94, 0x93, 0x9A, 0x99, 0x9A, 0x99, 0xCA, 0xC3, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x6E, 0x6E, 0x6E, 0x6E, 0x99, 0x99, 0x99, 0x00, 0x00, 0x99, 0xC4, 0xC4, 0xC4,
+ 0xC4, 0xEF, 0xC4, 0xEF, 0xEF, 0xEF, 0x7E, 0xA8, 0x7E, 0xAE, 0x7E, 0xAF, 0x85, 0xAF, 0x85, 0xB5,
+ 0x00, 0x00, 0x8C, 0xBC, 0x92, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93,
+ 0x93, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93, 0x93,
+ 0x93, 0x93, 0x93, 0x93, 0x93, 0x00, 0x04, 0x03, 0x34, 0x03, 0x34, 0x09, 0x34, 0x33, 0x64, 0x33,
+ 0x64, 0x39, 0x6A, 0x63, 0x94, 0x69, 0x94, 0x69, 0x9A, 0x93, 0xC4, 0x99, 0xCA, 0x99, 0xCA, 0xC3,
+ 0xF4, 0xC9, 0xFA, 0xC9, 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xFB, 0xFB, 0x24, 0x24, 0x24, 0x24, 0x4F, 0x24, 0x4F, 0x4F, 0x7A, 0x4F,
+ 0x7A, 0x4F, 0x7A, 0x7A, 0x7A, 0x7A, 0xA5, 0x7A, 0xA5, 0xA5, 0xD0, 0xA5, 0xD0, 0xA5, 0xD0, 0xD0,
+ 0xD0, 0xD0, 0xFB, 0xD0, 0xFB, 0xFB, 0xD2, 0xD2, 0xD8, 0xD2, 0xD9, 0xD8, 0xD9, 0xD9, 0xE0, 0xD9,
+ 0xE0, 0xDF, 0xE6, 0xE0, 0xE6, 0xE0, 0xED, 0xE6, 0xED, 0xE7, 0xEE, 0xED, 0xEE, 0xED, 0xF4, 0xF4,
+ 0xF4, 0xF4, 0xFB, 0xF4, 0xFB, 0xFB, 0xC4, 0x93, 0x99, 0x93, 0xC4, 0x93, 0x99, 0x93, 0xC4, 0x93,
+ 0xC3, 0x93, 0xC4, 0x93, 0xC3, 0x93, 0xC4, 0x93, 0xC3, 0x93, 0xC4, 0x93, 0xC3, 0x93, 0xC4, 0x93,
+ 0xC3, 0x93, 0xC4, 0x93, 0xC3, 0x00,
+};
diff --git a/demos/modules/gdisp/gdisp_images_animated/main.c b/demos/modules/gdisp/gdisp_images_animated/main.c
index 4713e0e9..c5260174 100644
--- a/demos/modules/gdisp/gdisp_images_animated/main.c
+++ b/demos/modules/gdisp/gdisp_images_animated/main.c
@@ -33,7 +33,7 @@
#define MY_BG_COLOR RGB2COLOR(220, 220, 255) // Pale blue so we can see the transparent parts
#ifdef WIN32
- #define USE_MEMORY_FILE FALSE // Can be true or false for Win32
+ #define USE_MEMORY_FILE TRUE // Can be true or false for Win32
#else
#define USE_MEMORY_FILE TRUE // Non-Win32 - use the compiled in image
#endif
diff --git a/demos/modules/ginput/touch_driver_test/main.c b/demos/modules/ginput/touch_driver_test/main.c
index 1a1157b0..225a111c 100644
--- a/demos/modules/ginput/touch_driver_test/main.c
+++ b/demos/modules/ginput/touch_driver_test/main.c
@@ -28,7 +28,6 @@
*/
#include "gfx.h"
-#include "chprintf.h"
static GConsoleObject gc;
static GButtonObject gNext;
@@ -39,15 +38,15 @@ static GListener gl;
* GINPUT Touch Driver Calibrator. *
*------------------------------------------------------------------------*/
int main(void) {
- GSourceHandle gs, gsNext, gsPrev;
+ GSourceHandle gs;
GEvent *pe;
GEventMouse *pem;
GEventGWinButton *peb;
coord_t swidth, sheight;
GHandle ghc, ghNext, ghPrev;
- BaseSequentialStream *gp;
GEventType deviceType;
font_t font;
+ GWidgetInit wi;
gfxInit(); // Initialize the display
@@ -58,12 +57,13 @@ int main(void) {
// Create our title
font = gdispOpenFont("UI2");
+ gwinSetDefaultFont(font);
gdispFillStringBox(0, 0, swidth, 20, "Touch Calibration", font, Red, White, justifyLeft);
// Create our main display window
- ghc = gwinCreateConsole(&gc, 0, 20, swidth, sheight-20, font);
+ wi.g.show = TRUE; wi.g.x = 0; wi.g.y = 20; wi.g.width = swidth; wi.g.height = sheight-20;
+ ghc = gwinConsoleCreate(&gc, &wi.g);
gwinClear(ghc);
- gp = gwinGetConsoleStream(ghc);
// Initialize the mouse in our special no calibration mode.
geventListenerInit(&gl);
@@ -77,22 +77,22 @@ int main(void) {
StepDeviceType:
gwinClear(ghc);
gwinSetColor(ghc, Yellow);
- chprintf(gp, "\n1. DEVICE TYPE\n\n");
+ gwinPrintf(ghc, "\n1. DEVICE TYPE\n\n");
pem = (GEventMouse *)&gl.event;
ginputGetMouseStatus(0, pem);
deviceType = pem->type;
gwinSetColor(ghc, White);
- chprintf(gp, "This is detected as a %s device\n\n",
+ gwinPrintf(ghc, "This is detected as a %s device\n\n",
deviceType == GEVENT_MOUSE ? "MOUSE" : (pem->type == GEVENT_TOUCH ? "TOUCH" : "UNKNOWN"));
if (ghNext)
- chprintf(gp, "Press Next or Back to continue.\n");
+ gwinPrintf(ghc, "Press Next or Back to continue.\n");
else if (deviceType == GEVENT_MOUSE)
- chprintf(gp, "Click the mouse button to move on to the next test.\n");
+ gwinPrintf(ghc, "Click the mouse button to move on to the next test.\n");
else
- chprintf(gp, "Press and release your finger to move on to the next test.\n");
+ gwinPrintf(ghc, "Press and release your finger to move on to the next test.\n");
while(1) {
pe = geventEventWait(&gl, TIME_INFINITE);
@@ -117,23 +117,23 @@ StepDeviceType:
StepRawJitter:
gwinClear(ghc);
gwinSetColor(ghc, Yellow);
- chprintf(gp, "\n2. GINPUT_MOUSE_READ_CYCLES\n\n");
+ gwinPrintf(ghc, "\n2. GINPUT_MOUSE_READ_CYCLES\n\n");
gwinSetColor(ghc, White);
if (deviceType == GEVENT_MOUSE)
- chprintf(gp, "Press and hold the mouse button.\n\n");
+ gwinPrintf(ghc, "Press and hold the mouse button.\n\n");
else
- chprintf(gp, "Press and hold on the surface.\n\n");
- chprintf(gp, "Numbers will display in this window.\n"
+ gwinPrintf(ghc, "Press and hold on the surface.\n\n");
+ gwinPrintf(ghc, "Numbers will display in this window.\n"
"Ensure that values don't jump around very much when your finger is stationary.\n\n"
"Increasing GINPUT_MOUSE_READ_CYCLES helps reduce jitter but increases CPU usage.\n\n");
if (ghNext)
- chprintf(gp, "Press Next or Back to continue.\n");
+ gwinPrintf(ghc, "Press Next or Back to continue.\n");
else if (deviceType == GEVENT_MOUSE)
- chprintf(gp, "Release the mouse button to move on to the next test.\n");
+ gwinPrintf(ghc, "Release the mouse button to move on to the next test.\n");
else
- chprintf(gp, "Release your finger to move on to the next test.\n");
+ gwinPrintf(ghc, "Release your finger to move on to the next test.\n");
// For this test turn on ALL mouse movement events
geventAttachSource(&gl, gs, GLISTEN_MOUSEDOWNMOVES|GLISTEN_MOUSEMETA|GLISTEN_MOUSENOFILTER);
@@ -150,7 +150,7 @@ StepRawJitter:
if (pe->type == GEVENT_MOUSE || pe->type == GEVENT_TOUCH) {
pem = (GEventMouse *)pe;
if ((pem->current_buttons & GINPUT_MOUSE_BTN_LEFT))
- chprintf(gp, "%u:%u\n", pem->x, pem->y);
+ gwinPrintf(ghc, "%u:%u\n", pem->x, pem->y);
if (!ghNext && (pem->meta & GMETA_MOUSE_UP))
break;
}
@@ -166,19 +166,19 @@ StepRawJitter:
StepCalibrate:
gwinClear(ghc);
gwinSetColor(ghc, Yellow);
- chprintf(gp, "\n3. GINPUT_MOUSE_CALIBRATION_ERROR\n\n");
+ gwinPrintf(ghc, "\n3. GINPUT_MOUSE_CALIBRATION_ERROR\n\n");
gwinSetColor(ghc, Gray);
- chprintf(gp, "Ensure GINPUT_MOUSE_NEED_CALIBRATION = TRUE and GINPUT_MOUSE_CALIBRATION_ERROR is >= 0\n\n");
+ gwinPrintf(ghc, "Ensure GINPUT_MOUSE_NEED_CALIBRATION = TRUE and GINPUT_MOUSE_CALIBRATION_ERROR is >= 0\n\n");
gwinSetColor(ghc, White);
- chprintf(gp, "You will be presented with a number of points to touch.\nPress them in turn.\n\n"
+ gwinPrintf(ghc, "You will be presented with a number of points to touch.\nPress them in turn.\n\n"
"If the calibration repeatedly fails, increase GINPUT_MOUSE_CALIBRATION_ERROR and try again.\n\n");
if (ghNext)
- chprintf(gp, "Press Next to start the calibration.\n");
+ gwinPrintf(ghc, "Press Next to start the calibration.\n");
else if (deviceType == GEVENT_MOUSE)
- chprintf(gp, "Click the mouse button to start the calibration.\n");
+ gwinPrintf(ghc, "Click the mouse button to start the calibration.\n");
else
- chprintf(gp, "Press and release your finger to start the calibration.\n");
+ gwinPrintf(ghc, "Press and release your finger to start the calibration.\n");
while(1) {
pe = geventEventWait(&gl, TIME_INFINITE);
@@ -201,37 +201,21 @@ StepCalibrate:
/* From now on we can use Next and Previous Buttons */
if (!ghNext) {
+ gwinAttachMouse(0);
+ gwinAttachListener(&gl);
- ghNext = gwinCreateButton(&gNext, swidth-50, 0, 50, 20, font, GBTN_NORMAL);
- gwinSetButtonText(ghNext, "Next", FALSE);
- gsNext = gwinGetButtonSource(ghNext);
- geventAttachSource(&gl, gsNext, 0);
- gwinAttachButtonMouse(ghNext, 0);
-
- ghPrev = gwinCreateButton(&gPrev, swidth-100, 0, 50, 20, font, GBTN_NORMAL);
- gwinSetButtonText(ghPrev, "Back", FALSE);
- gsPrev = gwinGetButtonSource(ghPrev);
- geventAttachSource(&gl, gsPrev, 0);
- gwinAttachButtonMouse(ghPrev, 0);
-
-#if 0
- {
- // Attach a couple of hardware toggle buttons to our Next and Back buttons as well.
- // We can always use the mouse to trigger the buttons if you don't want to use hardware toggles.
- // This code depends on your hardware. Turn it on only if you have
- // defined a board definition for your toggle driver. Then change
- // the next two lines to be correct for your hardware. The values
- // below are correct for the Win32 toggle driver.
- gwinAttachButtonToggle(ghNext, GINPUT_TOGGLE_MOMENTARY1);
- gwinAttachButtonToggle(ghPrev, GINPUT_TOGGLE_MOMENTARY2);
- }
-#endif
+ wi.customDraw = 0; wi.customParam = 0; wi.customStyle = 0;
+ wi.g.show = TRUE; wi.g.x = swidth-50; wi.g.y = 0; wi.g.width = 50; wi.g.height = 20;
+ wi.text = "Next"; ghNext = gwinButtonCreate(&gNext, &wi);
+
+ wi.g.show = TRUE; wi.g.x = swidth-100;
+ wi.text = "Back"; ghPrev = gwinButtonCreate(&gPrev, &wi);
}
// Calibration used the whole screen - re-establish our title
gdispFillStringBox(0, 0, swidth, 20, "Touch Calibration", font, Green, White, justifyLeft);
- gwinButtonDraw(ghNext);
- gwinButtonDraw(ghPrev);
+ gwinRedraw(ghNext);
+ gwinRedraw(ghPrev);
/*
* Test: Mouse movement jitter
@@ -240,18 +224,18 @@ StepCalibrate:
StepJitter:
gwinClear(ghc);
gwinSetColor(ghc, Yellow);
- chprintf(gp, "\n4. GINPUT_MOUSE_MOVE_JITTER\n\n");
+ gwinPrintf(ghc, "\n4. GINPUT_MOUSE_MOVE_JITTER\n\n");
gwinSetColor(ghc, White);
if (deviceType == GEVENT_MOUSE)
- chprintf(gp, "Press and hold the mouse button and move around as if to draw.\n\n");
+ gwinPrintf(ghc, "Press and hold the mouse button and move around as if to draw.\n\n");
else
- chprintf(gp, "Press firmly on the surface and move around as if to draw.\n\n");
+ gwinPrintf(ghc, "Press firmly on the surface and move around as if to draw.\n\n");
- chprintf(gp, "Dots will display in this window. Ensure that when you stop moving your finger that "
+ gwinPrintf(ghc, "Dots will display in this window. Ensure that when you stop moving your finger that "
"new dots stop displaying.\nNew dots should only display when your finger is moving.\n\n"
"Adjust GINPUT_MOUSE_MOVE_JITTER to the smallest value that this reliably works for.\n\n");
- chprintf(gp, "Press Next or Back to continue.\n\n");
+ gwinPrintf(ghc, "Press Next or Back to continue.\n\n");
while(1) {
pe = geventEventWait(&gl, TIME_INFINITE);
@@ -265,7 +249,7 @@ StepJitter:
if (pe->type == GEVENT_MOUSE || pe->type == GEVENT_TOUCH) {
pem = (GEventMouse *)pe;
if ((pem->current_buttons & GINPUT_MOUSE_BTN_LEFT))
- chprintf(gp, ".");
+ gwinPrintf(ghc, ".");
}
}
@@ -276,16 +260,16 @@ StepJitter:
StepPolling:
gwinClear(ghc);
gwinSetColor(ghc, Yellow);
- chprintf(gp, "\n5. GINPUT_MOUSE_POLL_PERIOD\n\n");
+ gwinPrintf(ghc, "\n5. GINPUT_MOUSE_POLL_PERIOD\n\n");
gwinSetColor(ghc, White);
- chprintf(gp, "Press firmly on the surface (or press and hold the mouse button) and move around as if to draw.\n\n");
- chprintf(gp, "A green line will follow your finger.\n"
+ gwinPrintf(ghc, "Press firmly on the surface (or press and hold the mouse button) and move around as if to draw.\n\n");
+ gwinPrintf(ghc, "A green line will follow your finger.\n"
"Adjust GINPUT_MOUSE_POLL_PERIOD to the highest value that provides a line without "
"gaps that are too big.\nDecreasing the value increases CPU usage.\n"
"About 25 (millisecs) normally produces good results."
"This test can be ignored for interrupt driven drivers.\n\n");
- chprintf(gp, "Press Next or Back to continue.\n\n");
+ gwinPrintf(ghc, "Press Next or Back to continue.\n\n");
while(1) {
pe = geventEventWait(&gl, TIME_INFINITE);
@@ -310,18 +294,18 @@ StepPolling:
StepClickJitter:
gwinClear(ghc);
gwinSetColor(ghc, Yellow);
- chprintf(gp, "\n6. GINPUT_MOUSE_MAX_CLICK_JITTER\n\n");
+ gwinPrintf(ghc, "\n6. GINPUT_MOUSE_MAX_CLICK_JITTER\n\n");
gwinSetColor(ghc, White);
- chprintf(gp, "Press and release the touch surface to \"click\".\nTry both short and long presses.\n");
- chprintf(gp, "For a mouse click with the left and right buttons.\n\n");
- chprintf(gp, "Dots will display in this window. A yellow dash is a left (or short) click. "
+ gwinPrintf(ghc, "Press and release the touch surface to \"click\".\nTry both short and long presses.\n");
+ gwinPrintf(ghc, "For a mouse click with the left and right buttons.\n\n");
+ gwinPrintf(ghc, "Dots will display in this window. A yellow dash is a left (or short) click. "
"A red x is a right (or long) click.\n\n"
"Adjust GINPUT_MOUSE_CLICK_JITTER to the smallest value that this reliably works for.\n"
"Adjust GINPUT_MOUSE_CLICK_TIME to adjust distinguishing short vs long presses.\n"
"TIME_INFINITE means there are no long presses (although a right mouse button will still work).\n\n"
"Note: moving your finger (mouse) during a click cancels it.\n\n");
- chprintf(gp, "This is the last test but you can press Next or Back to continue.\n\n");
+ gwinPrintf(ghc, "This is the last test but you can press Next or Back to continue.\n\n");
while(1) {
pe = geventEventWait(&gl, TIME_INFINITE);
@@ -336,11 +320,11 @@ StepClickJitter:
pem = (GEventMouse *)pe;
if ((pem->meta & GMETA_MOUSE_CLICK)) {
gwinSetColor(ghc, Yellow);
- chprintf(gp, "-");
+ gwinPrintf(ghc, "-");
}
if ((pem->meta & GMETA_MOUSE_CXTCLICK)) {
gwinSetColor(ghc, Red);
- chprintf(gp, "x");
+ gwinPrintf(ghc, "x");
}
}
}
diff --git a/demos/modules/gwin/basic/main.c b/demos/modules/gwin/basic/main.c
index 5dc1bab7..c46e6969 100644
--- a/demos/modules/gwin/basic/main.c
+++ b/demos/modules/gwin/basic/main.c
@@ -40,8 +40,14 @@ int main(void) {
gdispClear(Lime);
/* Create two windows */
- GW1 = gwinCreateWindow(NULL, 20, 10, 200, 150);
- GW2 = gwinCreateWindow(NULL, 50, 190, 150, 100);
+ {
+ GWindowInit wi;
+
+ wi.show = TRUE; wi.x = 20; wi.y = 10; wi.width = 200; wi.height = 150;
+ GW1 = gwinWindowCreate(NULL, &wi);
+ wi.show = TRUE; wi.x = 50; wi.y = 190; wi.width = 150; wi.height = 100;
+ GW2 = gwinWindowCreate(NULL, &wi);
+ }
/* Set fore- and background colors for both windows */
gwinSetColor(GW1, Black);
@@ -53,9 +59,9 @@ int main(void) {
gwinClear(GW1);
gwinClear(GW2);
- gwinDrawLine (GW1, 5, 30, 150, 110);
+ gwinDrawLine(GW1, 5, 30, 150, 110);
for(i=5, j=0; i < 200 && j < 150; i+=3, j+=i/20)
- gwinDrawPixel (GW1, i, j);
+ gwinDrawPixel(GW1, i, j);
/*
* Draw two filled circles at the same coordinate
diff --git a/demos/modules/gwin/console/main.c b/demos/modules/gwin/console/main.c
index aa3de40d..197a8ad6 100644
--- a/demos/modules/gwin/console/main.c
+++ b/demos/modules/gwin/console/main.c
@@ -28,27 +28,37 @@
*/
#include "gfx.h"
-#include "chprintf.h"
/* The handles for our three consoles */
GHandle GW1, GW2, GW3;
-/* The streams for our three consoles */
-BaseSequentialStream *S1, *S2, *S3;
-
int main(void) {
uint8_t i;
font_t font1, font2;
/* initialize and clear the display */
gfxInit();
- font1 = gdispOpenFont("UI2 Double");
- font2 = gdispOpenFont("Small");
- /* create the three console windows and set a font for each */
- GW1 = gwinCreateConsole(NULL, 0, 0, gdispGetWidth(), gdispGetHeight()/2, font1);
- GW2 = gwinCreateConsole(NULL, 0, gdispGetHeight()/2, gdispGetWidth()/2, gdispGetHeight(), font2);
- GW3 = gwinCreateConsole(NULL, gdispGetWidth()/2, gdispGetHeight()/2, gdispGetWidth(), gdispGetHeight(), font2);
+ /* Set some fonts */
+ font1 = gdispOpenFont("Small");
+ font2 = gdispOpenFont("UI2 Double");
+ gwinSetDefaultFont(font1);
+
+ /* create the three console windows */
+ {
+ GWindowInit wi;
+
+ wi.show = TRUE;
+ wi.x = 0; wi.y = 0; wi.width = gdispGetWidth(); wi.height = gdispGetHeight()/2;
+ GW1 = gwinConsoleCreate(NULL, &wi);
+ wi.y = gdispGetHeight()/2; wi.width = gdispGetWidth()/2; wi.height = gdispGetHeight();
+ GW2 = gwinConsoleCreate(NULL, &wi);
+ wi.x = gdispGetWidth()/2; wi.height = gdispGetHeight();
+ GW3 = gwinConsoleCreate(NULL, &wi);
+ }
+
+ /* Use a special font for GW1 */
+ gwinSetFont(GW1, font2);
/* Set the fore- and background colors for each console */
gwinSetColor(GW1, Green);
@@ -63,24 +73,19 @@ int main(void) {
gwinClear(GW2);
gwinClear(GW3);
- /* receive the stream pointers of each console */
- S1 = gwinGetConsoleStream(GW1);
- S2 = gwinGetConsoleStream(GW2);
- S3 = gwinGetConsoleStream(GW3);
-
/* Output some data on the first console */
for(i = 0; i < 10; i++) {
- chprintf(S1, "Hello ChibiOS/GFX!\r\n");
+ gwinPrintf(GW1, "Hello ChibiOS/GFX!\r\n");
}
/* Output some data on the second console */
for(i = 0; i < 16; i++) {
- chprintf(S2, "Message Nr.: %d\r\n", i+1);
+ gwinPrintf(GW2, "Message Nr.: %d\r\n", i+1);
}
/* Output some data on the third console */
for(i = 0; i < 18; i++) {
- chprintf(S3, "Message Nr.: %d\r\n", i+1);
+ gwinPrintf(GW3, "Message Nr.: %d\r\n", i+1);
}
while(TRUE) {
diff --git a/demos/modules/gwin/slider/gfxconf.h b/demos/modules/gwin/slider/gfxconf.h
deleted file mode 100644
index b7b39a3f..00000000
--- a/demos/modules/gwin/slider/gfxconf.h
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Copyright (c) 2012, 2013, Joel Bodenmann aka Tectu <joel@unormal.org>
- * Copyright (c) 2012, 2013, Andrew Hannam aka inmarket
- *
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- * * Neither the name of the <organization> nor the
- * names of its contributors may be used to endorse or promote products
- * derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef _GFXCONF_H
-#define _GFXCONF_H
-
-/* The operating system to use - one of these must be defined */
-#define GFX_USE_OS_CHIBIOS TRUE
-#define GFX_USE_OS_WIN32 FALSE
-#define GFX_USE_OS_POSIX FALSE
-
-/* GFX sub-systems to turn on */
-#define GFX_USE_GDISP TRUE
-#define GFX_USE_GWIN TRUE
-#define GFX_USE_GEVENT TRUE
-#define GFX_USE_GTIMER TRUE
-#define GFX_USE_GINPUT TRUE
-
-/* Features for the GDISP sub-system. */
-#define GDISP_NEED_VALIDATION TRUE
-#define GDISP_NEED_CLIP TRUE
-#define GDISP_NEED_TEXT TRUE
-#define GDISP_NEED_CIRCLE FALSE
-#define GDISP_NEED_ELLIPSE FALSE
-#define GDISP_NEED_ARC FALSE
-#define GDISP_NEED_CONVEX_POLYGON FALSE
-#define GDISP_NEED_SCROLL FALSE
-#define GDISP_NEED_PIXELREAD FALSE
-#define GDISP_NEED_CONTROL FALSE
-#define GDISP_NEED_IMAGE FALSE
-#define GDISP_NEED_MULTITHREAD TRUE
-#define GDISP_NEED_ASYNC FALSE
-#define GDISP_NEED_MSGAPI FALSE
-
-/* Builtin Fonts */
-#define GDISP_INCLUDE_FONT_SMALL FALSE
-#define GDISP_INCLUDE_FONT_LARGER FALSE
-#define GDISP_INCLUDE_FONT_UI1 FALSE
-#define GDISP_INCLUDE_FONT_UI2 TRUE
-#define GDISP_INCLUDE_FONT_LARGENUMBERS FALSE
-
-/* GDISP image decoders */
-#define GDISP_NEED_IMAGE_NATIVE FALSE
-#define GDISP_NEED_IMAGE_GIF FALSE
-#define GDISP_NEED_IMAGE_BMP FALSE
-#define GDISP_NEED_IMAGE_JPG FALSE
-#define GDISP_NEED_IMAGE_PNG FALSE
-
-/* Features for the GWIN sub-system. */
-#define GWIN_NEED_BUTTON FALSE
-#define GWIN_NEED_CONSOLE TRUE
-#define GWIN_NEED_SLIDER TRUE
-
-/* Features for the GINPUT sub-system. */
-#define GINPUT_NEED_MOUSE TRUE
-#define GINPUT_NEED_DIAL TRUE
-
-#endif /* _GFXCONF_H */
diff --git a/demos/modules/gwin/slider/main.c b/demos/modules/gwin/slider/main.c
deleted file mode 100644
index 15dc3e26..00000000
--- a/demos/modules/gwin/slider/main.c
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * Copyright (c) 2012, 2013, Joel Bodenmann aka Tectu <joel@unormal.org>
- * Copyright (c) 2012, 2013, Andrew Hannam aka inmarket
- *
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- * * Neither the name of the <organization> nor the
- * names of its contributors may be used to endorse or promote products
- * derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "gfx.h"
-#include "chprintf.h"
-
-static GListener gl;
-
-#define SLIDER_WIDTH 20
-
-int main(void) {
- coord_t swidth, sheight;
- GHandle ghSliderH, ghSliderV, ghConsole;
- font_t fui2;
- GEvent * pe;
- GEventGWinSlider * pSliderEvent;
- BaseSequentialStream *consout;
-
- gfxInit(); // Initialize the display
-
- // Get the display dimensions
- swidth = gdispGetWidth();
- sheight = gdispGetHeight();
-
- // Get the font
- fui2 = gdispOpenFont("UI2");
-
- // Create out gwin windows/widgets
- ghSliderH = gwinCreateSlider(NULL, 5, 5, swidth-10, SLIDER_WIDTH);
- ghSliderV = gwinCreateSlider(NULL, 5, 10+SLIDER_WIDTH, SLIDER_WIDTH, sheight-15+SLIDER_WIDTH);
- ghConsole = gwinCreateConsole(NULL, 10+SLIDER_WIDTH, 10+SLIDER_WIDTH, swidth-15-SLIDER_WIDTH, sheight-15-SLIDER_WIDTH, fui2);
- consout = gwinGetConsoleStream(ghConsole);
-
- // Color up the console window
- gwinSetColor(ghConsole, White);
- gwinSetBgColor(ghConsole, Blue);
-
- // Assign the mouse and dials to the sliders.
-#if GINPUT_NEED_MOUSE
- gwinAttachSliderMouse(ghSliderH, 0);
- gwinAttachSliderMouse(ghSliderV, 0);
-#endif
-#if GINPUT_NEED_DIAL
- gwinAttachSliderDial(ghSliderV, 0);
- gwinAttachSliderDial(ghSliderH, 1);
-#endif
-
- // We want to listen for slider events
- geventListenerInit(&gl);
- geventAttachSource(&gl, gwinGetSliderSource(ghSliderH), 0);
- geventAttachSource(&gl, gwinGetSliderSource(ghSliderV), 0);
-
- // Draw everything on the screen
- gwinClear(ghConsole);
- gwinSliderDraw(ghSliderH);
- gwinSliderDraw(ghSliderV);
-
- while(1) {
- // Get an Event
- pe = geventEventWait(&gl, TIME_INFINITE);
-
- switch(pe->type) {
- case GEVENT_GWIN_SLIDER:
- pSliderEvent = (GEventGWinSlider *)pe;
- chprintf(consout, "%c=%d\n", pSliderEvent->slider == ghSliderH ? 'H' : 'V', pSliderEvent->position);
- break;
- }
- }
-
- return 0;
-}
diff --git a/demos/modules/gwin/slider/readme.txt b/demos/modules/gwin/slider/readme.txt
deleted file mode 100644
index 02d733e9..00000000
--- a/demos/modules/gwin/slider/readme.txt
+++ /dev/null
@@ -1,6 +0,0 @@
-This demo supports input from both a mouse/touch and/or a dial input.
-If your platform does not support one or the other, turn it off in
-gfxconf.h
-
-Note that you will need to include the drivers into your project
-makefile for whichever inputs you decide to use.
diff --git a/demos/modules/gwin/slider/result_647x490.png b/demos/modules/gwin/slider/result_647x490.png
deleted file mode 100644
index c7b12a93..00000000
--- a/demos/modules/gwin/slider/result_647x490.png
+++ /dev/null
Binary files differ
diff --git a/demos/modules/gwin/widgets/main.c b/demos/modules/gwin/widgets/main.c
index e0e4c401..bff842f4 100644
--- a/demos/modules/gwin/widgets/main.c
+++ b/demos/modules/gwin/widgets/main.c
@@ -31,37 +31,192 @@
// include our chibios logo in a .gif format
#include "image_chibios.h"
+/**
+ * This demo demonstrates many of the GWIN widgets.
+ * On the "Radio" tab try playing with the color radio buttons.
+ * On the "Checkbox" tab try playing with the "Disable All" checkbox.
+ */
+
+/* Our custom yellow style */
+static const GWidgetStyle YellowWidgetStyle = {
+ Yellow, // window background
+
+ // enabled color set
+ {
+ HTML2COLOR(0x0000FF), // text
+ HTML2COLOR(0x404040), // edge
+ HTML2COLOR(0xE0E0E0), // fill
+ HTML2COLOR(0xE0E0E0), // progress - inactive area
+ },
+
+ // disabled color set
+ {
+ HTML2COLOR(0xC0C0C0), // text
+ HTML2COLOR(0x808080), // edge
+ HTML2COLOR(0xE0E0E0), // fill
+ HTML2COLOR(0xC0E0C0), // progress - active area
+ },
+
+ // pressed color set
+ {
+ HTML2COLOR(0xFF00FF), // text
+ HTML2COLOR(0x404040), // edge
+ HTML2COLOR(0x808080), // fill
+ HTML2COLOR(0x00E000), // progress - active area
+ },
+};
+
+/* The variables we need */
static GListener gl;
static GHandle ghConsole;
static GHandle ghTabButtons, ghTabSliders, ghTabCheckboxes, ghTabLabels, ghTabRadios, ghTabImages;
static GHandle ghButton1, ghButton2, ghButton3, ghButton4;
static GHandle ghSlider1, ghSlider2, ghSlider3, ghSlider4;
-static GHandle ghCheckbox1, ghCheckbox2;
+static GHandle ghCheckbox1, ghCheckbox2, ghCheckDisableAll;
static GHandle ghLabel1;
static GHandle ghRadio1, ghRadio2;
-static GHandle ghImage1;
-
-#define ScrWidth gdispGetWidth()
-#define ScrHeight gdispGetHeight()
-
-#define TAB_HEIGHT 30
-#define BUTTON_WIDTH 50
-#define BUTTON_HEIGHT 30
-#define SLIDER_WIDTH 20
-#define CHECKBOX_WIDTH 80
-#define CHECKBOX_HEIGHT 20
-#define RADIO_WIDTH 50
-#define RADIO_HEIGHT 20
-#define GROUP_TABS 0
-#define GROUP_R1R2 1
-
-static GHandle createTab(GWidgetInit *pwi) {
- GHandle gh;
-
- gh = gwinCreateRadio(NULL, pwi, GROUP_TABS);
- gwinSetCustomDraw(gh, gwinRadioDraw_Tab, 0);
- gwinSetVisible(gh, TRUE);
- return gh;
+static GHandle ghRadioBlack, ghRadioWhite, ghRadioYellow;
+static GHandle ghImage1;
+
+/* Some useful macros */
+#define ScrWidth gdispGetWidth()
+#define ScrHeight gdispGetHeight()
+
+#define TAB_HEIGHT 30
+#define LABEL_HEIGHT 40
+#define BUTTON_WIDTH 50
+#define BUTTON_HEIGHT 30
+#define SLIDER_WIDTH 20
+#define CHECKBOX_WIDTH 80
+#define CHECKBOX_HEIGHT 20
+#define RADIO_WIDTH 50
+#define RADIO_HEIGHT 20
+#define COLOR_WIDTH 80
+#define DISABLEALL_WIDTH 100
+#define GROUP_TABS 0
+#define GROUP_YESNO 1
+#define GROUP_COLORS 2
+
+/**
+ * Create all the widgets.
+ * With the exception of the Tabs they are all created invisible.
+ */
+static void createWidgets(void) {
+ GWidgetInit wi;
+
+ wi.customDraw = 0; wi.customParam = 0; wi.customStyle = 0;
+
+ // Create the Tabs
+ wi.g.show = TRUE; wi.customDraw = gwinRadioDraw_Tab;
+ wi.g.width = ScrWidth/6; wi.g.height = TAB_HEIGHT; wi.g.y = 0;
+ wi.g.x = 0*wi.g.width; wi.text = "Buttons"; ghTabButtons = gwinRadioCreate(NULL, &wi, GROUP_TABS);
+ wi.g.x = 1*wi.g.width; wi.text = "Sliders"; ghTabSliders = gwinRadioCreate(NULL, &wi, GROUP_TABS);
+ wi.g.x = 2*wi.g.width; wi.text = "Checkbox"; ghTabCheckboxes = gwinRadioCreate(NULL, &wi, GROUP_TABS);
+ wi.g.x = 3*wi.g.width; wi.text = "Radios"; ghTabRadios = gwinRadioCreate(NULL, &wi, GROUP_TABS);
+ wi.g.x = 4*wi.g.width; wi.text = "Labels"; ghTabLabels = gwinRadioCreate(NULL, &wi, GROUP_TABS);
+ wi.g.x = 5*wi.g.width; wi.text = "Images"; ghTabImages = gwinRadioCreate(NULL, &wi, GROUP_TABS);
+
+ // Buttons
+ wi.g.show = FALSE; wi.customDraw = 0;
+ wi.g.width = BUTTON_WIDTH; wi.g.height = BUTTON_HEIGHT; wi.g.y = TAB_HEIGHT+5;
+ wi.g.x = 0+0*(BUTTON_WIDTH+1); wi.text = "B1"; ghButton1 = gwinButtonCreate(NULL, &wi);
+ wi.g.x = 0+1*(BUTTON_WIDTH+1); wi.text = "B2"; ghButton2 = gwinButtonCreate(NULL, &wi);
+ wi.g.x = 0+2*(BUTTON_WIDTH+1); wi.text = "B3"; ghButton3 = gwinButtonCreate(NULL, &wi);
+ wi.g.x = 0+3*(BUTTON_WIDTH+1); wi.text = "B4"; ghButton4 = gwinButtonCreate(NULL, &wi);
+
+ // Horizontal Sliders
+ wi.g.width = ScrWidth/2-2; wi.g.height = SLIDER_WIDTH; wi.g.x = ScrWidth/2+1;
+ wi.g.y = ScrHeight/2-2*(SLIDER_WIDTH+1); wi.text = "S1"; ghSlider1 = gwinSliderCreate(NULL, &wi);
+ wi.g.y = ScrHeight/2-1*(SLIDER_WIDTH+1); wi.text = "S2"; ghSlider2 = gwinSliderCreate(NULL, &wi);
+
+ // Vertical Sliders
+ wi.g.width = SLIDER_WIDTH; wi.g.height = ScrHeight/2-2; wi.g.y = ScrHeight/2+1;
+ wi.g.x = 0+0*(SLIDER_WIDTH+1); wi.text = "S3"; ghSlider3 = gwinSliderCreate(NULL, &wi);
+ wi.g.x = 0+1*(SLIDER_WIDTH+1); wi.text = "S4"; ghSlider4 = gwinSliderCreate(NULL, &wi);
+
+ // Checkboxes - for the 2nd checkbox we apply special drawing before making it visible
+ wi.g.width = CHECKBOX_WIDTH; wi.g.height = CHECKBOX_HEIGHT; wi.g.x = 0;
+ wi.g.y = TAB_HEIGHT+5+0*(CHECKBOX_HEIGHT+1); wi.text = "C1"; ghCheckbox1 = gwinCheckboxCreate(NULL, &wi);
+ wi.customDraw = gwinCheckboxDraw_CheckOnRight;
+ wi.g.y = TAB_HEIGHT+5+1*(CHECKBOX_HEIGHT+1); wi.text = "C2"; ghCheckbox2 = gwinCheckboxCreate(NULL, &wi);
+ wi.customDraw = 0; wi.g.width = DISABLEALL_WIDTH;
+ wi.g.y = TAB_HEIGHT+5+2*(CHECKBOX_HEIGHT+1); wi.text = "Disable All"; ghCheckDisableAll = gwinCheckboxCreate(NULL, &wi);
+
+ // Labels
+ wi.g.width = 0; wi.g.height = LABEL_HEIGHT; // dynamic width, fixed height
+ wi.g.y = TAB_HEIGHT+5+2*(CHECKBOX_HEIGHT+1); wi.text = "Label"; ghLabel1 = gwinLabelCreate(NULL, &wi);
+
+ // Radio Buttons
+ wi.g.width = RADIO_WIDTH; wi.g.height = RADIO_HEIGHT; wi.g.y = TAB_HEIGHT+5;
+ wi.g.x = 0*wi.g.width; wi.text = "Yes"; ghRadio1 = gwinRadioCreate(NULL, &wi, GROUP_YESNO);
+ wi.g.x = 1*wi.g.width; wi.text = "No"; ghRadio2 = gwinRadioCreate(NULL, &wi, GROUP_YESNO);
+ wi.g.width = COLOR_WIDTH; wi.g.y += RADIO_HEIGHT+5;
+ wi.g.x = 0*wi.g.width; wi.text = "Black"; ghRadioBlack = gwinRadioCreate(NULL, &wi, GROUP_COLORS);
+ wi.g.x = 1*wi.g.width; wi.text = "White"; ghRadioWhite = gwinRadioCreate(NULL, &wi, GROUP_COLORS);
+ wi.g.x = 2*wi.g.width; wi.text = "Yellow"; ghRadioYellow = gwinRadioCreate(NULL, &wi, GROUP_COLORS);
+ gwinRadioPress(ghRadioWhite);
+
+ // Image
+ wi.g.x = ScrWidth-210; wi.g.y = TAB_HEIGHT + 10; wi.g.width = 200; wi.g.height = 200;
+ ghImage1 = gwinImageCreate(NULL, &wi.g);
+ gwinImageOpenMemory(ghImage1, image_chibios);
+ gwinImageCache(ghImage1);
+
+ // Console - we apply some special colors before making it visible
+ wi.g.width = ScrWidth/2-1; wi.g.height = ScrHeight/2-1;
+ wi.g.x = ScrWidth/2+1; wi.g.y = ScrHeight/2+1;
+ ghConsole = gwinConsoleCreate(NULL, &wi.g);
+ gwinSetColor(ghConsole, Yellow);
+ gwinSetBgColor(ghConsole, Black);
+}
+
+/**
+ * Set the visibility of widgets based on which tab is selected.
+ */
+static void setTab(GHandle tab) {
+ /* Make sure everything is invisible first */
+ gwinSetVisible(ghButton1, FALSE); gwinSetVisible(ghButton2, FALSE);
+ gwinSetVisible(ghButton3, FALSE); gwinSetVisible(ghButton4, FALSE);
+ gwinSetVisible(ghSlider1, FALSE); gwinSetVisible(ghSlider2, FALSE);
+ gwinSetVisible(ghSlider3, FALSE); gwinSetVisible(ghSlider4, FALSE);
+ gwinSetVisible(ghCheckbox1, FALSE); gwinSetVisible(ghCheckbox2, FALSE); gwinSetVisible(ghCheckDisableAll, FALSE);
+ gwinSetVisible(ghLabel1, FALSE);
+ gwinSetVisible(ghRadio1, FALSE); gwinSetVisible(ghRadio2, FALSE);
+ gwinSetVisible(ghRadioWhite, FALSE);gwinSetVisible(ghRadioBlack, FALSE);gwinSetVisible(ghRadioYellow, FALSE);
+ gwinSetVisible(ghImage1, FALSE);
+
+ /* Turn on widgets depending on the tab selected */
+ if (tab == ghTabButtons) {
+ gwinSetVisible(ghButton1, TRUE); gwinSetVisible(ghButton2, TRUE);
+ gwinSetVisible(ghButton3, TRUE); gwinSetVisible(ghButton4, TRUE);
+ } else if (tab == ghTabSliders) {
+ gwinSetVisible(ghSlider1, TRUE); gwinSetVisible(ghSlider2, TRUE);
+ gwinSetVisible(ghSlider3, TRUE); gwinSetVisible(ghSlider4, TRUE);
+ } else if (tab == ghTabCheckboxes) {
+ gwinSetVisible(ghCheckbox1, TRUE); gwinSetVisible(ghCheckbox2, TRUE); gwinSetVisible(ghCheckDisableAll, TRUE);
+ } else if (tab == ghTabLabels) {
+ gwinSetVisible(ghLabel1, TRUE);
+ } else if (tab == ghTabRadios) {
+ gwinSetVisible(ghRadio1, TRUE); gwinSetVisible(ghRadio2, TRUE);
+ gwinSetVisible(ghRadioWhite, TRUE); gwinSetVisible(ghRadioBlack, TRUE); gwinSetVisible(ghRadioYellow, TRUE);
+ } else if (tab == ghTabImages) {
+ gwinSetVisible(ghImage1, TRUE);
+ }
+}
+
+/**
+ * Set the enabled state of every widget (except the tabs etc)
+ */
+static void setEnabled(bool_t ena) {
+ gwinSetEnabled(ghButton1, ena); gwinSetEnabled(ghButton2, ena);
+ gwinSetEnabled(ghButton3, ena); gwinSetEnabled(ghButton4, ena);
+ gwinSetEnabled(ghSlider1, ena); gwinSetEnabled(ghSlider2, ena);
+ gwinSetEnabled(ghSlider3, ena); gwinSetEnabled(ghSlider4, ena);
+ gwinSetEnabled(ghCheckbox1, ena); gwinSetEnabled(ghCheckbox2, ena); //gwinSetEnabled(ghCheckDisableAll, TRUE);
+ gwinSetEnabled(ghLabel1, ena);
+ gwinSetEnabled(ghRadio1, ena); gwinSetEnabled(ghRadio2, ena);
+ gwinSetEnabled(ghRadioWhite, ena); gwinSetEnabled(ghRadioBlack, ena); gwinSetEnabled(ghRadioYellow, ena);
+ gwinSetEnabled(ghImage1, ena);
}
int main(void) {
@@ -69,16 +224,11 @@ int main(void) {
// Initialize the display
gfxInit();
- gdispClear(White);
// Set the widget defaults
gwinSetDefaultFont(gdispOpenFont("UI2"));
- gwinSetDefaultColor(Black);
- gwinSetDefaultBgColor(White);
-
- // We want to listen for widget events
- geventListenerInit(&gl);
- gwinAttachListener(&gl);
+ gwinSetDefaultStyle(&WhiteWidgetStyle, FALSE);
+ gdispClear(White);
// Connect the mouse
#if GINPUT_NEED_MOUSE
@@ -86,65 +236,9 @@ int main(void) {
#endif
// Create the gwin windows/widgets
- {
- GWidgetInit wi;
-
- // Create the Tabs
- wi.g.show = FALSE; wi.g.width = ScrWidth/6; wi.g.height = TAB_HEIGHT; wi.g.y = 0;
- wi.g.x = 0*wi.g.width; wi.text = "Buttons"; ghTabButtons = createTab(&wi);
- wi.g.x = 1*wi.g.width; wi.text = "Sliders"; ghTabSliders = createTab(&wi);
- wi.g.x = 2*wi.g.width; wi.text = "Checkbox"; ghTabCheckboxes = createTab(&wi);
- wi.g.x = 3*wi.g.width; wi.text = "Labels"; ghTabLabels = createTab(&wi);
- wi.g.x = 4*wi.g.width; wi.text = "Radios"; ghTabRadios = createTab(&wi);
- wi.g.x = 5*wi.g.width; wi.text = "Images"; ghTabImages = createTab(&wi);
-
- // Buttons
- wi.g.width = BUTTON_WIDTH; wi.g.height = BUTTON_HEIGHT; wi.g.y = TAB_HEIGHT+5;
- wi.g.x = 0+0*(BUTTON_WIDTH+1); wi.text = "B1"; ghButton1 = gwinCreateButton(NULL, &wi);
- wi.g.x = 0+1*(BUTTON_WIDTH+1); wi.text = "B2"; ghButton2 = gwinCreateButton(NULL, &wi);
- wi.g.x = 0+2*(BUTTON_WIDTH+1); wi.text = "B3"; ghButton3 = gwinCreateButton(NULL, &wi);
- wi.g.x = 0+3*(BUTTON_WIDTH+1); wi.text = "B4"; ghButton4 = gwinCreateButton(NULL, &wi);
-
- // Horizontal Sliders
- wi.g.width = ScrWidth/2-2; wi.g.height = SLIDER_WIDTH; wi.g.x = ScrWidth/2+1;
- wi.g.y = ScrHeight/2-2*(SLIDER_WIDTH+1); wi.text = "S1"; ghSlider1 = gwinCreateSlider(NULL, &wi);
- wi.g.y = ScrHeight/2-1*(SLIDER_WIDTH+1); wi.text = "S2"; ghSlider2 = gwinCreateSlider(NULL, &wi);
-
- // Vertical Sliders
- wi.g.width = SLIDER_WIDTH; wi.g.height = ScrHeight/2-2; wi.g.y = ScrHeight/2+1;
- wi.g.x = 0+0*(SLIDER_WIDTH+1); wi.text = "S3"; ghSlider3 = gwinCreateSlider(NULL, &wi);
- wi.g.x = 0+1*(SLIDER_WIDTH+1); wi.text = "S4"; ghSlider4 = gwinCreateSlider(NULL, &wi);
-
- // Checkboxes - for the 2nd checkbox we apply special drawing before making it visible
- wi.g.width = CHECKBOX_WIDTH; wi.g.height = CHECKBOX_HEIGHT; wi.g.x = 0;
- wi.g.y = TAB_HEIGHT+5+0*(CHECKBOX_HEIGHT+1); wi.text = "C1"; ghCheckbox1 = gwinCreateCheckbox(NULL, &wi);
- wi.g.y = TAB_HEIGHT+5+1*(CHECKBOX_HEIGHT+1); wi.text = "C2"; ghCheckbox2 = gwinCreateCheckbox(NULL, &wi);
- gwinSetCustomDraw(ghCheckbox2, gwinCheckboxDraw_CheckOnRight, 0);
-
- // Labels
- wi.g.width = 0; // dynamic width
- wi.g.y = TAB_HEIGHT+5+2*(CHECKBOX_HEIGHT+1); wi.text = "L1"; ghLabel1 = gwinLabelCreate(NULL, &wi);
-
- // Radio Buttons
- wi.g.width = RADIO_WIDTH; wi.g.height = RADIO_HEIGHT; wi.g.y = TAB_HEIGHT+5;
- wi.g.x = 0*wi.g.width; wi.text = "Yes"; ghRadio1 = gwinCreateRadio(NULL, &wi, GROUP_R1R2);
- wi.g.x = 1*wi.g.width; wi.text = "No"; ghRadio2 = gwinCreateRadio(NULL, &wi, GROUP_R1R2);
-
- // Image
- wi.g.x = ScrWidth-210; wi.g.y = TAB_HEIGHT + 10; wi.g.width = 200; wi.g.height = 200;
- ghImage1 = gwinImageCreate(NULL, &wi);
- gwinImageOpenMemory(ghImage1, image_chibios);
- gwinImageCache(ghImage1);
-
- // Console - we apply some special colors before making it visible
- wi.g.width = ScrWidth/2-1; wi.g.height = ScrHeight/2-1;
- wi.g.x = ScrWidth/2+1; wi.g.y = ScrHeight/2+1;
- ghConsole = gwinCreateConsole(NULL, &wi.g);
- gwinSetColor(ghConsole, Yellow);
- gwinSetBgColor(ghConsole, Black);
- }
+ createWidgets();
- // Assign toggles and dials to the buttons & sliders etc.
+ // Assign toggles and dials to specific buttons & sliders etc.
#if GINPUT_NEED_TOGGLE
gwinAttachToggle(ghButton1, 0, 0);
gwinAttachToggle(ghButton2, 0, 1);
@@ -158,8 +252,12 @@ int main(void) {
gwinSetVisible(ghConsole, TRUE);
gwinClear(ghConsole);
- // Press the Buttons Tab
- gwinPressRadio(ghTabButtons);
+ // We want to listen for widget events
+ geventListenerInit(&gl);
+ gwinAttachListener(&gl);
+
+ // Press the Tab we want visible
+ gwinRadioPress(ghTabButtons);
while(1) {
// Get an Event
@@ -169,54 +267,68 @@ int main(void) {
case GEVENT_GWIN_BUTTON:
gwinPrintf(ghConsole, "Button %s\n", gwinGetText(((GEventGWinButton *)pe)->button));
break;
+
case GEVENT_GWIN_SLIDER:
gwinPrintf(ghConsole, "Slider %s=%d\n", gwinGetText(((GEventGWinSlider *)pe)->slider), ((GEventGWinSlider *)pe)->position);
break;
+
case GEVENT_GWIN_CHECKBOX:
gwinPrintf(ghConsole, "Checkbox %s=%s\n", gwinGetText(((GEventGWinCheckbox *)pe)->checkbox), ((GEventGWinCheckbox *)pe)->isChecked ? "Checked" : "UnChecked");
+
+ // If it is the Disable All checkbox then do that.
+ if (((GEventGWinCheckbox *)pe)->checkbox == ghCheckDisableAll) {
+ gwinPrintf(ghConsole, "%s All\n", ((GEventGWinCheckbox *)pe)->isChecked ? "Disable" : "Enable");
+ setEnabled(!((GEventGWinCheckbox *)pe)->isChecked);
+ }
break;
+
case GEVENT_GWIN_RADIO:
gwinPrintf(ghConsole, "Radio Group %u=%s\n", ((GEventGWinRadio *)pe)->group, gwinGetText(((GEventGWinRadio *)pe)->radio));
- // Is this the tab radio's
- if (((GEventGWinRadio *)pe)->group == GROUP_TABS) {
-
- // Do some special animation for Label1
- if (((GEventGWinRadio *)pe)->radio == ghTabLabels) {
- gwinSetBgColor(ghLabel1, gwinGetDefaultBgColor());
- gwinSetColor(ghLabel1, gwinGetDefaultColor());
- }
+ switch(((GEventGWinRadio *)pe)->group) {
+ case GROUP_TABS:
// Set control visibility depending on the tab selected
- gwinSetVisible(ghButton1, ((GEventGWinRadio *)pe)->radio == ghTabButtons);
- gwinSetVisible(ghButton2, ((GEventGWinRadio *)pe)->radio == ghTabButtons);
- gwinSetVisible(ghButton3, ((GEventGWinRadio *)pe)->radio == ghTabButtons);
- gwinSetVisible(ghButton4, ((GEventGWinRadio *)pe)->radio == ghTabButtons);
- gwinSetVisible(ghSlider1, ((GEventGWinRadio *)pe)->radio == ghTabSliders);
- gwinSetVisible(ghSlider2, ((GEventGWinRadio *)pe)->radio == ghTabSliders);
- gwinSetVisible(ghSlider3, ((GEventGWinRadio *)pe)->radio == ghTabSliders);
- gwinSetVisible(ghSlider4, ((GEventGWinRadio *)pe)->radio == ghTabSliders);
- gwinSetVisible(ghCheckbox1, ((GEventGWinRadio *)pe)->radio == ghTabCheckboxes);
- gwinSetVisible(ghCheckbox2, ((GEventGWinRadio *)pe)->radio == ghTabCheckboxes);
- gwinSetVisible(ghLabel1, ((GEventGWinRadio *)pe)->radio == ghTabLabels);
- gwinSetVisible(ghRadio1, ((GEventGWinRadio *)pe)->radio == ghTabRadios);
- gwinSetVisible(ghRadio2, ((GEventGWinRadio *)pe)->radio == ghTabRadios);
- gwinSetVisible(ghImage1, ((GEventGWinRadio *)pe)->radio == ghTabImages);
-
- // Do some special animation for Label1
+ setTab(((GEventGWinRadio *)pe)->radio);
+
+ // Do some special animation for Label1 to demonstrate auto width sizing
if (((GEventGWinRadio *)pe)->radio == ghTabLabels) {
+ gwinPrintf(ghConsole, "Change Label Text\n");
gfxSleepMilliseconds(1000);
- gwinSetBgColor(ghLabel1, Blue);
- gwinSetColor(ghLabel1, Yellow);
gwinSetText(ghLabel1, "Very Big Label", FALSE);
gfxSleepMilliseconds(1000);
- gwinSetBgColor(ghLabel1, Yellow);
- gwinSetColor(ghLabel1, Red);
- gwinSetText(ghLabel1, "L1", FALSE);
+ gwinSetText(ghLabel1, "Label", FALSE);
}
+ break;
+
+ case GROUP_COLORS:
+ {
+ const GWidgetStyle *pstyle;
+
+ gwinPrintf(ghConsole, "Change Color Scheme\n");
+
+ if (((GEventGWinRadio *)pe)->radio == ghRadioYellow)
+ pstyle = &YellowWidgetStyle;
+ else if (((GEventGWinRadio *)pe)->radio == ghRadioBlack)
+ pstyle = &BlackWidgetStyle;
+ else
+ pstyle = &WhiteWidgetStyle;
+
+ // Clear the screen to the new color - we avoid the console area as it can't redraw itself
+ #if GDISP_NEED_CLIP
+ gdispUnsetClip();
+ #endif
+ gdispFillArea(0, 0, ScrWidth, ScrHeight/2, pstyle->background);
+ gdispFillArea(0, ScrHeight/2, ScrWidth/2, ScrHeight/2, pstyle->background);
+
+ // Update the style on all controls
+ gwinSetDefaultStyle(pstyle, TRUE);
+ }
+ break;
}
break;
+
default:
gwinPrintf(ghConsole, "Unknown %d\n", pe->type);
break;
diff --git a/demos/modules/gwin/widgets/readme.txt b/demos/modules/gwin/widgets/readme.txt
index 02d733e9..b5777061 100644
--- a/demos/modules/gwin/widgets/readme.txt
+++ b/demos/modules/gwin/widgets/readme.txt
@@ -1,6 +1,8 @@
-This demo supports input from both a mouse/touch and/or a dial input.
+This demo supports input from both a mouse/touch, toggles and/or a dial input.
If your platform does not support one or the other, turn it off in
gfxconf.h
Note that you will need to include the drivers into your project
makefile for whichever inputs you decide to use.
+
+For some fun have a play with the "colors" radio group and the "Disable All" checkbox.
diff --git a/include/gdisp/gdisp.h b/include/gdisp/gdisp.h
index 4ba72580..2497801a 100644
--- a/include/gdisp/gdisp.h
+++ b/include/gdisp/gdisp.h
@@ -572,7 +572,6 @@ extern "C" {
#include "gdisp/lld/gdisp_lld.h"
/* The same as above but use the low level driver directly if no multi-thread support is needed */
- #define _gdispInit(gdisp) gdisp_lld_init()
#define gdispIsBusy() FALSE
#define gdispClear(color) gdisp_lld_clear(color)
#define gdispDrawPixel(x, y, color) gdisp_lld_draw_pixel(x, y, color)
diff --git a/include/gwin/button.h b/include/gwin/button.h
index afe6d0cc..a78a0a71 100644
--- a/include/gwin/button.h
+++ b/include/gwin/button.h
@@ -41,26 +41,14 @@ typedef struct GEventGWinButton {
} GEventGWinButton;
/**
- * @brief Button colors
- */
-typedef struct GButtonColors {
- color_t color_edge;
- color_t color_fill;
- color_t color_txt;
-} GButtonColors;
-
-/**
* @brief The button widget structure
* @note Do not use the members directly - treat it as a black-box.
*/
-typedef struct GButtonObject_t {
+typedef struct GButtonObject {
GWidgetObject w;
#if GINPUT_NEED_TOGGLE
- uint16_t toggle;
+ uint16_t toggle;
#endif
- GButtonColors c_up;
- GButtonColors c_dn;
- GButtonColors c_dis;
} GButtonObject;
#ifdef __cplusplus
@@ -86,26 +74,7 @@ extern "C" {
*
* @api
*/
-GHandle gwinCreateButton(GButtonObject *gb, const GWidgetInit *pInit);
-
-/**
- * @brief Set the colors of a button.
- *
- * @param[in] gh The window handle (must be a button widget)
- * @param[in] pUp The colors for the button when in the up state.
- * @param[in] pDown The colors for the button when in the down state.
- * @param[in] pDisabled The colors for the button when it is disabled.
- *
- * @note The button is not automatically redrawn. Call gwinButtonDraw() after changing the button style
- * @note The button style is copied into the internal button structure - there is no need to
- * maintain static style structures (they can be temporary structures on the stack).
- * @note The pUp, pDown and pDisabled parameters can be NULL. If they are then the existing color styles
- * are not changed for that button state.
- * @note Some custom drawn buttons will ignore he specified colors
- *
- * @api
- */
-void gwinSetButtonColors(GHandle gh, const GButtonColors *pUp, const GButtonColors *pDown, const GButtonColors *pDisabled);
+GHandle gwinButtonCreate(GButtonObject *gb, const GWidgetInit *pInit);
/**
* @brief Is the button current pressed
@@ -115,7 +84,7 @@ void gwinSetButtonColors(GHandle gh, const GButtonColors *pUp, const GButtonColo
*
* @api
*/
-bool_t gwinIsButtonPressed(GHandle gh);
+bool_t gwinButtonIsPressed(GHandle gh);
/**
* @brief Some custom button drawing routines
@@ -141,7 +110,6 @@ bool_t gwinIsButtonPressed(GHandle gh);
* @{
*/
void gwinButtonDraw_3D(GWidgetObject *gw, void *param); // @< A standard 3D button
-void gwinButtonDraw_Box(GWidgetObject *gw, void *param); // @< A very simple box style button
#if GDISP_NEED_ARC || defined(__DOXYGEN__)
void gwinButtonDraw_Rounded(GWidgetObject *gw, void *param); // @< A rounded rectangle button
#endif
diff --git a/include/gwin/checkbox.h b/include/gwin/checkbox.h
index 679a5d9c..fcd0549d 100644
--- a/include/gwin/checkbox.h
+++ b/include/gwin/checkbox.h
@@ -34,26 +34,18 @@
/* Type definitions */
/*===========================================================================*/
-typedef struct GEventGWinCheckbox_t {
+typedef struct GEventGWinCheckbox {
GEventType type; // The type of this event (GEVENT_GWIN_CHECKBOX)
GHandle checkbox; // The checkbox that has been depressed (actually triggered on release)
bool_t isChecked; // Is the checkbox currently checked or unchecked?
} GEventGWinCheckbox;
-typedef struct GCheckboxColors {
- color_t color_border;
- color_t color_checked;
- color_t color_bg;
- color_t color_txt;
-} GCheckboxColors;
-
/* A Checkbox window */
-typedef struct GCheckboxObject_t {
+typedef struct GCheckboxObject {
GWidgetObject w;
#if GINPUT_NEED_TOGGLE
uint16_t toggle;
#endif
- GCheckboxColors c;
} GCheckboxObject;
/**
@@ -75,27 +67,27 @@ typedef struct GCheckboxObject_t {
*
* @api
*/
-GHandle gwinCreateCheckbox(GCheckboxObject *gb, const GWidgetInit *pInit);
+GHandle gwinCheckboxCreate(GCheckboxObject *gb, const GWidgetInit *pInit);
/**
- * @brief Get the state of a checkbox
- * @return TRUE if the checkbox is currently checked
+ * @brief Set the state of a checkbox
*
- * @param[in] gh The window handle (must be a checkbox window)
+ * @param[in] gh The window handle (must be a checkbox window)
+ * @param[in] isChecked TRUE to set the check, FALSE to uncheck.
*
* @api
*/
-bool_t gwinIsCheckboxChecked(GHandle gh);
+void gwinCheckboxCheck(GHandle gh, bool_t isChecked);
/**
- * @brief Set the colors used to draw the checkbox
+ * @brief Get the state of a checkbox
+ * @return TRUE if the checkbox is currently checked
*
- * @param[in] gh The window handle (must be a checkbox window)
- * @param[in] pColors The colors to use
+ * @param[in] gh The window handle (must be a checkbox window)
*
* @api
*/
-void gwinCheckboxSetColors(GHandle gh, GCheckboxColors *pColors);
+bool_t gwinCheckboxIsChecked(GHandle gh);
/**
* @brief Some custom checkbox drawing routines
diff --git a/include/gwin/class_gwin.h b/include/gwin/class_gwin.h
index 1a4de5b9..3be496b1 100644
--- a/include/gwin/class_gwin.h
+++ b/include/gwin/class_gwin.h
@@ -136,6 +136,11 @@ typedef struct gwinVMT {
* @brief The list of all windows in the system
*/
extern gfxQueueASync _GWINList;
+
+ /**
+ * @brief The current window manager
+ */
+ extern GWindowManager * _GWINwm;
#endif
#ifdef __cplusplus
diff --git a/include/gwin/console.h b/include/gwin/console.h
index a3b3697c..b32c3628 100644
--- a/include/gwin/console.h
+++ b/include/gwin/console.h
@@ -27,7 +27,7 @@
/* This file is included within "gwin/gwin.h" */
// A console window. Supports wrapped text writing and a cursor.
-typedef struct GConsoleObject_t {
+typedef struct GConsoleObject {
GWindowObject g;
coord_t cx, cy; // Cursor position
@@ -46,8 +46,8 @@ extern "C" {
/**
* @brief Create a console window.
- * @details A console window allows text to be written using chprintf() (and the console functions defined here).
- * @brief Text in a console window supports newlines and will wrap text as required.
+ * @details A console window allows text to be written.
+ * @note Text in a console window supports newlines and will wrap text as required.
* @return NULL if there is no resultant drawing area, otherwise a window handle.
*
* @param[in] gc The GConsoleObject structure to initialise. If this is NULL the structure is dynamically allocated.
@@ -64,7 +64,7 @@ extern "C" {
*
* @api
*/
-GHandle gwinCreateConsole(GConsoleObject *gc, const GWindowInit *pInit);
+GHandle gwinConsoleCreate(GConsoleObject *gc, const GWindowInit *pInit);
#if GFX_USE_OS_CHIBIOS && GWIN_CONSOLE_USE_BASESTREAM
/**
@@ -77,7 +77,7 @@ GHandle gwinCreateConsole(GConsoleObject *gc, const GWindowInit *pInit);
*
* @api
*/
- BaseSequentialStream *gwinGetConsoleStream(GHandle gh);
+ BaseSequentialStream *gwinConsoleGetStream(GHandle gh);
#endif
/**
diff --git a/include/gwin/graph.h b/include/gwin/graph.h
index b5fc1405..8bc33edf 100644
--- a/include/gwin/graph.h
+++ b/include/gwin/graph.h
@@ -71,7 +71,7 @@ typedef struct GGraphStyle_t {
} GGraphStyle;
// A graph window
-typedef struct GGraphObject_t {
+typedef struct GGraphObject {
GWindowObject g;
GGraphStyle style;
coord_t xorigin, yorigin;
@@ -107,7 +107,7 @@ extern "C" {
*
* @api
*/
-GHandle gwinCreateGraph(GGraphObject *gg, const GWindowInit *pInit);
+GHandle gwinGraphCreate(GGraphObject *gg, const GWindowInit *pInit);
/**
* @brief Set the style of the graphing operations.
diff --git a/include/gwin/gwidget.h b/include/gwin/gwidget.h
index ffd8e26f..222a3af5 100644
--- a/include/gwin/gwidget.h
+++ b/include/gwin/gwidget.h
@@ -31,28 +31,50 @@
struct GWidgetObject;
/**
- * @brief Defines a custom drawing function for a widget
+ * @brief The GColorSet structure
+ * @{
*/
-typedef void (*CustomWidgetDrawFunction)(struct GWidgetObject *gw, void *param);
+typedef struct GColorSet {
+ color_t text; // @< The text color
+ color_t edge; // @< The edge color
+ color_t fill; // @< The fill color
+ color_t progress; // @< The color of progress bars
+} GColorSet;
+/* @} */
/**
- * @brief The GWIN Widget structure
- * @note A widget is a GWIN window that accepts user input.
- * It also has a number of other properties such as its ability
- * to redraw itself (a widget maintains drawing state).
- * @note Do not access the members directly. Treat it as a black-box and use the method functions.
- *
+ * @brief The GWidgetStyle structure
+ * @details A GWidgetStyle is a set of colors that together form a "style".
+ * These colors should not be confused with the GWindow foreground
+ * and background colors which are used for drawing operations.
* @{
*/
-typedef struct GWidgetObject {
- GWindowObject g; // @< This is still a GWIN
- const char * txt; // @< The widget text
- CustomWidgetDrawFunction fnDraw; // @< The current draw function
- void * fnParam; // @< A parameter for the current draw function
-} GWidgetObject;
+typedef struct GWidgetStyle {
+ color_t background; // @< The window background color
+ GColorSet enabled; // @< The colors when enabled
+ GColorSet disabled; // @< The colors when disabled
+ GColorSet pressed; // @< The colors when pressed
+} GWidgetStyle;
/* @} */
/**
+ * @brief We define a couple of GWidgetStyle's that you can use in your
+ * application. The Black style is the default style if you don't
+ * specify one.
+ * @note BlackWidgetStyle means that it is designed for a Black background.
+ * Similarly WhiteWidgetStyle is designed for a White background.
+ * @{
+ */
+extern const GWidgetStyle BlackWidgetStyle;
+extern const GWidgetStyle WhiteWidgetStyle;
+/* @} */
+
+/**
+ * @brief Defines a custom drawing function for a widget
+ */
+typedef void (*CustomWidgetDrawFunction)(struct GWidgetObject *gw, void *param);
+
+/**
* @brief The structure to initialise a widget.
*
* @note Some widgets may have extra parameters.
@@ -63,12 +85,33 @@ typedef struct GWidgetObject {
* @{
*/
typedef struct GWidgetInit {
- GWindowInit g; // @< The GWIN initializer
- const char * text; // @< The initial text
+ GWindowInit g; // @< The GWIN initializer
+ const char * text; // @< The initial text
+ CustomWidgetDrawFunction customDraw; // @< A custom draw function - use NULL for the standard
+ void * customParam; // @< A parameter for the custom draw function (default = NULL)
+ const GWidgetStyle * customStyle; // @< A custom style to use - use NULL for the default style
} GWidgetInit;
/* @} */
/**
+ * @brief The GWIN Widget structure
+ * @note A widget is a GWIN window that accepts user input.
+ * It also has a number of other properties such as its ability
+ * to redraw itself (a widget maintains drawing state).
+ * @note Do not access the members directly. Treat it as a black-box and use the method functions.
+ *
+ * @{
+ */
+typedef struct GWidgetObject {
+ GWindowObject g; // @< This is still a GWIN
+ const char * text; // @< The widget text
+ CustomWidgetDrawFunction fnDraw; // @< The current draw function
+ void * fnParam; // @< A parameter for the current draw function
+ const GWidgetStyle * pstyle; // @< The current widget style colors
+} GWidgetObject;
+/* @} */
+
+/**
* A comment/rant on the above structure:
* We would really like the GWindowObject member to be anonymous. While this is
* allowed under the C11, C99, GNU and various other standards which have been
@@ -84,10 +127,31 @@ extern "C" {
#endif
/**
+ * @brief Set the default style for widgets created hereafter.
+ *
+ * @param[in] pstyle The default style. Passing NULL uses the system compiled style.
+ * @param[in] updateAll If TRUE then all existing widgets that are using the current default style
+ * will be updated to use this new style. Widgets that have custom styles different
+ * from the default style will not be updated.
+ *
+ * @note The style must be allocated statically (not on the stack) as only the pointer is stored.
+ *
+ * @api
+ */
+void gwinSetDefaultStyle(const GWidgetStyle *pstyle, bool_t updateAll);
+
+/**
+ * @brief Get the current default style.
+ *
+ * @api
+ */
+const GWidgetStyle *gwinGetDefaultStyle(void);
+
+/**
* @brief Set the text of a widget.
*
* @param[in] gh The widget handle
- * @param[in] txt The text to set. This must be a constant string unless useAlloc is set.
+ * @param[in] text The text to set. This must be a constant string unless useAlloc is set.
* @param[in] useAlloc If TRUE the string specified will be copied into dynamically allocated memory.
*
* @note The widget is automatically redrawn
@@ -95,7 +159,7 @@ extern "C" {
*
* @api
*/
-void gwinSetText(GHandle gh, const char *txt, bool_t useAlloc);
+void gwinSetText(GHandle gh, const char *text, bool_t useAlloc);
/**
* @brief Get the text of a widget.
@@ -108,6 +172,30 @@ void gwinSetText(GHandle gh, const char *txt, bool_t useAlloc);
const char *gwinGetText(GHandle gh);
/**
+ * @brief Set the style of a widget.
+ *
+ * @param[in] gh The widget handle
+ * @param[in] pstyle The style to set. This must be a static structure (not allocated on a transient stack).
+ * Use NULL to reset to the default style.
+ *
+ * @note The widget is automatically redrawn
+ * @note Non-widgets will ignore this call.
+ *
+ * @api
+ */
+void gwinSetStyle(GHandle gh, const GWidgetStyle *pstyle);
+
+/**
+ * @brief Get the style of a widget.
+ * @return The widget style or NULL if it isn't a widget
+ *
+ * @param[in] gh The widget handle
+ *
+ * @api
+ */
+const GWidgetStyle *gwinGetStyle(GHandle gh);
+
+/**
* @brief Set the routine to perform a custom widget drawing.
*
* @param[in] gh The widget handle
diff --git a/include/gwin/gwin.h b/include/gwin/gwin.h
index 4d0deaf0..37c2a4e8 100644
--- a/include/gwin/gwin.h
+++ b/include/gwin/gwin.h
@@ -174,7 +174,7 @@ extern "C" {
*
* @api
*/
- GHandle gwinCreateWindow(GWindowObject *pgw, const GWindowInit *pInit);
+ GHandle gwinWindowCreate(GWindowObject *pgw, const GWindowInit *pInit);
/**
* @brief Destroy a window (of any type). Releases any dynamically allocated memory.
@@ -357,46 +357,63 @@ extern "C" {
void gwinResize(GHandle gh, coord_t width, coord_t height);
/**
- * @brief Minimize, Maximize or Restore a window
+ * @brief Redraw a window
*
* @param[in] gh The window
- * @param[in] minmax The new minimized/maximized state
*
- * @note The final window state may not be the requested state. Window Managers
- * do not need to implement changing the minmax state. If there is no
- * window manager this call is ignored.
- * @note The window is redrawn if it is changed. See the comments in @p gwinSetVisible()
- * with regard to what can be redrawn and what can't.
- * @note It is up to the window manager to determine what happens with any screen area
- * uncovered by resizing the window.
- * @note When a window is minimised it may be asked to draw the window or the window
- * manager may draw the minimised window.
+ * @note This is normally never required as windows and widgets will redraw as required.
+ * Note that some windows are incapable of redrawing themselves as they don't save
+ * their drawing state.
*
* @api
*/
- void gwinSetMinMax(GHandle gh, GWindowMinMax minmax);
+ void gwinRedraw(GHandle gh);
- /**
- * @brief Get the Minimized/Maximized state of a window
- *
- * @param[in] gh The window
- *
- * @api
- */
- GWindowMinMax gwinGetMinMax(GHandle gh);
+ #if GWIN_NEED_WINDOWMANAGER
+ /**
+ * @brief Minimize, Maximize or Restore a window
+ * @pre GWIN_NEED_WINDOWMANAGER must be TRUE
+ *
+ * @param[in] gh The window
+ * @param[in] minmax The new minimized/maximized state
+ *
+ * @note The final window state may not be the requested state. Window Managers
+ * do not need to implement changing the minmax state. If there is no
+ * window manager this call is ignored.
+ * @note The window is redrawn if it is changed. See the comments in @p gwinSetVisible()
+ * with regard to what can be redrawn and what can't.
+ * @note It is up to the window manager to determine what happens with any screen area
+ * uncovered by resizing the window.
+ * @note When a window is minimised it may be asked to draw the window or the window
+ * manager may draw the minimised window.
+ *
+ * @api
+ */
+ void gwinSetMinMax(GHandle gh, GWindowMinMax minmax);
- /**
- * @brief Raise a window to the top of the z-order
- *
- * @param[in] gh The window
- *
- * @note The window z-order is only supported by some window managers. If there is no
- * window manager this call simple tries to redraw the window. See the comments
- * in @p gwinSetVisible() with regard to what can be redrawn and what can't.
- *
- * @api
- */
- void gwinRaise(GHandle gh);
+ /**
+ * @brief Get the Minimized/Maximized state of a window
+ * @pre GWIN_NEED_WINDOWMANAGER must be TRUE
+ *
+ * @param[in] gh The window
+ *
+ * @api
+ */
+ GWindowMinMax gwinGetMinMax(GHandle gh);
+
+ /**
+ * @brief Raise a window to the top of the z-order
+ * @pre GWIN_NEED_WINDOWMANAGER must be TRUE
+ *
+ * @param[in] gh The window
+ *
+ * @note The window z-order is only supported by some window managers. See the comments
+ * in @p gwinSetVisible() with regard to what can be redrawn and what can't.
+ *
+ * @api
+ */
+ void gwinRaise(GHandle gh);
+ #endif
#if GDISP_NEED_TEXT || defined(__DOXYGEN__)
/**
diff --git a/include/gwin/image.h b/include/gwin/image.h
index d32e9a0c..7eb2d969 100644
--- a/include/gwin/image.h
+++ b/include/gwin/image.h
@@ -30,10 +30,10 @@
// This file is included within "gwin/gwin.h"
// An image window
-typedef struct GImageWidget_t {
+typedef struct GImageObject {
GWindowObject g;
gdispImage image;
-} GImageWidget;
+} GImageObject;
#ifdef __cplusplus
extern "C" {
@@ -41,7 +41,7 @@ extern "C" {
/**
* @brief Create an image widget.
- * @details A console widget allows to display a picture.
+ * @details Display's a picture.
* @return NULL if there is no resultant drawing area, otherwise the widget handle.
*
* @param[in] widget The image widget structure to initialise. If this is NULL, the structure is dynamically allocated.
@@ -52,10 +52,10 @@ extern "C" {
*
* @api
*/
-GHandle gwinImageCreate(GImageWidget *widget, GWindowInit *pInit);
+GHandle gwinImageCreate(GImageObject *widget, GWindowInit *pInit);
/**
- * @brief Sets the sets the io fields in the image structure to routines that support reading from an image stored
+ * @brief Sets the input routines that support reading the image from memory
* in RAM or flash.
* @return TRUE if the IO open function succeeds
*
@@ -68,8 +68,7 @@ bool_t gwinImageOpenMemory(GHandle gh, const void* memory);
#if defined(WIN32) || GFX_USE_OS_WIN32 || GFX_USE_OS_POSIX || defined(__DOXYGEN__)
/**
- * @brief Sets the sets the io fields in the image structure to routines that support reading from an image stored
- * in a simulators native file system.
+ * @brief Sets the input routines that support reading the image from a file
* @return TRUE if the IO open function succeeds
*
* @param[in] gh The widget (must be an image widget)
@@ -82,8 +81,7 @@ bool_t gwinImageOpenMemory(GHandle gh, const void* memory);
#if GFX_USE_OS_CHIBIOS || defined(__DOXYGEN__)
/**
- * @brief Sets the sets the io fields in the image structure to routines that support reading from an image stored
- * on a BaseFileStream (eg. an SD-Card).
+ * @brief Sets the input routines that support reading the image from a BaseFileStream (eg. an SD-Card).
* @return TRUE if the IO open function succeeds
*
* @param[in] gh The widget (must be an image widget)
diff --git a/include/gwin/label.h b/include/gwin/label.h
index d387345d..4362b035 100644
--- a/include/gwin/label.h
+++ b/include/gwin/label.h
@@ -30,9 +30,9 @@
// This file is included within "gwin/gwin.h"
// An label window
-typedef struct GLabelWidget_t {
+typedef struct GLabelObject {
GWidgetObject w;
-} GLabelWidget;
+} GLabelObject;
#ifdef __cplusplus
extern "C" {
@@ -49,7 +49,7 @@ extern "C" {
*
* @api
*/
-GHandle gwinLabelCreate(GLabelWidget *widget, GWidgetInit *pInit);
+GHandle gwinLabelCreate(GLabelObject *widget, GWidgetInit *pInit);
#ifdef __cplusplus
}
diff --git a/include/gwin/radio.h b/include/gwin/radio.h
index 8d4e32a7..1e0a2dd6 100644
--- a/include/gwin/radio.h
+++ b/include/gwin/radio.h
@@ -40,27 +40,15 @@ typedef struct GEventGWinRadio {
} GEventGWinRadio;
/**
- * @brief Button colors
- */
-typedef struct GRadioColors {
- color_t color_edge;
- color_t color_fill;
- color_t color_txt;
-} GRadioColors;
-
-/**
* @brief The radio button widget structure
* @note Do not use the members directly - treat it as a black-box.
*/
-typedef struct GRadioObject_t {
+typedef struct GRadioObject {
GWidgetObject w;
#if GINPUT_NEED_TOGGLE
uint16_t toggle;
#endif
uint16_t group;
- GRadioColors c_up;
- GRadioColors c_dn;
- GRadioColors c_dis;
} GRadioObject;
#ifdef __cplusplus
@@ -89,26 +77,7 @@ extern "C" {
*
* @api
*/
-GHandle gwinCreateRadio(GRadioObject *gb, const GWidgetInit *pInit, uint16_t group);
-
-/**
- * @brief Set the colors of a button.
- *
- * @param[in] gh The window handle (must be a radio widget)
- * @param[in] pUp The colors for the button when in the up state.
- * @param[in] pDown The colors for the button when in the down state.
- * @param[in] pDisabled The colors for the button when it is disabled.
- *
- * @note The button is not automatically redrawn. Call gwinButtonDraw() after changing the button style
- * @note The button style is copied into the internal button structure - there is no need to
- * maintain static style structures (they can be temporary structures on the stack).
- * @note The pUp, pDown and pDisabled parameters can be NULL. If they are then the existing color styles
- * are not changed for that button state.
- * @note Some custom drawn buttons will ignore he specified colors
- *
- * @api
- */
-void gwinSetRadioColors(GHandle gh, const GRadioColors *pUp, const GRadioColors *pDown, const GRadioColors *pDisabled);
+GHandle gwinRadioCreate(GRadioObject *gb, const GWidgetInit *pInit, uint16_t group);
/**
* @brief Press this radio button (and by definition unset any others in the group)
@@ -117,7 +86,7 @@ void gwinSetRadioColors(GHandle gh, const GRadioColors *pUp, const GRadioColors
*
* @api
*/
-void gwinPressRadio(GHandle gh);
+void gwinRadioPress(GHandle gh);
/**
* @brief Is the radio button currently pressed
@@ -127,7 +96,7 @@ void gwinPressRadio(GHandle gh);
*
* @api
*/
-bool_t gwinIsRadioPressed(GHandle gh);
+bool_t gwinRadioIsPressed(GHandle gh);
/**
* @brief Find the currently pressed radio button in the specified group
@@ -137,7 +106,7 @@ bool_t gwinIsRadioPressed(GHandle gh);
*
* @api
*/
-GHandle gwinActiveRadio(uint16_t group);
+GHandle gwinRadioGetActive(uint16_t group);
/**
* @brief Some custom radio button drawing routines
diff --git a/include/gwin/slider.h b/include/gwin/slider.h
index a8cf7ecf..f4ab8750 100644
--- a/include/gwin/slider.h
+++ b/include/gwin/slider.h
@@ -26,7 +26,7 @@
#define GEVENT_GWIN_SLIDER (GEVENT_GWIN_FIRST+1)
-typedef struct GEventGWinSlider_t {
+typedef struct GEventGWinSlider {
GEventType type; // The type of this event (GEVENT_GWIN_BUTTON)
GHandle slider; // The slider that is returning results
int position;
@@ -34,16 +34,8 @@ typedef struct GEventGWinSlider_t {
// There are currently no GEventGWinSlider listening flags - use 0
-typedef struct GSliderColors {
- color_t color_edge;
- color_t color_thumb;
- color_t color_active;
- color_t color_inactive;
- color_t color_txt;
-} GSliderColors;
-
// A slider window
-typedef struct GSliderObject_t {
+typedef struct GSliderObject {
GWidgetObject w;
#if GINPUT_NEED_TOGGLE
uint16_t t_dn;
@@ -56,7 +48,6 @@ typedef struct GSliderObject_t {
int min;
int max;
int pos;
- GSliderColors c;
} GSliderObject;
#ifdef __cplusplus
@@ -86,7 +77,7 @@ extern "C" {
*
* @api
*/
-GHandle gwinCreateSlider(GSliderObject *gb, const GWidgetInit *pInit);
+GHandle gwinSliderCreate(GSliderObject *gb, const GWidgetInit *pInit);
/**
* @brief Set the slider range.
@@ -99,7 +90,7 @@ GHandle gwinCreateSlider(GSliderObject *gb, const GWidgetInit *pInit);
*
* @api
*/
-void gwinSetSliderRange(GHandle gh, int min, int max);
+void gwinSliderSetRange(GHandle gh, int min, int max);
/**
* @brief Set the slider position.
@@ -112,22 +103,7 @@ void gwinSetSliderRange(GHandle gh, int min, int max);
*
* @api
*/
-void gwinSetSliderPosition(GHandle gh, int pos);
-
-/**
- * @brief Set the style of a slider.
- * @details The slider style is defined by its colours.
- *
- * @param[in] gh The window handle (must be a slider window)
- * @param[in] pStyle The styling for the slider.
- *
- * @note The slider is not automatically redrawn. Call gwinSliderDraw() after changing the slider style
- * @note The slider style is copied into the internal slider structure - there is no need to
- * maintain a static style structure.
- *
- * @api
- */
-void gwinSetSliderColors(GHandle gh, const GSliderColors *pStyle);
+void gwinSliderSetPosition(GHandle gh, int pos);
/**
* @brief Get the current slider position.
@@ -140,7 +116,7 @@ void gwinSetSliderColors(GHandle gh, const GSliderColors *pStyle);
*
* @api
*/
-#define gwinGetSliderPosition(gh) (((GSliderObject *)(gh))->pos)
+#define gwinSliderGetPosition(gh) (((GSliderObject *)(gh))->pos)
/**
* @brief Some custom slider drawing routines
diff --git a/src/gdisp/gdisp.c b/src/gdisp/gdisp.c
index 1b16ac53..5c0f4709 100644
--- a/src/gdisp/gdisp.c
+++ b/src/gdisp/gdisp.c
@@ -135,6 +135,10 @@
gdisp_lld_init();
gfxMutexExit(&gdispMutex);
}
+#else
+ void _gdispInit(void) {
+ gdisp_lld_init();
+ }
#endif
#if GDISP_NEED_MULTITHREAD
diff --git a/src/gwin/button.c b/src/gwin/button.c
index 73f56c2e..e6f628c3 100644
--- a/src/gwin/button.c
+++ b/src/gwin/button.c
@@ -29,23 +29,6 @@
// Our pressed state
#define GBUTTON_FLG_PRESSED (GWIN_FIRST_CONTROL_FLAG<<0)
-// Default color scheme
-static const GButtonColors GButtonDefaultColorsUp = {
- HTML2COLOR(0x404040), // color_up_edge;
- HTML2COLOR(0xE0E0E0), // color_up_fill;
- HTML2COLOR(0x000000), // color_up_txt;
-};
-static const GButtonColors GButtonDefaultColorsDown = {
- HTML2COLOR(0x404040), // color_dn_edge;
- HTML2COLOR(0x808080), // color_dn_fill;
- HTML2COLOR(0x404040), // color_dn_txt;
-};
-static const GButtonColors GButtonDefaultColorsDisabled = {
- HTML2COLOR(0x808080), // color_dis_edge;
- HTML2COLOR(0xE0E0E0), // color_dis_fill;
- HTML2COLOR(0xC0C0C0), // color_dis_txt;
-};
-
// Send the button event
static void SendButtonEvent(GWidgetObject *gw) {
GSourceListener * psl;
@@ -153,30 +136,18 @@ static const gwidgetVMT buttonVMT = {
#endif
};
-GHandle gwinCreateButton(GButtonObject *gw, const GWidgetInit *pInit) {
+GHandle gwinButtonCreate(GButtonObject *gw, const GWidgetInit *pInit) {
if (!(gw = (GButtonObject *)_gwidgetCreate(&gw->w, pInit, &buttonVMT)))
return 0;
#if GINPUT_NEED_TOGGLE
gw->toggle = GWIDGET_NO_INSTANCE;
#endif
- gw->c_up = GButtonDefaultColorsUp;
- gw->c_dn = GButtonDefaultColorsDown;
- gw->c_dis = GButtonDefaultColorsDisabled;
gwinSetVisible((GHandle)gw, pInit->g.show);
return (GHandle)gw;
}
-void gwinSetButtonColors(GHandle gh, const GButtonColors *pUp, const GButtonColors *pDown, const GButtonColors *pDisabled) {
- if (gh->vmt != (gwinVMT *)&buttonVMT)
- return;
-
- if (pUp) ((GButtonObject *)gh)->c_up = *pUp;
- if (pDown) ((GButtonObject *)gh)->c_dn = *pDown;
- if (pDisabled) ((GButtonObject *)gh)->c_dis = *pDisabled;
-}
-
-bool_t gwinIsButtonPressed(GHandle gh) {
+bool_t gwinButtonIsPressed(GHandle gh) {
if (gh->vmt != (gwinVMT *)&buttonVMT)
return FALSE;
@@ -187,73 +158,64 @@ bool_t gwinIsButtonPressed(GHandle gh) {
* Custom Draw Routines
*----------------------------------------------------------*/
-static GButtonColors *getDrawColors(GWidgetObject *gw) {
- if (!(gw->g.flags & GWIN_FLG_ENABLED)) return &((GButtonObject *)gw)->c_dis;
- if ((gw->g.flags & GBUTTON_FLG_PRESSED)) return &((GButtonObject *)gw)->c_dn;
- return &((GButtonObject *)gw)->c_up;
+static const GColorSet *getDrawColors(GWidgetObject *gw) {
+ if (!(gw->g.flags & GWIN_FLG_ENABLED)) return &gw->pstyle->disabled;
+ if ((gw->g.flags & GBUTTON_FLG_PRESSED)) return &gw->pstyle->pressed;
+ return &gw->pstyle->enabled;
}
void gwinButtonDraw_3D(GWidgetObject *gw, void *param) {
- (void) param;
- GButtonColors * pcol;
+ const GColorSet * pcol;
+ (void) param;
if (gw->g.vmt != (gwinVMT *)&buttonVMT) return;
pcol = getDrawColors(gw);
- gdispFillStringBox(gw->g.x, gw->g.y, gw->g.width-1, gw->g.height-1, gw->txt, gw->g.font, pcol->color_txt, pcol->color_fill, justifyCenter);
- gdispDrawLine(gw->g.x+gw->g.width-1, gw->g.y, gw->g.x+gw->g.width-1, gw->g.y+gw->g.height-1, pcol->color_edge);
- gdispDrawLine(gw->g.x, gw->g.y+gw->g.height-1, gw->g.x+gw->g.width-2, gw->g.y+gw->g.height-1, pcol->color_edge);
-}
-
-void gwinButtonDraw_Box(GWidgetObject *gw, void *param) {
- (void) param;
- GButtonColors * pcol;
-
- if (gw->g.vmt != (gwinVMT *)&buttonVMT) return;
- pcol = getDrawColors(gw);
-
- gdispFillStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->txt, gw->g.font, pcol->color_txt, pcol->color_fill, justifyCenter);
- gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, pcol->color_edge);
+ gdispFillStringBox(gw->g.x, gw->g.y, gw->g.width-1, gw->g.height-1, gw->text, gw->g.font, pcol->text, pcol->fill, justifyCenter);
+ gdispDrawLine(gw->g.x+gw->g.width-1, gw->g.y, gw->g.x+gw->g.width-1, gw->g.y+gw->g.height-1, pcol->edge);
+ gdispDrawLine(gw->g.x, gw->g.y+gw->g.height-1, gw->g.x+gw->g.width-2, gw->g.y+gw->g.height-1, pcol->edge);
}
#if GDISP_NEED_ARC
void gwinButtonDraw_Rounded(GWidgetObject *gw, void *param) {
- (void) param;
- GButtonColors * pcol;
+ const GColorSet * pcol;
+ (void) param;
if (gw->g.vmt != (gwinVMT *)&buttonVMT) return;
pcol = getDrawColors(gw);
+ gdispFillArea(gw->g.x, gw->g.y, ld, ld, gw->pstyle->background);
if (gw->g.width >= 2*RND_CNR_SIZE+10) {
- gdispFillRoundedBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, RND_CNR_SIZE-1, pcol->color_fill);
- gdispDrawStringBox(gw->g.x+1, gw->g.y+RND_CNR_SIZE, gw->g.width-2, gw->g.height-(2*RND_CNR_SIZE), gw->txt, gw->g.font, pcol->color_txt, justifyCenter);
- gdispDrawRoundedBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, RND_CNR_SIZE, pcol->color_edge);
+ gdispFillRoundedBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, RND_CNR_SIZE-1, pcol->fill);
+ gdispDrawStringBox(gw->g.x+1, gw->g.y+RND_CNR_SIZE, gw->g.width-2, gw->g.height-(2*RND_CNR_SIZE), gw->text, gw->g.font, pcol->text, justifyCenter);
+ gdispDrawRoundedBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, RND_CNR_SIZE, pcol->edge);
} else {
- gdispFillStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->txt, gw->g.font, pcol->color_txt, pcol->color_fill, justifyCenter);
- gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, pcol->color_edge);
+ gdispFillStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->text, gw->g.font, pcol->text, pcol->fill, justifyCenter);
+ gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, pcol->edge);
}
}
#endif
#if GDISP_NEED_ELLIPSE
void gwinButtonDraw_Ellipse(GWidgetObject *gw, void *param) {
- (void) param;
- GButtonColors * pcol;
+ const GColorSet * pcol;
+ (void) param;
if (gw->g.vmt != (gwinVMT *)&buttonVMT) return;
pcol = getDrawColors(gw);
- gdispFillEllipse(gw->g.x+1, gw->g.y+1, gw->g.width/2-1, gw->g.height/2-1, pcol->color_fill);
- gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->txt, gw->g.font, pcol->color_txt, justifyCenter);
- gdispDrawEllipse(gw->g.x, gw->g.y, gw->g.width/2, gw->g.height/2, pcol->color_edge);
+ gdispFillArea(gw->g.x, gw->g.y, ld, ld, gw->pstyle->background);
+ gdispFillEllipse(gw->g.x+1, gw->g.y+1, gw->g.width/2-1, gw->g.height/2-1, pcol->fill);
+ gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->text, gw->g.font, pcol->text, justifyCenter);
+ gdispDrawEllipse(gw->g.x, gw->g.y, gw->g.width/2, gw->g.height/2, pcol->edge);
}
#endif
#if GDISP_NEED_CONVEX_POLYGON
void gwinButtonDraw_ArrowUp(GWidgetObject *gw, void *param) {
- (void) param;
- GButtonColors * pcol;
- point arw[7];
+ const GColorSet * pcol;
+ (void) param;
+ point arw[7];
if (gw->g.vmt != (gwinVMT *)&buttonVMT) return;
pcol = getDrawColors(gw);
@@ -266,15 +228,16 @@ void gwinButtonDraw_Box(GWidgetObject *gw, void *param) {
arw[5].x = (gw->g.width - gw->g.width/ARROWBODY_DIVIDER)/2; arw[5].y = gw->g.height/ARROWHEAD_DIVIDER;
arw[6].x = 0; arw[6].y = gw->g.height/ARROWHEAD_DIVIDER;
- gdispFillConvexPoly(gw->g.x, gw->g.y, arw, 7, pcol->color_fill);
- gdispDrawPoly(gw->g.x, gw->g.y, arw, 7, pcol->color_edge);
- gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->txt, gw->g.font, pcol->color_txt, justifyCenter);
+ gdispFillArea(gw->g.x, gw->g.y, ld, ld, gw->pstyle->background);
+ gdispFillConvexPoly(gw->g.x, gw->g.y, arw, 7, pcol->fill);
+ gdispDrawPoly(gw->g.x, gw->g.y, arw, 7, pcol->edge);
+ gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->text, gw->g.font, pcol->text, justifyCenter);
}
void gwinButtonDraw_ArrowDown(GWidgetObject *gw, void *param) {
- (void) param;
- GButtonColors * pcol;
- point arw[7];
+ const GColorSet * pcol;
+ (void) param;
+ point arw[7];
if (gw->g.vmt != (gwinVMT *)&buttonVMT) return;
pcol = getDrawColors(gw);
@@ -287,15 +250,16 @@ void gwinButtonDraw_Box(GWidgetObject *gw, void *param) {
arw[5].x = (gw->g.width - gw->g.width/ARROWBODY_DIVIDER)/2; arw[5].y = gw->g.height-1-gw->g.height/ARROWHEAD_DIVIDER;
arw[6].x = 0; arw[6].y = gw->g.height-1-gw->g.height/ARROWHEAD_DIVIDER;
- gdispFillConvexPoly(gw->g.x, gw->g.y, arw, 7, pcol->color_fill);
- gdispDrawPoly(gw->g.x, gw->g.y, arw, 7, pcol->color_edge);
- gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->txt, gw->g.font, pcol->color_txt, justifyCenter);
+ gdispFillArea(gw->g.x, gw->g.y, ld, ld, gw->pstyle->background);
+ gdispFillConvexPoly(gw->g.x, gw->g.y, arw, 7, pcol->fill);
+ gdispDrawPoly(gw->g.x, gw->g.y, arw, 7, pcol->edge);
+ gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->text, gw->g.font, pcol->text, justifyCenter);
}
void gwinButtonDraw_ArrowLeft(GWidgetObject *gw, void *param) {
- (void) param;
- GButtonColors * pcol;
- point arw[7];
+ const GColorSet * pcol;
+ (void) param;
+ point arw[7];
if (gw->g.vmt != (gwinVMT *)&buttonVMT) return;
pcol = getDrawColors(gw);
@@ -308,15 +272,16 @@ void gwinButtonDraw_Box(GWidgetObject *gw, void *param) {
arw[5].x = gw->g.width/ARROWHEAD_DIVIDER; arw[5].y = (gw->g.height + gw->g.height/ARROWBODY_DIVIDER)/2;
arw[6].x = gw->g.width/ARROWHEAD_DIVIDER; arw[6].y = gw->g.height-1;
- gdispFillConvexPoly(gw->g.x, gw->g.y, arw, 7, pcol->color_fill);
- gdispDrawPoly(gw->g.x, gw->g.y, arw, 7, pcol->color_edge);
- gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->txt, gw->g.font, pcol->color_txt, justifyCenter);
+ gdispFillArea(gw->g.x, gw->g.y, ld, ld, gw->pstyle->background);
+ gdispFillConvexPoly(gw->g.x, gw->g.y, arw, 7, pcol->fill);
+ gdispDrawPoly(gw->g.x, gw->g.y, arw, 7, pcol->edge);
+ gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->text, gw->g.font, pcol->text, justifyCenter);
}
void gwinButtonDraw_ArrowRight(GWidgetObject *gw, void *param) {
- (void) param;
- GButtonColors * pcol;
- point arw[7];
+ const GColorSet * pcol;
+ (void) param;
+ point arw[7];
if (gw->g.vmt != (gwinVMT *)&buttonVMT) return;
pcol = getDrawColors(gw);
@@ -329,32 +294,31 @@ void gwinButtonDraw_Box(GWidgetObject *gw, void *param) {
arw[5].x = gw->g.width-1-gw->g.width/ARROWHEAD_DIVIDER; arw[5].y = (gw->g.height + gw->g.height/ARROWBODY_DIVIDER)/2;
arw[6].x = gw->g.width-1-gw->g.width/ARROWHEAD_DIVIDER; arw[6].y = gw->g.height-1;
- gdispFillConvexPoly(gw->g.x, gw->g.y, arw, 7, pcol->color_fill);
- gdispDrawPoly(gw->g.x, gw->g.y, arw, 7, pcol->color_edge);
- gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->txt, gw->g.font, pcol->color_txt, justifyCenter);
+ gdispFillArea(gw->g.x, gw->g.y, ld, ld, gw->pstyle->background);
+ gdispFillConvexPoly(gw->g.x, gw->g.y, arw, 7, pcol->fill);
+ gdispDrawPoly(gw->g.x, gw->g.y, arw, 7, pcol->edge);
+ gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->text, gw->g.font, pcol->text, justifyCenter);
}
#endif
#if GDISP_NEED_IMAGE || defined(__DOXYGEN__)
void gwinButtonDraw_Image(GWidgetObject *gw, void *param) {
- GButtonColors * pcol;
- coord_t sy;
+ const GColorSet * pcol;
+ coord_t sy;
if (gw->g.vmt != (gwinVMT *)&buttonVMT) return;
+ pcol = getDrawColors(gw);
if (!(gw->g.flags & GWIN_FLG_ENABLED)) {
- pcol = &((GButtonObject *)gw)->c_dis;
sy = 2 * gw->g.height;
} else if ((gw->g.flags & GBUTTON_FLG_PRESSED)) {
- pcol = &((GButtonObject *)gw)->c_dn;
sy = gw->g.height;
} else {
- pcol = &((GButtonObject *)gw)->c_up;
sy = 0;
}
gdispImageDraw((gdispImage *)param, gw->g.x, gw->g.y, gw->g.width, gw->g.height, 0, sy);
- gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->txt, gw->g.font, pcol->color_txt, justifyCenter);
+ gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->text, gw->g.font, pcol->text, justifyCenter);
}
#endif
diff --git a/src/gwin/checkbox.c b/src/gwin/checkbox.c
index 74d612d2..84eb3b9f 100644
--- a/src/gwin/checkbox.c
+++ b/src/gwin/checkbox.c
@@ -24,13 +24,6 @@
// Our checked state
#define GCHECKBOX_FLG_CHECKED (GWIN_FIRST_CONTROL_FLAG<<0)
-static const GCheckboxColors defaultColors = {
- Black, // border
- Grey, // selected
- White, // background
- Black, // text
-};
-
// Send the checkbox event
static void SendCheckboxEvent(GWidgetObject *gw) {
GSourceListener * psl;
@@ -115,70 +108,89 @@ static const gwidgetVMT checkboxVMT = {
#endif
};
-GHandle gwinCreateCheckbox(GCheckboxObject *gb, const GWidgetInit *pInit) {
+GHandle gwinCheckboxCreate(GCheckboxObject *gb, const GWidgetInit *pInit) {
if (!(gb = (GCheckboxObject *)_gwidgetCreate(&gb->w, pInit, &checkboxVMT)))
return 0;
#if GINPUT_NEED_TOGGLE
gb->toggle = GWIDGET_NO_INSTANCE;
#endif
- gb->c = defaultColors; // assign the default colors
gwinSetVisible((GHandle)gb, pInit->g.show);
return (GHandle)gb;
}
-bool_t gwinIsCheckboxChecked(GHandle gh) {
+void gwinCheckboxCheck(GHandle gh, bool_t isChecked) {
+ if (gh->vmt != (gwinVMT *)&checkboxVMT)
+ return;
+
+ if (isChecked) {
+ if ((gh->flags & GCHECKBOX_FLG_CHECKED)) return;
+ gh->flags |= GCHECKBOX_FLG_CHECKED;
+ } else {
+ if (!(gh->flags & GCHECKBOX_FLG_CHECKED)) return;
+ gh->flags &= ~GCHECKBOX_FLG_CHECKED;
+ }
+ _gwidgetRedraw(gh);
+ SendCheckboxEvent((GWidgetObject *)gh);
+}
+
+bool_t gwinCheckboxIsChecked(GHandle gh) {
if (gh->vmt != (gwinVMT *)&checkboxVMT)
return FALSE;
return (gh->flags & GCHECKBOX_FLG_CHECKED) ? TRUE : FALSE;
}
-void gwinCheckboxSetColors(GHandle gh, GCheckboxColors *pColors) {
- if (gh->vmt != (gwinVMT *)&checkboxVMT)
- return;
+/*----------------------------------------------------------
+ * Custom Draw Routines
+ *----------------------------------------------------------*/
- ((GCheckboxObject *)gh)->c = *pColors;
+static const GColorSet *getDrawColors(GWidgetObject *gw) {
+ if (!(gw->g.flags & GWIN_FLG_ENABLED)) return &gw->pstyle->disabled;
+ if ((gw->g.flags & GCHECKBOX_FLG_CHECKED)) return &gw->pstyle->pressed;
+ return &gw->pstyle->enabled;
}
void gwinCheckboxDraw_CheckOnLeft(GWidgetObject *gw, void *param) {
- #define gcw ((GCheckboxObject *)gw)
- coord_t ld, df;
- (void) param;
+ #define gcw ((GCheckboxObject *)gw)
+ coord_t ld, df;
+ const GColorSet * pcol;
+ (void) param;
- if (gw->g.vmt != (gwinVMT *)&checkboxVMT)
- return;
+ if (gw->g.vmt != (gwinVMT *)&checkboxVMT) return;
+ pcol = getDrawColors(gw);
ld = gw->g.width < gw->g.height ? gw->g.width : gw->g.height;
- gdispFillArea(gw->g.x+1, gw->g.y+1, ld, ld-2, gcw->c.color_bg);
- gdispDrawBox(gw->g.x, gw->g.y, ld, ld, gcw->c.color_border);
+ gdispFillArea(gw->g.x+1, gw->g.y+1, ld, ld-2, gw->pstyle->background);
+ gdispDrawBox(gw->g.x, gw->g.y, ld, ld, pcol->edge);
df = ld < 4 ? 1 : 2;
if (gw->g.flags & GCHECKBOX_FLG_CHECKED)
- gdispFillArea(gw->g.x+df, gw->g.y+df, ld-2*df, ld-2*df, gcw->c.color_checked);
+ gdispFillArea(gw->g.x+df, gw->g.y+df, ld-2*df, ld-2*df, pcol->fill);
- gdispFillStringBox(gw->g.x+ld+1, gw->g.y, gw->g.width-ld-1, gw->g.height, gw->txt, gw->g.font, gcw->c.color_txt, gcw->c.color_bg, justifyLeft);
+ gdispFillStringBox(gw->g.x+ld+1, gw->g.y, gw->g.width-ld-1, gw->g.height, gw->text, gw->g.font, pcol->text, gw->pstyle->background, justifyLeft);
#undef gcw
}
void gwinCheckboxDraw_CheckOnRight(GWidgetObject *gw, void *param) {
- #define gcw ((GCheckboxObject *)gw)
- coord_t ep, ld, df;
- (void) param;
+ #define gcw ((GCheckboxObject *)gw)
+ coord_t ep, ld, df;
+ const GColorSet * pcol;
+ (void) param;
- if (gw->g.vmt != (gwinVMT *)&checkboxVMT)
- return;
+ if (gw->g.vmt != (gwinVMT *)&checkboxVMT) return;
+ pcol = getDrawColors(gw);
ld = gw->g.width < gw->g.height ? gw->g.width : gw->g.height;
ep = gw->g.width-ld-1;
- gdispFillArea(gw->g.x+ep-1, gw->g.y+1, ld, ld-2, gcw->c.color_bg);
- gdispDrawBox(gw->g.x+ep, gw->g.y, ld, ld, gcw->c.color_border);
+ gdispFillArea(gw->g.x+ep-1, gw->g.y+1, ld, ld-2, gw->pstyle->background);
+ gdispDrawBox(gw->g.x+ep, gw->g.y, ld, ld, pcol->edge);
df = ld < 4 ? 1 : 2;
if (gw->g.flags & GCHECKBOX_FLG_CHECKED)
- gdispFillArea(gw->g.x+ep+df, gw->g.y+df, ld-2*df, ld-2*df, gcw->c.color_checked);
+ gdispFillArea(gw->g.x+ep+df, gw->g.y+df, ld-2*df, ld-2*df, pcol->fill);
- gdispFillStringBox(gw->g.x, gw->g.y, ep, gw->g.height, gw->txt, gw->g.font, gcw->c.color_txt, gcw->c.color_bg, justifyRight);
+ gdispFillStringBox(gw->g.x, gw->g.y, ep, gw->g.height, gw->text, gw->g.font, pcol->text, gw->pstyle->background, justifyRight);
#undef gcw
}
diff --git a/src/gwin/console.c b/src/gwin/console.c
index 105cc79d..06648e9b 100644
--- a/src/gwin/console.c
+++ b/src/gwin/console.c
@@ -66,7 +66,7 @@ static const gwinVMT consoleVMT = {
AfterClear, // The after-clear routine
};
-GHandle gwinCreateConsole(GConsoleObject *gc, const GWindowInit *pInit) {
+GHandle gwinConsoleCreate(GConsoleObject *gc, const GWindowInit *pInit) {
if (!(gc = (GConsoleObject *)_gwindowCreate(&gc->g, pInit, &consoleVMT, 0)))
return 0;
#if GFX_USE_OS_CHIBIOS && GWIN_CONSOLE_USE_BASESTREAM
@@ -79,7 +79,7 @@ GHandle gwinCreateConsole(GConsoleObject *gc, const GWindowInit *pInit) {
}
#if GFX_USE_OS_CHIBIOS && GWIN_CONSOLE_USE_BASESTREAM
- BaseSequentialStream *gwinGetConsoleStream(GHandle gh) {
+ BaseSequentialStream *gwinConsoleGetStream(GHandle gh) {
if (gh->vmt != &consoleVMT)
return 0;
return (BaseSequentialStream *)&(((GConsoleObject *)(gh))->stream);
diff --git a/src/gwin/gimage.c b/src/gwin/gimage.c
index 464bc595..eef47dc7 100644
--- a/src/gwin/gimage.c
+++ b/src/gwin/gimage.c
@@ -16,7 +16,7 @@
#include "gwin/class_gwin.h"
-#define widget(gh) ((GImageWidget*)gh)
+#define widget(gh) ((GImageObject *)gh)
static void _destroy(GWindowObject *gh) {
if (gdispImageIsOpen(&widget(gh)->image))
@@ -80,14 +80,14 @@ static void _redraw(GHandle gh) {
static const gwinVMT imageVMT = {
"Image", // The class name
- sizeof(GImageWidget), // The object size
+ sizeof(GImageObject), // The object size
_destroy, // The destroy routine
_redraw, // The redraw routine
0, // The after-clear routine
};
-GHandle gwinImageCreate(GImageWidget *gobj, GWindowInit *pInit) {
- if (!(gobj = (GImageWidget *)_gwindowCreate(&gobj->g, pInit, &imageVMT, 0)))
+GHandle gwinImageCreate(GImageObject *gobj, GWindowInit *pInit) {
+ if (!(gobj = (GImageObject *)_gwindowCreate(&gobj->g, pInit, &imageVMT, 0)))
return 0;
// Ensure the gdispImageIsOpen() gives valid results
diff --git a/src/gwin/graph.c b/src/gwin/graph.c
index 049f52e0..de447f4f 100644
--- a/src/gwin/graph.c
+++ b/src/gwin/graph.c
@@ -165,7 +165,7 @@ static void lineto(GGraphObject *gg, coord_t x0, coord_t y0, coord_t x1, coord_t
}
}
-GHandle gwinCreateGraph(GGraphObject *gg, const GWindowInit *pInit) {
+GHandle gwinGraphCreate(GGraphObject *gg, const GWindowInit *pInit) {
if (!(gg = (GGraphObject *)_gwindowCreate(&gg->g, pInit, &graphVMT, 0)))
return 0;
gg->xorigin = gg->yorigin = 0;
diff --git a/src/gwin/gwidget.c b/src/gwin/gwidget.c
index 6440f171..8fc6ba77 100644
--- a/src/gwin/gwidget.c
+++ b/src/gwin/gwidget.c
@@ -14,7 +14,67 @@
#include "gwin/class_gwin.h"
/* Our listener for events for widgets */
-static GListener gl;
+static GListener gl;
+
+/* Our default style - a white background theme */
+const GWidgetStyle WhiteWidgetStyle = {
+ HTML2COLOR(0xFFFFFF), // window background
+
+ // enabled color set
+ {
+ HTML2COLOR(0x000000), // text
+ HTML2COLOR(0x404040), // edge
+ HTML2COLOR(0xE0E0E0), // fill
+ HTML2COLOR(0xE0E0E0), // progress - inactive area
+ },
+
+ // disabled color set
+ {
+ HTML2COLOR(0xC0C0C0), // text
+ HTML2COLOR(0x808080), // edge
+ HTML2COLOR(0xE0E0E0), // fill
+ HTML2COLOR(0xC0E0C0), // progress - active area
+ },
+
+ // pressed color set
+ {
+ HTML2COLOR(0x404040), // text
+ HTML2COLOR(0x404040), // edge
+ HTML2COLOR(0x808080), // fill
+ HTML2COLOR(0x00E000), // progress - active area
+ },
+};
+
+/* Our black style */
+const GWidgetStyle BlackWidgetStyle = {
+ HTML2COLOR(0x000000), // window background
+
+ // enabled color set
+ {
+ HTML2COLOR(0xC0C0C0), // text
+ HTML2COLOR(0xC0C0C0), // edge
+ HTML2COLOR(0x606060), // fill
+ HTML2COLOR(0x404040), // progress - inactive area
+ },
+
+ // disabled color set
+ {
+ HTML2COLOR(0x808080), // text
+ HTML2COLOR(0x404040), // edge
+ HTML2COLOR(0x404040), // fill
+ HTML2COLOR(0x004000), // progress - active area
+ },
+
+ // pressed color set
+ {
+ HTML2COLOR(0xFFFFFF), // text
+ HTML2COLOR(0xC0C0C0), // edge
+ HTML2COLOR(0xE0E0E0), // fill
+ HTML2COLOR(0x008000), // progress - active area
+ },
+};
+
+static const GWidgetStyle * defaultStyle = &BlackWidgetStyle;
/* We use these everywhere in this file */
#define gw ((GWidgetObject *)gh)
@@ -169,9 +229,10 @@ GHandle _gwidgetCreate(GWidgetObject *pgw, const GWidgetInit *pInit, const gwidg
if (!(pgw = (GWidgetObject *)_gwindowCreate(&pgw->g, &pInit->g, &vmt->g, GWIN_FLG_WIDGET|GWIN_FLG_ENABLED)))
return 0;
- pgw->txt = pInit->text ? pInit->text : "";
- pgw->fnDraw = vmt->DefaultDraw;
- pgw->fnParam = 0;
+ pgw->text = pInit->text ? pInit->text : "";
+ pgw->fnDraw = pInit->customDraw ? pInit->customDraw : vmt->DefaultDraw;
+ pgw->fnParam = pInit->customParam;
+ pgw->pstyle = pInit->customStyle ? pInit->customStyle : defaultStyle;
return &pgw->g;
}
@@ -184,7 +245,7 @@ void _gwidgetDestroy(GHandle gh) {
// Deallocate the text (if necessary)
if ((gh->flags & GWIN_FLG_ALLOCTXT)) {
gh->flags &= ~GWIN_FLG_ALLOCTXT;
- gfxFree((void *)gw->txt);
+ gfxFree((void *)gw->text);
}
#if GFX_USE_GINPUT && GINPUT_NEED_TOGGLE
@@ -226,32 +287,60 @@ void _gwidgetRedraw(GHandle gh) {
gw->fnDraw(gw, gw->fnParam);
}
-void gwinSetText(GHandle gh, const char *txt, bool_t useAlloc) {
+void gwinSetDefaultStyle(const GWidgetStyle *pstyle, bool_t updateAll) {
+ if (!pstyle)
+ pstyle = &BlackWidgetStyle;
+
+ if (updateAll) {
+ const gfxQueueASyncItem * qi;
+ GHandle gh;
+
+ for(qi = gfxQueueASyncPeek(&_GWINList); qi; qi = gfxQueueASyncNext(qi)) {
+ gh = QItem2GWindow(qi);
+ if ((gh->flags & GWIN_FLG_WIDGET) && ((GWidgetObject *)gh)->pstyle == defaultStyle)
+ gwinSetStyle(gh, pstyle);
+ }
+ }
+ gwinSetDefaultBgColor(pstyle->background);
+ defaultStyle = pstyle;
+}
+
+/**
+ * @brief Get the current default style.
+ *
+ * @api
+ */
+const GWidgetStyle *gwinGetDefaultStyle(void) {
+ return defaultStyle;
+}
+
+
+void gwinSetText(GHandle gh, const char *text, bool_t useAlloc) {
if (!(gh->flags & GWIN_FLG_WIDGET))
return;
// Dispose of the old string
if ((gh->flags & GWIN_FLG_ALLOCTXT)) {
gh->flags &= ~GWIN_FLG_ALLOCTXT;
- if (gw->txt) {
- gfxFree((void *)gw->txt);
- gw->txt = "";
+ if (gw->text) {
+ gfxFree((void *)gw->text);
+ gw->text = "";
}
}
// Alloc the new text if required
- if (txt && !*txt) txt = 0;
- if (txt && useAlloc) {
+ if (!text || !*text)
+ gw->text = "";
+ else if (useAlloc) {
char *str;
- if ((str = (char *)gfxAlloc(strlen(txt)+1))) {
+ if ((str = (char *)gfxAlloc(strlen(text)+1))) {
gh->flags |= GWIN_FLG_ALLOCTXT;
- strcpy(str, txt);
+ strcpy(str, text);
}
- txt = (const char *)str;
- }
-
- gw->txt = txt ? txt : "";
+ gw->text = (const char *)str;
+ } else
+ gw->text = text;
_gwidgetRedraw(gh);
}
@@ -259,7 +348,20 @@ const char *gwinGetText(GHandle gh) {
if (!(gh->flags & GWIN_FLG_WIDGET))
return 0;
- return gw->txt;
+ return gw->text;
+}
+
+void gwinSetStyle(GHandle gh, const GWidgetStyle *pstyle) {
+ if (!(gh->flags & GWIN_FLG_WIDGET))
+ return;
+ gw->pstyle = pstyle ? pstyle : defaultStyle;
+ gh->bgcolor = pstyle->background;
+ gh->color = pstyle->enabled.text;
+ _gwidgetRedraw(gh);
+}
+
+const GWidgetStyle *gwinGetStyle(GHandle gh) {
+ return gw->pstyle;
}
void gwinSetCustomDraw(GHandle gh, CustomWidgetDrawFunction fn, void *param) {
diff --git a/src/gwin/gwin.c b/src/gwin/gwin.c
index 92b6cc03..2fd0c905 100644
--- a/src/gwin/gwin.c
+++ b/src/gwin/gwin.c
@@ -32,11 +32,6 @@ static color_t defaultBgColor = Black;
#if GDISP_NEED_TEXT
static font_t defaultFont;
#endif
-#if GWIN_NEED_WINDOWMANAGER
- gfxQueueASync _GWINList;
- extern GWindowManager GNullWindowManager;
- static GWindowManager * cwm;
-#endif
/*-----------------------------------------------
* Helper Routines
@@ -52,9 +47,9 @@ static color_t defaultBgColor = Black;
} else
gwinClear(gh);
}
- static void _gwm_redim(GHandle gh, const GWindowInit *pInit) {
- gh->x = pInit->x; gh->y = pInit->y;
- gh->width = pInit->width; gh->height = pInit->height;
+ static void _gwm_redim(GHandle gh, coord_t x, coord_t y, coord_t width, coord_t height) {
+ gh->x = x; gh->y = y;
+ gh->width = width; gh->height = height;
if (gh->x < 0) { gh->width += gh->x; gh->x = 0; }
if (gh->y < 0) { gh->height += gh->y; gh->y = 0; }
if (gh->x > gdispGetWidth()-MIN_WIN_WIDTH) gh->x = gdispGetWidth()-MIN_WIN_WIDTH;
@@ -87,9 +82,9 @@ void _gwinInit(void) {
_gwidgetInit();
#endif
#if GWIN_NEED_WINDOWMANAGER
- gfxQueueASyncInit(&_GWINList);
- cwm = &GNullWindowManager;
- cwm->vmt->Init();
+ extern void _gwmInit(void);
+
+ _gwmInit();
#endif
}
@@ -113,7 +108,7 @@ GHandle _gwindowCreate(GWindowObject *pgw, const GWindowInit *pInit, const gwinV
#endif
#if GWIN_NEED_WINDOWMANAGER
- if (!cwm->vmt->Add(pgw, pInit)) {
+ if (!_GWINwm->vmt->Add(pgw, pInit)) {
if ((pgw->flags & GWIN_FLG_DYNAMIC))
gfxFree(pgw);
return 0;
@@ -129,18 +124,6 @@ GHandle _gwindowCreate(GWindowObject *pgw, const GWindowInit *pInit, const gwinV
* Routines that affect all windows
*-----------------------------------------------*/
-#if GWIN_NEED_WINDOWMANAGER
- void gwinSetWindowManager(struct GWindowManager *gwm) {
- if (!gwm)
- gwm = &GNullWindowManager;
- if (cwm != gwm) {
- cwm->vmt->DeInit();
- cwm = gwm;
- cwm->vmt->Init();
- }
- }
-#endif
-
void gwinSetDefaultColor(color_t clr) {
defaultFgColor = clr;
}
@@ -171,7 +154,7 @@ color_t gwinGetDefaultBgColor(void) {
* The GWindow Routines
*-----------------------------------------------*/
-GHandle gwinCreateWindow(GWindowObject *pgw, const GWindowInit *pInit) {
+GHandle gwinWindowCreate(GWindowObject *pgw, const GWindowInit *pInit) {
if (!(pgw = _gwindowCreate(pgw, pInit, &basegwinVMT, 0)))
return 0;
gwinSetVisible(pgw, pInit->show);
@@ -181,7 +164,7 @@ GHandle gwinCreateWindow(GWindowObject *pgw, const GWindowInit *pInit) {
void gwinDestroy(GHandle gh) {
// Remove from the window manager
#if GWIN_NEED_WINDOWMANAGER
- cwm->vmt->Delete(gh);
+ _GWINwm->vmt->Delete(gh);
#endif
// Class destroy routine
@@ -204,7 +187,7 @@ void gwinSetVisible(GHandle gh, bool_t visible) {
if (!(gh->flags & GWIN_FLG_VISIBLE)) {
gh->flags |= GWIN_FLG_VISIBLE;
#if GWIN_NEED_WINDOWMANAGER
- cwm->vmt->Visible(gh);
+ _GWINwm->vmt->Visible(gh);
#else
_gwm_vis(gh);
#endif
@@ -213,7 +196,7 @@ void gwinSetVisible(GHandle gh, bool_t visible) {
if ((gh->flags & GWIN_FLG_VISIBLE)) {
gh->flags &= ~GWIN_FLG_VISIBLE;
#if GWIN_NEED_WINDOWMANAGER
- cwm->vmt->Visible(gh);
+ _GWINwm->vmt->Visible(gh);
#endif
}
}
@@ -253,7 +236,7 @@ bool_t gwinGetEnabled(GHandle gh) {
void gwinMove(GHandle gh, coord_t x, coord_t y) {
#if GWIN_NEED_WINDOWMANAGER
- cwm->vmt->Redim(gh, x, y, gh->width, gh->height);
+ _GWINwm->vmt->Redim(gh, x, y, gh->width, gh->height);
#else
_gwm_redim(gh, x, y, gh->width, gh->height);
#endif
@@ -261,44 +244,21 @@ void gwinMove(GHandle gh, coord_t x, coord_t y) {
void gwinResize(GHandle gh, coord_t width, coord_t height) {
#if GWIN_NEED_WINDOWMANAGER
- cwm->vmt->Redim(gh, gh->x, gh->y, width, height);
+ _GWINwm->vmt->Redim(gh, gh->x, gh->y, width, height);
#else
_gwm_redim(gh, gh->x, gh->y, width, height);
#endif
}
-void gwinSetMinMax(GHandle gh, GWindowMinMax minmax) {
+void gwinRedraw(GHandle gh) {
#if GWIN_NEED_WINDOWMANAGER
- cwm->vmt->MinMax(gh, minmax);
+ gwinRaise(gh);
#else
- (void) gh;
- (void) minmax;
+ if ((gh->flags & GWIN_FLG_VISIBLE))
+ _gwm_vis(gh);
#endif
}
-void gwinRaise(GHandle gh) {
- #if GWIN_NEED_WINDOWMANAGER
- cwm->vmt->Raise(gh);
- #else
- if ((gh->flags & GWIN_FLG_VISIBLE)) {
- if (gh->vmt->Redraw) {
- #if GDISP_NEED_CLIP
- gdispSetClip(gh->x, gh->y, gh->width, gh->height);
- #endif
- gh->vmt->Redraw(gh);
- }
- }
- #endif
-}
-
-GWindowMinMax gwinGetMinMax(GHandle gh) {
- if (gh->flags & GWIN_FLG_MINIMIZED)
- return GWIN_MINIMIZE;
- if (gh->flags & GWIN_FLG_MAXIMIZED)
- return GWIN_MAXIMIZE;
- return GWIN_NORMAL;
-}
-
#if GDISP_NEED_TEXT
void gwinSetFont(GHandle gh, font_t font) {
gh->font = font;
diff --git a/src/gwin/gwm.c b/src/gwin/gwm.c
index 88d61a21..f9f56838 100644
--- a/src/gwin/gwm.c
+++ b/src/gwin/gwm.c
@@ -43,10 +43,49 @@ static const gwmVMT GNullWindowManagerVMT = {
WM_MinMax,
};
-const GWindowManager GNullWindowManager = {
+static const GWindowManager GNullWindowManager = {
&GNullWindowManagerVMT,
};
+gfxQueueASync _GWINList;
+GWindowManager * _GWINwm;
+
+/*-----------------------------------------------
+ * Window Routines
+ *-----------------------------------------------*/
+
+void _gwmInit(void) {
+ gfxQueueASyncInit(&_GWINList);
+ _GWINwm = (GWindowManager *)&GNullWindowManager;
+ _GWINwm->vmt->Init();
+}
+
+void gwinSetWindowManager(struct GWindowManager *gwm) {
+ if (!gwm)
+ gwm = (GWindowManager *)&GNullWindowManager;
+ if (_GWINwm != gwm) {
+ _GWINwm->vmt->DeInit();
+ _GWINwm = gwm;
+ _GWINwm->vmt->Init();
+ }
+}
+
+void gwinSetMinMax(GHandle gh, GWindowMinMax minmax) {
+ _GWINwm->vmt->MinMax(gh, minmax);
+}
+
+void gwinRaise(GHandle gh) {
+ _GWINwm->vmt->Raise(gh);
+}
+
+GWindowMinMax gwinGetMinMax(GHandle gh) {
+ if (gh->flags & GWIN_FLG_MINIMIZED)
+ return GWIN_MINIMIZE;
+ if (gh->flags & GWIN_FLG_MAXIMIZED)
+ return GWIN_MAXIMIZE;
+ return GWIN_NORMAL;
+}
+
/*-----------------------------------------------
* Window Manager Routines
*-----------------------------------------------*/
diff --git a/src/gwin/label.c b/src/gwin/label.c
index cd469210..71ed18eb 100644
--- a/src/gwin/label.c
+++ b/src/gwin/label.c
@@ -25,38 +25,40 @@
#define GLABEL_FLG_HAUTO (GWIN_FIRST_CONTROL_FLAG<<1)
// Simple: single line with no wrapping
-static coord_t getwidth(const char *txt, font_t font, coord_t maxwidth) {
+static coord_t getwidth(const char *text, font_t font, coord_t maxwidth) {
(void) maxwidth;
- return gdispGetStringWidth(txt, font)+2; // Allow one pixel of padding on each side
+ 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 *txt, font_t font, coord_t maxwidth) {
- (void) txt;
+static coord_t getheight(const char *text, font_t font, coord_t maxwidth) {
+ (void) text;
(void) maxwidth;
return gdispGetFontMetric(font, fontHeight);
}
static void gwinLabelDefaultDraw(GWidgetObject *gw, void *param) {
- (void) param;
- coord_t w, h;
+ coord_t w, h;
+ (void) param;
- w = (gw->g.flags & GLABEL_FLG_WAUTO) ? getwidth(gw->txt, gw->g.font, gdispGetWidth() - gw->g.x) : gw->g.width;
- h = (gw->g.flags & GLABEL_FLG_HAUTO) ? getheight(gw->txt, gw->g.font, gdispGetWidth() - gw->g.x) : gw->g.height;
+ w = (gw->g.flags & GLABEL_FLG_WAUTO) ? getwidth(gw->text, gw->g.font, gdispGetWidth() - gw->g.x) : gw->g.width;
+ h = (gw->g.flags & GLABEL_FLG_HAUTO) ? getheight(gw->text, gw->g.font, gdispGetWidth() - gw->g.x) : gw->g.height;
if (gw->g.width != w || gw->g.height != h) {
gwinResize(&gw->g, w, h);
return;
}
- gdispFillStringBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, gw->txt, gw->g.font, gw->g.color, gw->g.bgcolor, justifyLeft);
+ gdispFillStringBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, gw->text, gw->g.font,
+ (gw->g.flags & GWIN_FLG_ENABLED) ? gw->pstyle->enabled.text : gw->pstyle->disabled.text, gw->pstyle->background,
+ justifyLeft);
}
static const gwidgetVMT labelVMT = {
{
"Label", // The class name
- sizeof(GLabelWidget), // The object size
+ sizeof(GLabelObject), // The object size
_gwidgetDestroy, // The destroy routine
_gwidgetRedraw, // The redraw routine
0, // The after-clear routine
@@ -88,7 +90,7 @@ static const gwidgetVMT labelVMT = {
#endif
};
-GHandle gwinLabelCreate(GLabelWidget *widget, GWidgetInit *pInit) {
+GHandle gwinLabelCreate(GLabelObject *widget, GWidgetInit *pInit) {
uint16_t flags = 0;
// auto assign width
@@ -103,7 +105,7 @@ GHandle gwinLabelCreate(GLabelWidget *widget, GWidgetInit *pInit) {
pInit->g.height = getheight(pInit->text, gwinGetDefaultFont(), gdispGetWidth() - pInit->g.x);
}
- if (!(widget = (GLabelWidget *)_gwidgetCreate(&widget->w, pInit, &labelVMT)))
+ if (!(widget = (GLabelObject *)_gwidgetCreate(&widget->w, pInit, &labelVMT)))
return 0;
widget->w.g.flags |= flags;
diff --git a/src/gwin/radio.c b/src/gwin/radio.c
index d1c65dbc..26ff0b83 100644
--- a/src/gwin/radio.c
+++ b/src/gwin/radio.c
@@ -24,25 +24,8 @@
// Our pressed state
#define GRADIO_FLG_PRESSED (GWIN_FIRST_CONTROL_FLAG<<0)
-// Default color scheme
-static const GRadioColors GRadioDefaultColorsUp = {
- HTML2COLOR(0x404040), // color_up_edge;
- HTML2COLOR(0xE0E0E0), // color_up_fill;
- HTML2COLOR(0x000000), // color_up_txt;
-};
-static const GRadioColors GRadioDefaultColorsDown = {
- HTML2COLOR(0x404040), // color_dn_edge;
- HTML2COLOR(0x808080), // color_dn_fill;
- HTML2COLOR(0x404040), // color_dn_txt;
-};
-static const GRadioColors GRadioDefaultColorsDisabled = {
- HTML2COLOR(0x808080), // color_dis_edge;
- HTML2COLOR(0xE0E0E0), // color_dis_fill;
- HTML2COLOR(0xC0C0C0), // color_dis_txt;
-};
-
// Send the button event
-static void SendButtonEvent(GWidgetObject *gw) {
+static void SendRadioEvent(GWidgetObject *gw) {
GSourceListener * psl;
GEvent * pe;
#define pbe ((GEventGWinRadio *)pe)
@@ -66,7 +49,7 @@ static void SendButtonEvent(GWidgetObject *gw) {
static void MouseDown(GWidgetObject *gw, coord_t x, coord_t y) {
(void) x; (void) y;
- gwinPressRadio((GHandle)gw);
+ gwinRadioPress((GHandle)gw);
}
#endif
@@ -75,7 +58,7 @@ static void SendButtonEvent(GWidgetObject *gw) {
static void ToggleOn(GWidgetObject *gw, uint16_t role) {
(void) role;
- gwinPressRadio((GHandle)gw);
+ gwinRadioPress((GHandle)gw);
}
static void ToggleAssign(GWidgetObject *gw, uint16_t role, uint16_t instance) {
@@ -125,7 +108,7 @@ static const gwidgetVMT radioVMT = {
#endif
};
-GHandle gwinCreateRadio(GRadioObject *gw, const GWidgetInit *pInit, uint16_t group) {
+GHandle gwinRadioCreate(GRadioObject *gw, const GWidgetInit *pInit, uint16_t group) {
if (!(gw = (GRadioObject *)_gwidgetCreate(&gw->w, pInit, &radioVMT)))
return 0;
@@ -133,53 +116,33 @@ GHandle gwinCreateRadio(GRadioObject *gw, const GWidgetInit *pInit, uint16_t gro
gw->toggle = GWIDGET_NO_INSTANCE;
#endif
gw->group = group;
- gw->c_up = GRadioDefaultColorsUp;
- gw->c_dn = GRadioDefaultColorsDown;
- gw->c_dis = GRadioDefaultColorsDisabled;
gwinSetVisible((GHandle)gw, pInit->g.show);
return (GHandle)gw;
}
-void gwinSetRadioColors(GHandle gh, const GRadioColors *pUp, const GRadioColors *pDown, const GRadioColors *pDisabled) {
- if (gh->vmt != (gwinVMT *)&radioVMT)
- return;
-
- if (pUp) ((GRadioObject *)gh)->c_up = *pUp;
- if (pDown) ((GRadioObject *)gh)->c_dn = *pDown;
- if (pDisabled) ((GRadioObject *)gh)->c_dis = *pDisabled;
-}
-
-void gwinPressRadio(GHandle gh) {
+void gwinRadioPress(GHandle gh) {
GHandle gx;
if (gh->vmt != (gwinVMT *)&radioVMT || (gh->flags & GRADIO_FLG_PRESSED))
return;
- if ((gx = gwinActiveRadio(((GRadioObject *)gh)->group))) {
+ if ((gx = gwinRadioGetActive(((GRadioObject *)gh)->group))) {
gx->flags &= ~GRADIO_FLG_PRESSED;
_gwidgetRedraw(gx);
}
gh->flags |= GRADIO_FLG_PRESSED;
_gwidgetRedraw(gh);
- SendButtonEvent((GWidgetObject *)gh);
+ SendRadioEvent((GWidgetObject *)gh);
}
-bool_t gwinIsRadioPressed(GHandle gh) {
+bool_t gwinRadioIsPressed(GHandle gh) {
if (gh->vmt != (gwinVMT *)&radioVMT)
return FALSE;
return (gh->flags & GRADIO_FLG_PRESSED) ? TRUE : FALSE;
}
-/**
- * @brief Find the currently pressed radio button in the specified group
- * @return The handle of the pressed radio button or NULL if none are pressed
- *
- * @param[in] gh The window handle (must be a radio widget)
- *
- * @api
- */
-GHandle gwinActiveRadio(uint16_t group) {
+GHandle gwinRadioGetActive(uint16_t group) {
const gfxQueueASyncItem * qi;
GHandle gh;
@@ -195,17 +158,17 @@ GHandle gwinActiveRadio(uint16_t group) {
* Custom Draw Routines
*----------------------------------------------------------*/
-static GRadioColors *getDrawColors(GWidgetObject *gw) {
- if (!(gw->g.flags & GWIN_FLG_ENABLED)) return &((GRadioObject *)gw)->c_dis;
- if ((gw->g.flags & GRADIO_FLG_PRESSED)) return &((GRadioObject *)gw)->c_dn;
- return &((GRadioObject *)gw)->c_up;
+static const GColorSet *getDrawColors(GWidgetObject *gw) {
+ if (!(gw->g.flags & GWIN_FLG_ENABLED)) return &gw->pstyle->disabled;
+ if ((gw->g.flags & GRADIO_FLG_PRESSED)) return &gw->pstyle->pressed;
+ return &gw->pstyle->enabled;
}
void gwinRadioDraw_Radio(GWidgetObject *gw, void *param) {
- #define gcw ((GRadioObject *)gw)
- coord_t ld, df;
- GRadioColors * pcol;
- (void) param;
+ #define gcw ((GRadioObject *)gw)
+ coord_t ld, df;
+ const GColorSet * pcol;
+ (void) param;
if (gw->g.vmt != (gwinVMT *)&radioVMT) return;
pcol = getDrawColors(gw);
@@ -213,46 +176,52 @@ void gwinRadioDraw_Radio(GWidgetObject *gw, void *param) {
ld = gw->g.width < gw->g.height ? gw->g.width : gw->g.height;
#if GDISP_NEED_CIRCLE
- df = ld/2;
- gdispFillArea(gw->g.x, gw->g.y, ld, ld, gw->g.bgcolor);
- gdispDrawCircle(gw->g.x+df, gw->g.y+df, df, pcol->color_edge);
+ df = (ld-1)/2;
+ gdispFillArea(gw->g.x, gw->g.y, ld, ld, gw->pstyle->background);
+ gdispDrawCircle(gw->g.x+df, gw->g.y+df, df, pcol->edge);
if (gw->g.flags & GRADIO_FLG_PRESSED)
- gdispFillCircle(gw->g.x+df, gw->g.y+df, df <= 2 ? 1 : (df-2), pcol->color_fill);
+ gdispFillCircle(gw->g.x+df, gw->g.y+df, df <= 2 ? 1 : (df-2), pcol->fill);
#else
- gdispFillArea(gw->g.x+1, gw->g.y+1, ld, ld-2, gw->g.bgcolor);
- gdispDrawBox(gw->g.x, gw->g.y, ld, ld, pcol->color_edge);
+ gdispFillArea(gw->g.x+1, gw->g.y+1, ld, ld-2, gw->pstyle->background);
+ gdispDrawBox(gw->g.x, gw->g.y, ld, ld, pcol->edge);
df = ld < 4 ? 1 : 2;
if (gw->g.flags & GRADIO_FLG_PRESSED)
- gdispFillArea(gw->g.x+df, gw->g.y+df, ld-2*df, ld-2*df, pcol->color_fill);
+ gdispFillArea(gw->g.x+df, gw->g.y+df, ld-2*df, ld-2*df, pcol->fill);
#endif
- gdispFillStringBox(gw->g.x+ld+1, gw->g.y, gw->g.width-ld-1, gw->g.height, gw->txt, gw->g.font, pcol->color_txt, gw->g.bgcolor, justifyLeft);
+ gdispFillStringBox(gw->g.x+ld+1, gw->g.y, gw->g.width-ld-1, gw->g.height, gw->text, gw->g.font, pcol->text, gw->pstyle->background, justifyLeft);
#undef gcw
}
void gwinRadioDraw_Button(GWidgetObject *gw, void *param) {
- (void) param;
- GRadioColors * pcol;
+ const GColorSet * pcol;
+ (void) param;
if (gw->g.vmt != (gwinVMT *)&radioVMT) return;
pcol = getDrawColors(gw);
- gdispFillStringBox(gw->g.x, gw->g.y, gw->g.width-1, gw->g.height-1, gw->txt, gw->g.font, pcol->color_txt, pcol->color_fill, justifyCenter);
- gdispDrawLine(gw->g.x+gw->g.width-1, gw->g.y, gw->g.x+gw->g.width-1, gw->g.y+gw->g.height-1, pcol->color_edge);
- gdispDrawLine(gw->g.x, gw->g.y+gw->g.height-1, gw->g.x+gw->g.width-2, gw->g.y+gw->g.height-1, pcol->color_edge);
+ gdispFillStringBox(gw->g.x, gw->g.y, gw->g.width-1, gw->g.height-1, gw->text, gw->g.font, pcol->text, pcol->fill, justifyCenter);
+ gdispDrawLine(gw->g.x+gw->g.width-1, gw->g.y, gw->g.x+gw->g.width-1, gw->g.y+gw->g.height-1, pcol->edge);
+ gdispDrawLine(gw->g.x, gw->g.y+gw->g.height-1, gw->g.x+gw->g.width-2, gw->g.y+gw->g.height-1, pcol->edge);
}
void gwinRadioDraw_Tab(GWidgetObject *gw, void *param) {
- (void) param;
- GRadioColors * pcol;
+ const GColorSet * pcol;
+ (void) param;
if (gw->g.vmt != (gwinVMT *)&radioVMT) return;
pcol = getDrawColors(gw);
- gdispFillStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->txt, gw->g.font, pcol->color_txt, pcol->color_fill, justifyCenter);
- gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, pcol->color_edge);
+ if ((gw->g.flags & GRADIO_FLG_PRESSED)) {
+ gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, pcol->edge);
+ gdispFillStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-1, gw->text, gw->g.font, pcol->text, pcol->fill, justifyCenter);
+ } else {
+ gdispFillStringBox(gw->g.x, gw->g.y, gw->g.width-1, gw->g.height-1, gw->text, gw->g.font, pcol->text, pcol->fill, justifyCenter);
+ gdispDrawLine(gw->g.x+gw->g.width-1, gw->g.y, gw->g.x+gw->g.width-1, gw->g.y+gw->g.height-1, pcol->edge);
+ gdispDrawLine(gw->g.x, gw->g.y+gw->g.height-1, gw->g.x+gw->g.width-2, gw->g.y+gw->g.height-1, pcol->edge);
+ }
}
#endif /* GFX_USE_GWIN && GWIN_NEED_BUTTON */
diff --git a/src/gwin/slider.c b/src/gwin/slider.c
index 5aa320f8..4d9c3510 100644
--- a/src/gwin/slider.c
+++ b/src/gwin/slider.c
@@ -29,14 +29,6 @@
#define GWIN_SLIDER_TOGGLE_INC 20 // How many toggles to go from minimum to maximum
#endif
-static const GSliderColors GSliderDefaultColors = {
- HTML2COLOR(0x404040), // color_edge
- HTML2COLOR(0x000000), // color_thumb
- HTML2COLOR(0x00E000), // color_active
- HTML2COLOR(0xE0E0E0), // color_inactive
- HTML2COLOR(0xFFFFFF), // color_txt
-};
-
// Send the slider event
static void SendSliderEvent(GWidgetObject *gw) {
GSourceListener * psl;
@@ -146,10 +138,10 @@ static void ResetDisplayPos(GSliderObject *gsw) {
#define gsw ((GSliderObject *)gw)
if (role) {
- gwinSetSliderPosition((GHandle)gw, gsw->pos+(gsw->max-gsw->min)/GWIN_SLIDER_TOGGLE_INC);
+ gwinSliderSetPosition((GHandle)gw, gsw->pos+(gsw->max-gsw->min)/GWIN_SLIDER_TOGGLE_INC);
SendSliderEvent(gw);
} else {
- gwinSetSliderPosition((GHandle)gw, gsw->pos-(gsw->max-gsw->min)/GWIN_SLIDER_TOGGLE_INC);
+ gwinSliderSetPosition((GHandle)gw, gsw->pos-(gsw->max-gsw->min)/GWIN_SLIDER_TOGGLE_INC);
SendSliderEvent(gw);
}
#undef gsw
@@ -231,7 +223,7 @@ static const gwidgetVMT sliderVMT = {
#endif
};
-GHandle gwinCreateSlider(GSliderObject *gs, const GWidgetInit *pInit) {
+GHandle gwinSliderCreate(GSliderObject *gs, const GWidgetInit *pInit) {
if (!(gs = (GSliderObject *)_gwidgetCreate(&gs->w, pInit, &sliderVMT)))
return 0;
#if GINPUT_NEED_TOGGLE
@@ -241,7 +233,6 @@ GHandle gwinCreateSlider(GSliderObject *gs, const GWidgetInit *pInit) {
#if GINPUT_NEED_DIAL
gs->dial = GWIDGET_NO_INSTANCE;
#endif
- gs->c = GSliderDefaultColors;
gs->min = 0;
gs->max = 100;
gs->pos = 0;
@@ -250,7 +241,7 @@ GHandle gwinCreateSlider(GSliderObject *gs, const GWidgetInit *pInit) {
return (GHandle)gs;
}
-void gwinSetSliderRange(GHandle gh, int min, int max) {
+void gwinSliderSetRange(GHandle gh, int min, int max) {
#define gsw ((GSliderObject *)gh)
if (gh->vmt != (gwinVMT *)&sliderVMT)
@@ -265,7 +256,7 @@ void gwinSetSliderRange(GHandle gh, int min, int max) {
#undef gsw
}
-void gwinSetSliderPosition(GHandle gh, int pos) {
+void gwinSliderSetPosition(GHandle gh, int pos) {
#define gsw ((GSliderObject *)gh)
if (gh->vmt != (gwinVMT *)&sliderVMT)
@@ -284,61 +275,70 @@ void gwinSetSliderPosition(GHandle gh, int pos) {
#undef gsw
}
-void gwinSetSliderColors(GHandle gh, const GSliderColors *pColors) {
- if (gh->vmt != (gwinVMT *)&sliderVMT)
- return;
-
- ((GSliderObject *)gh)->c = *pColors;
-}
+/*----------------------------------------------------------
+ * Custom Draw Routines
+ *----------------------------------------------------------*/
void gwinSliderDraw_Std(GWidgetObject *gw, void *param) {
- #define gsw ((GSliderObject *)gw)
- (void) param;
+ #define gsw ((GSliderObject *)gw)
+ const GColorSet * pcol;
+ (void) param;
if (gw->g.vmt != (gwinVMT *)&sliderVMT)
return;
+ if ((gw->g.flags & GWIN_FLG_ENABLED))
+ pcol = &gw->pstyle->pressed;
+ else
+ pcol = &gw->pstyle->disabled;
+
if (gw->g.width < gw->g.height) { // Vertical slider
if (gsw->dpos != gw->g.height-1)
- gdispFillArea(gw->g.x, gw->g.y+gsw->dpos, gw->g.width, gw->g.height - gsw->dpos, gsw->c.color_active);
+ gdispFillArea(gw->g.x, gw->g.y+gsw->dpos, gw->g.width, gw->g.height - gsw->dpos, pcol->progress); // Active Area
if (gsw->dpos != 0)
- gdispFillArea(gw->g.x, gw->g.y, gw->g.width, gsw->dpos, gsw->c.color_inactive);
- gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, gsw->c.color_edge);
- gdispDrawLine(gw->g.x, gw->g.y+gsw->dpos, gw->g.x+gw->g.width-1, gw->g.y+gsw->dpos, gsw->c.color_thumb);
+ gdispFillArea(gw->g.x, gw->g.y, gw->g.width, gsw->dpos, gw->pstyle->enabled.progress); // Inactive area
+ gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, pcol->edge); // Edge
+ gdispDrawLine(gw->g.x, gw->g.y+gsw->dpos, gw->g.x+gw->g.width-1, gw->g.y+gsw->dpos, pcol->edge); // Thumb
if (gsw->dpos >= 2)
- gdispDrawLine(gw->g.x, gw->g.y+gsw->dpos-2, gw->g.x+gw->g.width-1, gw->g.y+gsw->dpos-2, gsw->c.color_thumb);
+ gdispDrawLine(gw->g.x, gw->g.y+gsw->dpos-2, gw->g.x+gw->g.width-1, gw->g.y+gsw->dpos-2, pcol->edge); // Thumb
if (gsw->dpos <= gw->g.height-2)
- gdispDrawLine(gw->g.x, gw->g.y+gsw->dpos+2, gw->g.x+gw->g.width-1, gw->g.y+gsw->dpos+2, gsw->c.color_thumb);
+ gdispDrawLine(gw->g.x, gw->g.y+gsw->dpos+2, gw->g.x+gw->g.width-1, gw->g.y+gsw->dpos+2, pcol->edge); // Thumb
// Horizontal slider
} else {
if (gsw->dpos != gw->g.width-1)
- gdispFillArea(gw->g.x+gsw->dpos, gw->g.y, gw->g.width-gsw->dpos, gw->g.height, gsw->c.color_inactive);
+ gdispFillArea(gw->g.x+gsw->dpos, gw->g.y, gw->g.width-gsw->dpos, gw->g.height, gw->pstyle->enabled.progress); // Inactive area
if (gsw->dpos != 0)
- gdispFillArea(gw->g.x, gw->g.y, gsw->dpos, gw->g.height, gsw->c.color_active);
- gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, gsw->c.color_edge);
- gdispDrawLine(gw->g.x+gsw->dpos, gw->g.y, gw->g.x+gsw->dpos, gw->g.y+gw->g.height-1, gsw->c.color_thumb);
+ gdispFillArea(gw->g.x, gw->g.y, gsw->dpos, gw->g.height, pcol->progress); // Active Area
+ gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, pcol->edge); // Edge
+ gdispDrawLine(gw->g.x+gsw->dpos, gw->g.y, gw->g.x+gsw->dpos, gw->g.y+gw->g.height-1, pcol->edge); // Thumb
if (gsw->dpos >= 2)
- gdispDrawLine(gw->g.x+gsw->dpos-2, gw->g.y, gw->g.x+gsw->dpos-2, gw->g.y+gw->g.height-1, gsw->c.color_thumb);
+ gdispDrawLine(gw->g.x+gsw->dpos-2, gw->g.y, gw->g.x+gsw->dpos-2, gw->g.y+gw->g.height-1, pcol->edge); // Thumb
if (gsw->dpos <= gw->g.width-2)
- gdispDrawLine(gw->g.x+gsw->dpos+2, gw->g.y, gw->g.x+gsw->dpos+2, gw->g.y+gw->g.height-1, gsw->c.color_thumb);
+ gdispDrawLine(gw->g.x+gsw->dpos+2, gw->g.y, gw->g.x+gsw->dpos+2, gw->g.y+gw->g.height-1, pcol->edge); // Thumb
}
- gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->txt, gw->g.font, gsw->c.color_txt, justifyCenter);
+ gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->text, gw->g.font, pcol->text, justifyCenter);
#undef gsw
}
void gwinSliderDraw_Image(GWidgetObject *gw, void *param) {
- #define gsw ((GSliderObject *)gw)
- #define gi ((gdispImage *)param)
- coord_t z, v;
+ #define gsw ((GSliderObject *)gw)
+ #define gi ((gdispImage *)param)
+ const GColorSet * pcol;
+ coord_t z, v;
if (gw->g.vmt != (gwinVMT *)&sliderVMT)
return;
+ if ((gw->g.flags & GWIN_FLG_ENABLED))
+ pcol = &gw->pstyle->pressed;
+ else
+ pcol = &gw->pstyle->disabled;
+
if (gw->g.width < gw->g.height) { // Vertical slider
if (gsw->dpos != 0) // The unfilled area
- gdispFillArea(gw->g.x, gw->g.y, gw->g.width, gsw->dpos, gsw->c.color_inactive);
+ gdispFillArea(gw->g.x, gw->g.y, gw->g.width, gsw->dpos, gw->pstyle->enabled.progress); // Inactive area
if (gsw->dpos != gw->g.height-1) { // The filled area
for(z=gw->g.height, v=gi->height; z > gsw->dpos;) {
z -= v;
@@ -349,13 +349,13 @@ void gwinSliderDraw_Image(GWidgetObject *gw, void *param) {
gdispImageDraw(gi, gw->g.x, gw->g.y+z, gw->g.width, v, 0, gi->height-v);
}
}
- gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, gsw->c.color_edge);
- gdispDrawLine(gw->g.x, gw->g.y+gsw->dpos, gw->g.x+gw->g.width-1, gw->g.y+gsw->dpos, gsw->c.color_thumb);
+ gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, pcol->edge); // Edge
+ gdispDrawLine(gw->g.x, gw->g.y+gsw->dpos, gw->g.x+gw->g.width-1, gw->g.y+gsw->dpos, pcol->edge); // Thumb
// Horizontal slider
} else {
if (gsw->dpos != gw->g.width-1) // The unfilled area
- gdispFillArea(gw->g.x+gsw->dpos, gw->g.y, gw->g.width-gsw->dpos, gw->g.height, gsw->c.color_inactive);
+ gdispFillArea(gw->g.x+gsw->dpos, gw->g.y, gw->g.width-gsw->dpos, gw->g.height, gw->pstyle->enabled.progress); // Inactive area
if (gsw->dpos != 0) { // The filled area
for(z=0, v=gi->width; z < gsw->dpos; z += v) {
if (z+v > gsw->dpos)
@@ -363,10 +363,10 @@ void gwinSliderDraw_Image(GWidgetObject *gw, void *param) {
gdispImageDraw(gi, gw->g.x+z, gw->g.y, v, gw->g.height, 0, 0);
}
}
- gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, gsw->c.color_edge);
- gdispDrawLine(gw->g.x+gsw->dpos, gw->g.y, gw->g.x+gsw->dpos, gw->g.y+gw->g.height-1, gsw->c.color_thumb);
+ gdispDrawBox(gw->g.x, gw->g.y, gw->g.width, gw->g.height, pcol->edge); // Edge
+ gdispDrawLine(gw->g.x+gsw->dpos, gw->g.y, gw->g.x+gsw->dpos, gw->g.y+gw->g.height-1, pcol->edge); // Thumb
}
- gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->txt, gw->g.font, gsw->c.color_txt, justifyCenter);
+ gdispDrawStringBox(gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->text, gw->g.font, pcol->text, justifyCenter);
#undef gsw
}