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

 


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

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


Subject: AW: [docbook-apps] simg:getWidth just returns $nominal.image.width




>On Mon, Jul 21, 2003 at 06:40:57PM +0200, Sebastian Fey wrote:
>>
>> i tried to use the variable $intrinsicwidth in graphics.xsl, but
>> simg:getWidth just fills it with the value of its second param
>> $nominal.image.width.
>> ...
>
>
>I presume you have fixed your earlier problem with
>the CLASSPATH not finding the extensions file, so

yes :)

>that the simg:getWidth function is actually being used,
>as your debug message indicates.
>
>It should work.  What kind of graphic format are you using?
>It is possible that getWidth doesn't handle all graphics
>file formats.

hi,

i now tried it with gif, jpg, png and wmf ... all return the same !

cu,
-seb

this snippet:
-------------

...
<xsl:when test="function-available('simg:getWidth')">
  <xsl:message>
    <xsl:value-of select="$filename" />
    <xsl:value-of select="simg:new($filename)" />
    <xsl:value-of
select="simg:getWidth(simg:new($filename),$nominal.image.width)"/>
...

and this output:
----------------

./figures/imajpg.jpg
com.nwalsh.saxon.ImageIntrinsics@ce2187
540 (6 * pixels.per.inch = $nominal.image.width)

./figures/imagif.gif
com.nwalsh.saxon.ImageIntrinsics@141b571
540

./figures/imapng.png
com.nwalsh.saxon.ImageIntrinsics@1c5f743
540

./figures/imawmf.wmf
com.nwalsh.saxon.ImageIntrinsics@1bb60c3
540

with a .xml like this: (maybe imagedata with format-attr is needed? -we dont
use it)
----------------------
...
<figure id="FIG_Overviewofsystem">
	<title>Overview of the HTx&nbsp;4.2 system</title>
	<mediaobject>
		<imageobject>
			<imagedata fileref="./figures/imajpg.jpg" />
		</imageobject>
	</mediaobject>
</figure>
...




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