about summary refs log tree commit diff stats
path: root/prototypes/browse/10.mu
diff options
context:
space:
mode:
Diffstat (limited to 'prototypes/browse/10.mu')
-rw-r--r--prototypes/browse/10.mu22
1 files changed, 11 insertions, 11 deletions
diff --git a/prototypes/browse/10.mu b/prototypes/browse/10.mu
index cd0f748b..834fec90 100644
--- a/prototypes/browse/10.mu
+++ b/prototypes/browse/10.mu
@@ -9,7 +9,7 @@ fn main args: (addr array (addr array byte)) -> exit-status/ebx: int {
   enable-screen-grid-mode
   var nrows/eax: int <- copy 0
   var ncols/ecx: int <- copy 0
-  nrows, ncols <- screen-size
+  nrows, ncols <- screen-size 0
   enable-keyboard-immediate-mode
   {
     render file, nrows, ncols
@@ -44,7 +44,7 @@ fn render in: (addr buffered-file), nrows: int, ncols: int {
   var leftcol/edx: int <- copy 5  # page-margin
   var rightcol/ebx: int <- copy leftcol
   rightcol <- add 0x40  # page-width = 64 characters
-  start-color-on-screen 0xec, 7  # 236 = darkish gray
+  start-color 0, 0xec, 7  # 236 = darkish gray
   {
     compare rightcol, ncols
     break-if->=
@@ -64,7 +64,7 @@ $line-loop: {
     compare row, botrow
     break-if->=
     var col/edx: int <- copy leftcol
-    move-cursor-on-screen row, col
+    move-cursor 0, row, col
     {
       compare col, rightcol
       break-if->=
@@ -75,7 +75,7 @@ $line-loop: {
       compare c, 0xa  # newline
       break-if-=  # no need to print newlines
       # print c
-      print-byte-to-screen c
+      print-byte 0, c
       col <- increment
       loop
     }  # $char-loop
@@ -95,7 +95,7 @@ $check-state: {
       {
         break-if-!=
         # r->current-state == 0 && c == '*' => bold text
-        start-bold-on-screen
+        start-bold 0
         copy-to *state, 1
         break $check-state
       }
@@ -103,7 +103,7 @@ $check-state: {
       {
         break-if-!=
         # r->current-state == 0 && c == '_' => bold text
-        start-bold-on-screen
+        start-bold 0
         copy-to *state, 1
         break $check-state
       }
@@ -115,7 +115,7 @@ $check-state: {
       {
         break-if-!=
         # r->current-state == 1 && c == '*' => normal text
-        reset-formatting-on-screen
+        reset-formatting 0
         copy-to *state, 0
         break $check-state
       }
@@ -123,7 +123,7 @@ $check-state: {
       {
         break-if-!=
         # r->current-state == 1 && c == '_' => normal text
-        reset-formatting-on-screen
+        reset-formatting 0
         copy-to *state, 0
         break $check-state
       }
@@ -138,11 +138,11 @@ fn clear toprow: int, leftcol: int, botrow: int, rightcol: int {
     compare row, botrow
     break-if->=
     var col/edx: int <- copy leftcol
-    move-cursor-on-screen row, col
+    move-cursor 0, row, col
     {
       compare col, rightcol
       break-if->=
-      print-string-to-screen " "
+      print-string 0, " "
       col <- increment
       loop
     }
@@ -171,6 +171,6 @@ fn dump in: (addr buffered-file) {
   var c/eax: byte <- read-byte-buffered in
   compare c, 0xffffffff  # EOF marker
   break-if-=
-  print-byte-to-screen c
+  print-byte 0, c
   loop
 }