implements frames on table
This commit is contained in:
parent
8107305224
commit
a7f914acf4
16
draw.rkt
16
draw.rkt
|
@ -316,19 +316,21 @@
|
||||||
cell-h #:valign row-valign
|
cell-h #:valign row-valign
|
||||||
(inset dw dh col)))
|
(inset dw dh col)))
|
||||||
(define cell+left
|
(define cell+left
|
||||||
(happend cell-wall the-cell))
|
(if frames? (happend cell-wall the-cell) the-cell))
|
||||||
(if (= col-i last-col)
|
(if (and frames? (= col-i last-col))
|
||||||
(happend cell+left cell-wall)
|
(happend cell+left cell-wall)
|
||||||
cell+left))))
|
cell+left))))
|
||||||
(define include-header? (zero? row-i))
|
(define include-header? (zero? row-i))
|
||||||
(define row-and-above
|
(define row-and-above
|
||||||
(if include-header? (vappend header the-row) the-row))
|
(if (and frames? include-header?) (vappend header the-row) the-row))
|
||||||
(define include-footer? (= row-i last-row))
|
(define include-footer? (= row-i last-row))
|
||||||
(define row-and-below
|
(define row-and-below
|
||||||
(vappend row-and-above
|
(if frames?
|
||||||
(if include-footer?
|
(vappend row-and-above
|
||||||
footer
|
(if include-footer?
|
||||||
inbetween)))
|
footer
|
||||||
|
inbetween))
|
||||||
|
row-and-above))
|
||||||
row-and-below)))
|
row-and-below)))
|
||||||
(define (text-rows rows)
|
(define (text-rows rows)
|
||||||
(local-require racket/format)
|
(local-require racket/format)
|
||||||
|
|
Loading…
Reference in New Issue