Re: URL wrapping (off-topic)
Jeremy Malcolm <[email protected]>
| Newsgroups | gmane.text.refdb.general |
|---|---|
| Message-ID | <[email protected]> |
Markus Hoenicka wrote:
> I'm afraid I've lost you here. The URLs in the bibliography are
> supposed to be ulinks, and they seem to be, according to your own test
> data. The generated bibliography contains e.g.:
>
> <ulink role="url"
> url="http://homes.eff.org/~barlow/Declaration-Final.html">http://homes.eff.org/~barlow/Declaration-Final.html</ulink>
Sorry, of course you're right. Still, the TeX magic doesn't work for
RefDB ulinks and does work for other ulinks. Here is what I do:
* In jadetex.cfg, I have \usepackage{url}
* In my driver file (Thesis.dsl) I have this (I didn't write it, I just
found it online, so I don't know if it's the only way to do it):
--- begins ---
(declare-flow-object-class formatting-instruction
"UNREGISTERED::James Clark//Flow Object
Class::formatting-instruction")
(element ulink
(make sequence
(if (node-list-empty? (children (current-node)))
; ulink url="...", /ulink
(make formatting-instruction
data: (string-append "\\url{"
(attribute-string (normalize "url"))
"}"))
(if (equal? (attribute-string (normalize "url"))
(data-of (current-node)))
; ulink url="http://...", http://..., /ulink
(make formatting-instruction data:
(string-append "\\url{"
(attribute-string (normalize "url"))
"}"))
; ulink url="http://...", some text, /ulink
(make sequence
($charseq$)
(literal " (")
(make formatting-instruction data:
(string-append "\\url{"
(attribute-string (normalize "url"))
"}"))
(literal ")"))))))
--- ends ---
By separate email I will send a small TeX file in which the URL is
wrapped correctly in the body text but the RefDB URL is not.
--
JEREMY MALCOLM <[email protected]> - lawyer, IT consultant and actor.
Internet and Open Source specialist. Web site: http://www.malcolm.id.au.
Disclaimer: http://www.terminus.net.au/disclaimer.html. GPG key: finger.
smime.p7s
(application/x-pkcs7-signature, 3.2 KB) - not displayed