summaryrefslogtreecommitdiffstats
path: root/src/include
diff options
context:
space:
mode:
authorMichael Brown2013-12-02 18:20:36 +0100
committerMichael Brown2013-12-02 18:20:36 +0100
commit135bf35b1189a4402dcca13685331c3fb2d901f5 (patch)
treeb95a0652759472957c53f61915062ef28424ee62 /src/include
parent[build] Fix building on OpenBSD 5.4 (diff)
downloadipxe-135bf35b1189a4402dcca13685331c3fb2d901f5.tar.gz
ipxe-135bf35b1189a4402dcca13685331c3fb2d901f5.tar.xz
ipxe-135bf35b1189a4402dcca13685331c3fb2d901f5.zip
[console] Allow '?' as an intermediate byte in ANSI escape sequences
The ANSI escape sequences to show and hide the cursor take the form "<ESC>[?25h" and "<ESC>[?25l" respectively. iPXE currently treats the '?' character as the final byte. Fix by explicitly treating '?' as an intermediate byte. Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/include')
-rw-r--r--src/include/ipxe/ansiesc.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/include/ipxe/ansiesc.h b/src/include/ipxe/ansiesc.h
index e84545769..c1c74481d 100644
--- a/src/include/ipxe/ansiesc.h
+++ b/src/include/ipxe/ansiesc.h
@@ -124,6 +124,12 @@ struct ansiesc_context {
*/
#define ANSIESC_LOG_PRIORITY 'p'
+/** Show cursor */
+#define ANSIESC_DECTCEM_SET ( ( '?' << 8 ) | 'h' )
+
+/** Hide cursor */
+#define ANSIESC_DECTCEM_RESET ( ( '?' << 8 ) | 'l' )
+
/** @} */
extern int ansiesc_process ( struct ansiesc_context *ctx, int c );