diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2004-09-05 16:14:06 +0000 |
---|---|---|
committer | Gerald W. Carter <jerry@samba.org> | 2008-04-23 08:46:01 -0500 |
commit | 8f09daf26edb67efec5411817ab9cf5f78b1b442 (patch) | |
tree | 56e080cf8280b0480ab10d7b8d902649d1f625c4 /docs/xslt/expand-sambadoc.xsl | |
parent | 153cf131399cd53ce66f0814337579572ecefbff (diff) | |
download | samba-8f09daf26edb67efec5411817ab9cf5f78b1b442.tar.gz samba-8f09daf26edb67efec5411817ab9cf5f78b1b442.tar.bz2 samba-8f09daf26edb67efec5411817ab9cf5f78b1b442.zip |
- Respect the scale= attribute.
- Better conformance to the DocBook specs
(This used to be commit 4f02e13dad1d8207d9f9dbaa655f129d4ca63d11)
Diffstat (limited to 'docs/xslt/expand-sambadoc.xsl')
-rw-r--r-- | docs/xslt/expand-sambadoc.xsl | 36 |
1 files changed, 34 insertions, 2 deletions
diff --git a/docs/xslt/expand-sambadoc.xsl b/docs/xslt/expand-sambadoc.xsl index ca57e7fec8..2832111fa5 100644 --- a/docs/xslt/expand-sambadoc.xsl +++ b/docs/xslt/expand-sambadoc.xsl @@ -249,6 +249,10 @@ <xsl:value-of select="@scale"/> </xsl:when> + <xsl:when test="imagefile/@scale != ''"> + <xsl:value-of select="imagefile/@scale"/> + </xsl:when> + <xsl:otherwise> <xsl:text>50</xsl:text> </xsl:otherwise> @@ -262,7 +266,21 @@ <xsl:element name="imagedata"> <xsl:attribute name="fileref"> <xsl:text>images/</xsl:text><xsl:value-of select="imagefile"/><xsl:text>.png</xsl:text></xsl:attribute> - <xsl:attribute name="scale"><xsl:text>50</xsl:text></xsl:attribute> + <xsl:attribute name="scale"> + <xsl:choose> + <xsl:when test="@scale != ''"> + <xsl:value-of select="@scale"/> + </xsl:when> + + <xsl:when test="imagefile/@scale != ''"> + <xsl:value-of select="imagefile/@scale"/> + </xsl:when> + + <xsl:otherwise> + <xsl:text>50</xsl:text> + </xsl:otherwise> + </xsl:choose> + </xsl:attribute> <xsl:attribute name="scalefit"><xsl:text>1</xsl:text></xsl:attribute> </xsl:element> </xsl:element> @@ -270,7 +288,21 @@ <xsl:element name="imagedata"> <xsl:attribute name="fileref"> <xsl:text>images/</xsl:text><xsl:value-of select="imagefile"/><xsl:text>.png</xsl:text></xsl:attribute> - <xsl:attribute name="scale"><xsl:text>50</xsl:text></xsl:attribute> + <xsl:attribute name="scale"> + <xsl:choose> + <xsl:when test="@scale != ''"> + <xsl:value-of select="@scale"/> + </xsl:when> + + <xsl:when test="imagefile/@scale != ''"> + <xsl:value-of select="imagefile/@scale"/> + </xsl:when> + + <xsl:otherwise> + <xsl:text>50</xsl:text> + </xsl:otherwise> + </xsl:choose> + </xsl:attribute> <xsl:attribute name="scalefit"><xsl:text>1</xsl:text></xsl:attribute> </xsl:element> </xsl:element> |