about summary refs log tree commit diff stats
path: root/apps
diff options
context:
space:
mode:
Diffstat (limited to 'apps')
-rw-r--r--apps/tui.mu (renamed from apps/screen.mu)9
1 files changed, 9 insertions, 0 deletions
diff --git a/apps/screen.mu b/apps/tui.mu
index 4f36809e..e2f97609 100644
--- a/apps/screen.mu
+++ b/apps/tui.mu
@@ -16,5 +16,14 @@ fn main -> exit-status/ebx: int {
   print-string " rows, "
   print-int32-to-screen ncols
   print-string " rows\n"
+
+  print-string "press a key to see its code: "
+  enable-keyboard-immediate-mode
+  var x/eax: byte <- read-key
+  enable-keyboard-type-mode
+  enable-screen-type-mode
+  print-string "You pressed "
+  print-int32-to-screen x
+  print-string "\n"
   exit-status <- copy 0
 }