This is the mail archive of the
docbook-tools-discuss@sourceware.cygnus.com
mailing list for the docbook-tools project.
Re: images in Docbook with Red Hat 6.2
- To: Sam Roberts <sam at cogent dot ca>
- Subject: Re: images in Docbook with Red Hat 6.2
- From: Eric Bischoff <ebisch at cybercable dot tm dot fr>
- Date: Thu, 13 Apr 2000 19:28:07 -0400
- CC: Peter Toft <pto at sslug dot dk>, docbook-tools-discuss at sourceware dot cygnus dot com
- References: <Voyager.000413114314.27688B@sam.cogent.ca>
Sam Roberts wrote:
>
>
> (define (graphic-file filename)
> (let ((ext (file-extension filename)))
> (if (or tex-backend ;; TeX can work this out itself
> (not filename)
> (not %graphic-default-extension%)
> (member ext %graphic-extensions%))
> filename
> (string-append filename "." %graphic-default-extension%))))
>
Such code trying to guess the graphic extension from within
the stylesheet is a good idea. Anyway, it will always face
the same problem : for publishing in HTML, for example, how
to decide whether to add JPEG, PNG or GIF ? It's not easy.
I'm currently using the following approach:
<graphic fileref="foo.&gif-eps;">
stands for:
"use foo.gif when making HTML files, foo.eps when printing
to TeX."
You can do create on the same model other entities like
&jpg-eps;. It's not perfect, but it's simple and works.
--
Éric Bischoff - mailto:ebisch@cybercable.tm.fr
__________________________________________________
\^o~_.
.~. ______ /( __ )
/V\ Toys story \__ \/ ( V
// \\ \__| (__=v
/( )\ |\___/ )
^^-^^ \_____( )
Tux Konqui \__=v
__________________________________________________