summaryrefslogtreecommitdiffstats
path: root/include/readkey.h
diff options
context:
space:
mode:
authorJean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>2010-08-20 10:22:47 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2010-08-30 20:57:20 +0200
commitb712b26632d4af1e1c9454a3b330ed7b401e165b (patch)
treedecefbfa56cfc958731d7455cf0aab6605e5d5e4 /include/readkey.h
parent0db2f6367712cafd91460af7816f1180fa1b5446 (diff)
downloadbarebox-b712b26632d4af1e1c9454a3b330ed7b401e165b.tar.gz
barebox-b712b26632d4af1e1c9454a3b330ed7b401e165b.tar.xz
Add Menu Framework
Introduce a menu framework that allow us to create list menu to simplify barebox and make it more user-frendly This kind of menu is very usefull when you do not have a keyboard or a serial console attached to your board to allow you to interract with barebox For the develloper part, The framework introduce two API 1) C that allow you to create menu, submenu, entry and complex menu action 2) Command that allow you as the C API to create menu, submenu, entry and complex menu action but this time the actions will be store in a function and then be evaluated and excecuted at runtime. Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/readkey.h')
-rw-r--r--include/readkey.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/readkey.h b/include/readkey.h
index 919af6421b..aabb835e89 100644
--- a/include/readkey.h
+++ b/include/readkey.h
@@ -22,6 +22,11 @@
#define ANSI_CLEAR_SCREEN "\e[2J\e[;H"
+#define printf_reverse(fmt,args...) printf("\e[7m" fmt "\e[m",##args)
+#define puts_reverse(fmt) puts("\e[7m" fmt "\e[m")
+#define gotoXY(row, col) printf("\e[%d;%dH", row, col)
+#define clear() puts("\e[2J")
+
int read_key(void);
#endif /* READKEY_H */