From ccadba5b955c55560cdbec38aa42bda3e397a127 Mon Sep 17 00:00:00 2001 From: Kartik Agaram Date: Mon, 31 May 2021 20:10:34 -0700 Subject: . Until we get scrolling on functions, it's a little cleaner to draw the primitives on top. --- shell/global.mu | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'shell') diff --git a/shell/global.mu b/shell/global.mu index 860deea6..ff6df88c 100644 --- a/shell/global.mu +++ b/shell/global.mu @@ -162,8 +162,6 @@ fn render-globals screen: (addr screen), _self: (addr global-table) { abort "render globals" return } - # render primitives - render-primitives screen, 1/xmin=padding-left, 0x55/xmax, 0x2f/ymax var data-ah/eax: (addr handle array global) <- get self, data var data/eax: (addr array global) <- lookup *data-ah var curr-index/edx: int <- copy 1 @@ -220,11 +218,15 @@ fn render-globals screen: (addr screen), _self: (addr global-table) { curr-index <- decrement loop } + # render primitives on top + render-primitives screen, 1/xmin=padding-left, 0x55/xmax, 0x2f/ymax } fn render-primitives screen: (addr screen), xmin: int, xmax: int, ymax: int { var y/ecx: int <- copy ymax - y <- subtract 0xf + y <- subtract 0x10 + clear-rect screen, xmin, y, xmax, ymax, 0xdc/bg=green-bg + y <- increment var tmpx/eax: int <- copy xmin tmpx <- draw-text-rightward screen, "cursor graphics", tmpx, xmax, y, 7/fg=grey, 0xdc/bg=green-bg y <- increment -- cgit 1.4.1-2-gfad0