clean up formatting on gmi:render procedure and document
This commit is contained in:
8
gmi.rkt
8
gmi.rkt
@@ -125,9 +125,13 @@
|
|||||||
(map string-join (outer-iter (list) (string-split paragraph))))
|
(map string-join (outer-iter (list) (string-split paragraph))))
|
||||||
(newline)))
|
(newline)))
|
||||||
|
|
||||||
|
;; given a document, which is a list of structs, render it out into
|
||||||
|
;; the current output port exactly as it will be shown to the user
|
||||||
(define (render document)
|
(define (render document)
|
||||||
(for-each (λ (line)
|
(for-each
|
||||||
(cond [(text? line)
|
(λ (line)
|
||||||
|
(cond
|
||||||
|
[(text? line)
|
||||||
(render-paragraph (text-str line))]
|
(render-paragraph (text-str line))]
|
||||||
|
|
||||||
[(pre? line)
|
[(pre? line)
|
||||||
|
Reference in New Issue
Block a user