about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--cpp/070display (renamed from cpp/070console)16
-rw-r--r--cpp/display.mu (renamed from cpp/console.mu)4
2 files changed, 12 insertions, 8 deletions
diff --git a/cpp/070console b/cpp/070display
index dcb6da96..a64aa550 100644
--- a/cpp/070console
+++ b/cpp/070display
@@ -1,4 +1,8 @@
 //: Text-mode cursor primitives. Currently thin wrappers around ncurses calls.
+//: Mu starts out at the 'console' where lines wrap and scrolling is
+//: automatic, where keys aren't read until pressing <enter>.
+//: This file provides mechanisms for opening a 'display' and taking raw
+//: charge of the cursor and keyboard.
 
 :(before "End Includes")
 #include<ncurses.h>
@@ -6,21 +10,21 @@
 //:: Display management
 
 :(before "End Primitive Recipe Declarations")
-CURSOR_MODE,
+SWITCH_TO_DISPLAY,
 :(before "End Primitive Recipe Numbers")
-Recipe_number["cursor-mode"] = CURSOR_MODE;
+Recipe_number["switch-to-display"] = SWITCH_TO_DISPLAY;
 :(before "End Primitive Recipe Implementations")
-case CURSOR_MODE: {
+case SWITCH_TO_DISPLAY: {
   initscr();
   break;
 }
 
 :(before "End Primitive Recipe Declarations")
-RETRO_MODE,
+RETURN_TO_CONSOLE,
 :(before "End Primitive Recipe Numbers")
-Recipe_number["retro-mode"] = RETRO_MODE;
+Recipe_number["return-to-console"] = RETURN_TO_CONSOLE;
 :(before "End Primitive Recipe Implementations")
-case RETRO_MODE: {
+case RETURN_TO_CONSOLE: {
   endwin();
   break;
 }
diff --git a/cpp/console.mu b/cpp/display.mu
index d83619c7..fa5f3b85 100644
--- a/cpp/console.mu
+++ b/cpp/display.mu
@@ -1,5 +1,5 @@
 recipe main [
-  cursor-mode 0:literal/screen
+  switch-to-display
   print-character-to-display 97:literal
   1:integer/raw, 2:integer/raw <- cursor-position-on-display
   $print 1:integer/raw
@@ -15,5 +15,5 @@ recipe main [
   move-cursor-on-display 0:literal, 0:literal
   clear-line-on-display
   wait-for-key-from-keyboard
-  retro-mode 0:literal/screen
+  return-to-console
 ]