From 6b343a82f29b6dea219504504244591c3042df43 Mon Sep 17 00:00:00 2001 From: Kartik Agaram Date: Sat, 1 Aug 2020 23:06:41 -0700 Subject: 6699 - start building out fake screen We now have all existing apps and prototypes going through the dependency-injected wrapper, even though it doesn't actually implement the fake screen yet. --- prototypes/browse/20/file-state.mu | 2 +- prototypes/browse/20/screen-position-state.mu | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'prototypes/browse/20') diff --git a/prototypes/browse/20/file-state.mu b/prototypes/browse/20/file-state.mu index 0047b2c0..544c7832 100644 --- a/prototypes/browse/20/file-state.mu +++ b/prototypes/browse/20/file-state.mu @@ -39,6 +39,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 } diff --git a/prototypes/browse/20/screen-position-state.mu b/prototypes/browse/20/screen-position-state.mu index 187b81b6..41ad2705 100644 --- a/prototypes/browse/20/screen-position-state.mu +++ b/prototypes/browse/20/screen-position-state.mu @@ -18,7 +18,7 @@ fn init-screen-position-state _self: (addr screen-position-state) { var self/esi: (addr screen-position-state) <- copy _self var nrows/eax: int <- copy 0 var ncols/ecx: int <- copy 0 - nrows, ncols <- screen-size + nrows, ncols <- screen-size 0 var dest/edx: (addr int) <- copy 0 # self->nrows = nrows dest <- get self, nrows @@ -71,7 +71,7 @@ $add-char:body: { break $add-char:body } # print c - print-byte-to-screen c + print-byte 0, c # self->col++ var tmp/eax: (addr int) <- get self, col increment *tmp @@ -140,5 +140,5 @@ fn reposition-cursor _self: (addr screen-position-state) { var self/esi: (addr screen-position-state) <- copy _self var r/eax: (addr int) <- get self, row var c/ecx: (addr int) <- get self, col - move-cursor-on-screen *r *c + move-cursor 0, *r *c } -- cgit 1.4.1-2-gfad0 alue='author'>author
path: root/docs/profanity.1
blob: 3f16a2db79211063262a993a72ae3df39881bbdf (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78