93 - new project: a text-mode editor

New planet racket dependency: neil/charterm:3:1
This commit is contained in:
Kartik K. Agaram 2014-10-04 20:18:55 -07:00
parent 033d558a10
commit 6e56bf32cc
1 changed files with 17 additions and 0 deletions

17
mu.arc
View File

@ -196,6 +196,8 @@
(if (~empty context)
(enq context contexts*))))))
($:require "charterm/main.rkt")
(def run-for-time-slice (context time-slice)
;? (prn "AAA")
(point return
@ -428,3 +430,18 @@
(map add-fns:readfile it)
(run 'main)
(prn memory*))
($:with-charterm
(charterm-clear-screen)
(charterm-cursor 10 5)
(charterm-display "Hello, ")
(charterm-bold)
(charterm-display "you")
(charterm-normal)
(charterm-display ".")
(charterm-cursor 1 1)
(charterm-display "Press a key...")
(let ((key (charterm-read-key)))
(charterm-cursor 1 1)
(charterm-clear-line)
(printf "You pressed: ~S\r\n" key)))