about summary refs log tree commit diff stats
path: root/baremetal/rpn.mu
diff options
context:
space:
mode:
authorKartik Agaram <vc@akkartik.com>2021-02-07 15:50:16 -0800
committerKartik Agaram <vc@akkartik.com>2021-02-07 15:50:16 -0800
commit8f34dfd1e09e9e33176bba8f05a2ec229cf3b56f (patch)
tree2a627da04cef70f856a712e9bd56d186c30aa8bc /baremetal/rpn.mu
parentf626421bc4f526c48b789914a3a1e088a9250278 (diff)
downloadmu-8f34dfd1e09e9e33176bba8f05a2ec229cf3b56f.tar.gz
7693 - baremetal: pass background color everywhere
Diffstat (limited to 'baremetal/rpn.mu')
-rw-r--r--baremetal/rpn.mu8
1 files changed, 4 insertions, 4 deletions
diff --git a/baremetal/rpn.mu b/baremetal/rpn.mu
index b309409f..65959957 100644
--- a/baremetal/rpn.mu
+++ b/baremetal/rpn.mu
@@ -23,7 +23,7 @@ fn main -> _/ebx: int {
   # read-eval-print loop
   {
     # print prompt
-    var x/eax: int <- draw-text-rightward 0/screen, "> ", 0/x, 0x80/xmax, y, 3/cyan
+    var x/eax: int <- draw-text-rightward 0/screen, "> ", 0/x, 0x80/xmax, y, 3/fg/cyan, 0/bg
     set-cursor-position 0/screen, x, y
     # read line from keyboard
     clear-stream in
@@ -37,17 +37,17 @@ fn main -> _/ebx: int {
       var key2/eax: int <- copy key
       append-byte in, key2
       var g/eax: grapheme <- copy key2
-      draw-grapheme-at-cursor 0/screen, g, 0xf
+      draw-grapheme-at-cursor 0/screen, g, 0xf/fg, 0/bg
       cursor-right 0
       loop
     }
     # clear cursor
-    draw-grapheme-at-cursor 0/screen, space, 3/fg/never-used
+    draw-grapheme-at-cursor 0/screen, space, 3/fg/never-used, 0/bg
     # parse and eval
     var out/eax: int <- simplify in
     # print
     y <- increment
-    out, y <- draw-int32-decimal-wrapping-right-then-down 0/screen, out, 0/xmin, y, 0x80/xmax, 0x30/ymax, 0/x, y, 7/fg
+    out, y <- draw-int32-decimal-wrapping-right-then-down 0/screen, out, 0/xmin, y, 0x80/xmax, 0x30/ymax, 0/x, y, 7/fg, 0/bg
     # newline
     y <- increment
     #