aboutsummaryrefslogtreecommitdiff
path: root/demo.c
diff options
context:
space:
mode:
authorPaul LeoNerd Evans <leonerd@leonerd.org.uk>2012-11-30 16:12:26 +0000
committerPaul LeoNerd Evans <leonerd@leonerd.org.uk>2012-11-30 16:12:26 +0000
commitc00f6cd3c63e01c84220b607eccf5a2ba2df8f63 (patch)
treeb7b183e4235f6bf88aaac1964a35ea8ea598ee86 /demo.c
parentefc5b7e088fc219993f22dc827022b143913c1f8 (diff)
downloadtermo-c00f6cd3c63e01c84220b607eccf5a2ba2df8f63.tar.gz
termo-c00f6cd3c63e01c84220b607eccf5a2ba2df8f63.tar.xz
termo-c00f6cd3c63e01c84220b607eccf5a2ba2df8f63.zip
Only recognise DECCPR as a position report, so it is distinct from F3
Diffstat (limited to 'demo.c')
-rw-r--r--demo.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/demo.c b/demo.c
index 646fe9a..2cd8ebc 100644
--- a/demo.c
+++ b/demo.c
@@ -61,12 +61,12 @@ int main(int argc, char *argv[])
if(key.type == TERMKEY_TYPE_MOUSE) {
int line, col;
termkey_interpret_mouse(tk, &key, NULL, NULL, &line, &col);
- printf("%s at line=%d, col=%d)\n", buffer, line, col);
+ printf("%s at line=%d, col=%d\n", buffer, line, col);
}
else if(key.type == TERMKEY_TYPE_POSITION) {
int line, col;
termkey_interpret_position(tk, &key, &line, &col);
- printf("Cursor position report at line=%d, col=%d)\n", line, col);
+ printf("Cursor position report at line=%d, col=%d\n", line, col);
}
else {
printf("%s\n", buffer);
@@ -80,7 +80,7 @@ int main(int argc, char *argv[])
if(key.type == TERMKEY_TYPE_UNICODE &&
key.modifiers == 0 &&
key.code.codepoint == '?') {
- printf("\033[6n");
+ printf("\033[?6n");
fflush(stdout);
}
}