From: SourceForge.net <no...@so...> - 2004-02-26 22:19:40
|
Bugs item #702995, was opened at 2003-03-14 03:41 Message generated for change (Comment added) made by pkendall You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=373747&aid=702995&group_id=21935 Category: DocBook XSL FO Group: None Status: Open Resolution: None Priority: 5 Submitted By: Jeff Beal (beal91) Assigned to: Nobody/Anonymous (nobody) Summary: Scaling graphic when only viewport is specified Initial Comment: According to TDG, when the viewport area of a graphic is specified and the content area is not, the value of the scalefit defaults to "1". However, the stylesheets (v 1.60.1) output a content-width and content-depth of "auto" in this case (i.e. the 'intrinsic' size.) The following customization of a portion of the process.image template seems to correct the problem in some cases: In looking at the code in <xsl:template name="process.image">, it looks like the variable named scalefit is correctly assigned a value of "1" when @width or @depth exist and not @contentwidth or @contentdepth, but this variable is not used when calculating the value of the fo:content-width and fo:content-depth attributes. ---------------------------------------------------------------------- Comment By: Paul Kendall (pkendall) Date: 2004-02-27 11:07 Message: Logged In: YES user_id=70579 I fixed this in my 1.64.1 by adding this to the process.image template in graphics.xsl <xsl:when test="number($scalefit) != 0"> <xsl:text>scale-to-fit</xsl:text> </xsl:when> I put it in the content-width & content-height attribute code just before the xsl:otherwise and now it works beautifully! Perhaps this can be added to the next release of the stylesheets. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=373747&aid=702995&group_id=21935 |