aboutsummaryrefslogtreecommitdiffstats
path: root/demos/modules/ginput_touch_driver_test/main.c
diff options
context:
space:
mode:
authorAndrew Hannam <andrewh@inmarket.com.au>2012-12-06 00:36:11 -0800
committerAndrew Hannam <andrewh@inmarket.com.au>2012-12-06 00:36:11 -0800
commite236a0a6b79ccd4446df72256740913392cf12f7 (patch)
tree3ddf6ab5df736bbea7ea814e3cc86b49587fa187 /demos/modules/ginput_touch_driver_test/main.c
parent74e94d39b9b66adeaf8bcbb8789d79110102bb15 (diff)
parent09fc35864aa695cc46dcb95ed3951a365622b709 (diff)
downloaduGFX-e236a0a6b79ccd4446df72256740913392cf12f7.tar.gz
uGFX-e236a0a6b79ccd4446df72256740913392cf12f7.tar.bz2
uGFX-e236a0a6b79ccd4446df72256740913392cf12f7.zip
Merge pull request #11 from Tectu/master
Merge Tectu Changes
Diffstat (limited to 'demos/modules/ginput_touch_driver_test/main.c')
-rw-r--r--demos/modules/ginput_touch_driver_test/main.c22
1 files changed, 20 insertions, 2 deletions
diff --git a/demos/modules/ginput_touch_driver_test/main.c b/demos/modules/ginput_touch_driver_test/main.c
index dc8bb0f9..78f29f86 100644
--- a/demos/modules/ginput_touch_driver_test/main.c
+++ b/demos/modules/ginput_touch_driver_test/main.c
@@ -18,6 +18,24 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+/*
+ * Make sure you have the following enabled in your halconf.h:
+ *
+ * #define GFX_USE_GDISP TRUE
+ * #define GFX_USE_GINPUT TRUE
+ * #define GFX_USE_GEVENT TRUE
+ * #define GFX_USE_GTIMER TRUE
+ * #define GFX_USE_GWIN TRUE
+ *
+ * #define GWIN_NEED_CONSOLE TRUE
+ * #define GWIN_NEED_BUTTON TRUE
+ *
+ * #define GINPUT_NEED_MOUSE TRUE
+ * #define GINPUT_NEED_TOUCH TRUE
+ *
+ * #define GDISP_NEED_CLIP TRUE
+ */
+
#include "ch.h"
#include "hal.h"
#include "chprintf.h"
@@ -53,7 +71,7 @@ int main(void) {
ghNext = ghPrev = 0;
// Create our title
- gdispFillStringBox(0, 0, swidth, 20, "Touch Calibration", &fontUI2, Red, White, justifyCenter);
+ gdispFillStringBox(0, 0, swidth, 20, "Touch Calibration", &fontUI2, Red, White, justifyLeft);
// Create our main display window
ghc = gwinCreateConsole(&gc, 0, 20, swidth, sheight-20, &fontUI2);
@@ -228,7 +246,7 @@ StepCalibrate:
}
// Calibration used the whole screen - re-establish our title
- gdispFillStringBox(0, 0, swidth, 20, "Touch Calibration", &fontUI2, Green, White, justifyCenter);
+ gdispFillStringBox(0, 0, swidth, 20, "Touch Calibration", &fontUI2, Green, White, justifyLeft);
gwinButtonDraw(ghNext);
gwinButtonDraw(ghPrev);