This is the mail archive of the
docbook-apps@lists.oasis-open.org
mailing list .
Problems with paras in proper handling of admon graphics
- To: docbook-apps at lists dot oasis-open dot org
- Subject: DOCBOOK-APPS: Problems with paras in proper handling of admon graphics
- From: Richard Sharpe <sharpe at ns dot aus dot com>
- Date: Thu, 19 Jul 2001 21:17:25 +0930
- Reply-to: rsharpe at ns dot aus dot com
Hi,
Yesterday I posted around a DSL function to handle admon graphics in a
much better way to handle admon graphics.
It turns an admon into a table and allows me to position the graphic
much better WRT to text along side of it.
However, I have a problem with multiple para's in an admon.
I can't seem to get %para-sep% space between paras, which makes it look
ugly.
Here is what I currently have. Can anyone see the problems?
(mode admon-para-mode
(element para
(make display-group
space-before: %para-sep%
space-after: %para-sep%
(literal "PARA")
(process-children))))
; Make admon graphics look better ...
(define ($graphical-admonition$)
(let* ((adm (current-node))
(title (select-elements (children adm)
(normalize "title")))
(title? (not (node-list-empty? title)))
(adm-title (if title?
(with-mode title-sosofo-mode
(process-node-list (node-list-first title)))
(literal (gentext-element-name adm))))
(graphic (make external-graphic
display?: #f
position-point-y: (+ %bf-size% 2pt)
entity-system-id: ($admon-graphic$)))
; (paras (node-list-first
; (select-elements (children (current-node))
; (normalize "para"))))
(f-child (node-list-first (children (current-node))))
(r-child (node-list-rest (children (current-node)))))
(make display-group
space-before: %block-sep%
space-after: %block-sep%
(make table
table-width: (- %text-width% (inherited-start-indent))
(make table-column
width: ($admon-graphic-width$))
(make table-column
width: 10pt)
(make table-column
width: (- %text-width%
(+ (inherited-start-indent)
($admon-graphic-width$)
10pt)))
(make table-row
(make table-cell
graphic)
(make table-cell
(make line-field
field-width: 5pt
field-align: 'center
(empty-sosofo)))
(make table-cell
(with-mode admon-para-mode
(process-children))))))))
--
Richard Sharpe, rsharpe@ns.aus.com, LPIC1
www.samba.org, www.ethereal.com, SAMS Teach Yourself Samba
in 24 Hours, Special Edition, Using Samba
------------------------------------------------------------------
To unsubscribe from this elist send a message with the single word
"unsubscribe" in the body to: docbook-apps-request@lists.oasis-open.org