summaryrefslogtreecommitdiff
path: root/src/guile
diff options
context:
space:
mode:
authorLudovic Courtès2008-03-06 17:13:13 +0100
committerLudovic Courtès2008-03-06 17:13:13 +0100
commit45d172a9a2dbf865de095df88bc9be79f96ad8c9 (patch)
tree74c6c4bfe00f278be8df4a95f87ee6358347497a /src/guile
parent270d306388ec76c81c515386ebf83c060c293d40 (diff)
downloadskribilo-45d172a9a2dbf865de095df88bc9be79f96ad8c9.tar.gz
skribilo-45d172a9a2dbf865de095df88bc9be79f96ad8c9.tar.lz
skribilo-45d172a9a2dbf865de095df88bc9be79f96ad8c9.zip
`base' package: Add `:rulecolor' option to `table'.
* NEWS, doc/user/colframe.skb, doc/user/table.skb: Update. * src/guile/skribilo/engine/lout.scm (table): Support `:rulecolor'. * src/guile/skribilo/package/base.scm (table): Support `:rulecolor'.
Diffstat (limited to 'src/guile')
-rw-r--r--src/guile/skribilo/engine/lout.scm6
-rw-r--r--src/guile/skribilo/package/base.scm8
2 files changed, 11 insertions, 3 deletions
diff --git a/src/guile/skribilo/engine/lout.scm b/src/guile/skribilo/engine/lout.scm
index b924b2b..64e8634 100644
--- a/src/guile/skribilo/engine/lout.scm
+++ b/src/guile/skribilo/engine/lout.scm
@@ -2274,7 +2274,7 @@
;* table ... */
;*---------------------------------------------------------------------*/
(markup-writer 'table
- :options '(:frame :rules :border :width :cellpadding)
+ :options '(:frame :rules :border :width :cellpadding :rulecolor)
;; XXX: `:cellstyle' `separate' and `:cellspacing' not supported
;; by Lout's @Tbl.
:before (lambda (n e)
@@ -2305,6 +2305,10 @@
(if (number? cp)
(format #t " margin { ~ap }\n"
(number->string cp)))
+ (let ((rule-color (markup-option n :rulecolor)))
+ (and rule-color
+ (format #t " rulecolor { ~a }~%"
+ (lout-color-specification rule-color))))
(display "{\n")))
diff --git a/src/guile/skribilo/package/base.scm b/src/guile/skribilo/package/base.scm
index a4443dc..8462e81 100644
--- a/src/guile/skribilo/package/base.scm
+++ b/src/guile/skribilo/package/base.scm
@@ -1,6 +1,6 @@
;;; base.scm -- The base markup package of Skribe/Skribilo.
;;;
-;;; Copyright 2005, 2006, 2007 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright 2005, 2006, 2007, 2008 Ludovic Courtès <ludo@gnu.org>
;;; Copyright 2003, 2004 Manuel Serrano
;;;
;;;
@@ -697,7 +697,8 @@
(ident #f) (class #f) (&location #f)
(border #f) (width #f)
(frame 'none) (rules 'none)
- (cellstyle 'collapse) (cellpadding #f) (cellspacing #f))
+ (cellstyle 'collapse) (cellpadding #f) (cellspacing #f)
+ (rulecolor #f))
(let ((frame (cond
((string? frame)
(string->symbol frame))
@@ -740,6 +741,9 @@
(options `((:frame ,frame)
(:rules ,rules)
(:cellstyle ,cellstyle)
+ ,@(if rulecolor
+ `((:rulecolor ,rulecolor))
+ '())
,@(the-options opts :ident :class)))
(body (parse-list-of 'table 'tr (the-body opts))))))))