OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: image-scaling (a never ending story?)


after spending several frustrating days reading mailing-list
archives and using google, I dare to ask the following
(probably well known) question:

Ho do I scale images in docbook?

I have tried several variants like

       <imagedata   fileref="small.png"  format="PNG" scalefit="1" />

<imagedata   fileref="small.png" format="PNG"  width="5cm" scalefit="1" />

with and without format="PNG"
tried "depth" and "contentwidth" instead of "width"

all without any effect.

Images are always displayed in original size.

I am using 'db2pdf' coming with SuSE Linux, which is a script
based on jade.

The invocation of jade looks like this (db2tex):

jade -V tex-backend -t tex -c /usr/share/sgml/CATALOG.iso_ent -c /usr/share/sgml/CATALOG.jade_dsl -c /usr/share/sgml/CATALOG.docbook-dsssl-stylesheets -c /usr/share/sgml/CATALOG.db41xml -c 
/usr/share/sgml/CATALOG.db42xml -D /usr/share/sgml/docbook/dsssl-stylesheets -d /usr/share/sgml/docbook/docbook-toys/suse-both.dsl#print -o test.tex /usr/share/sgml/jade_dsl/xml.dcl test.xml

TeX seems to be aware of the image size(s):

<small.png, id=38, 122.4575pt x 21.07875pt> <use small.png>
<big.png, id=39, 943.525pt x 160.6pt> <use big.png>
Overfull \hbox (540.2477pt too wide) detected at line 748

I even tried to play with the resulting tex documents


and used pdfjadetex to translate it into pdf with either
error messages or unscaled images.

Finally, I tries the xsl-path using:

xsltproc  docbook-xsl-1.64.1/fo/docbook.xsl test.xml > test.fo
pdfxmltex   simple.fo

creating just arrors:
pdfxmltex   simple.fo
This is pdfTeX, Version 3.14159-1.00a-pretest-20011114-ojmw (Web2C 7.3.7)
LaTeX2e <2001/06/01>
Babel <v3.7h> and hyphenation patterns for american, french, german, ngerman, n
ohyphenation, loaded.
xmltex version: 2002/06/25 v1.9 (Exp):
No File: simple.cfg (/usr/share/texmf/tex/xmltex/passivetex/fotex.xmt)
Document Class: article 2001/04/21 v1.4e Standard LaTeX document class
(/usr/share/texmf/tex/latex/psnfss/t1ptm.fd) (./simple.out) (./simple.out)
! Interruption.
\XML@tempb ...#4\relax \relax ->\def #2{0.5in}#1#4
                                                   \relax \relax
l.2 ....5in" margin-left="1in" margin-right="1in">
                                                   <fo:region-body margin-bot...


So, I am a bit lost at the moment.

I would appreciate  your help!

Greetings Harald

P.S.: sorry, if you get this twice. I sent this message yesterday
before having subscribed. As I could not find it in the latest
archive, I assume, it has been rejected by the list-server.

This is the complete document:

<?xml version="1.0"  ?>

"-//OASIS//DTD DocBook XML V4.2//EN"

<book id="test" lang="de">
     <title>Test Graphics</title>

     <releaseinfo>$Id: test.xml,v 1.2 2004/02/10 19:58:18 finster Exp finster $</releaseinfo>


   <chapter id="ch-intro">
     <title id="ch-title-intro">Introduction</title>

     <para>A Small Figure (PNG)</para>
           <imagedata   fileref="small.png"  format="PNG" scalefit="1" />

     <para>A Big Figure (PNG)</para>
           <imagedata   fileref="big.png" format="PNG"  width="5cm" scalefit="1" />



Dr.-Ing. Harald Finster / Aachen Germany
http://www.finster-stahlart.de industrial history and architecture
http://www.astrid-aix.de       gallery: watercolours and oil paintings

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]