cvs: php-gtk-doc /stylesheets/html synop.xsl

From: Date: Mon, 31 Oct 2005 10:49:28 +0000
Subject: cvs: php-gtk-doc /stylesheets/html synop.xsl
Groups: php.gtk.doc 
Request: Send a blank email to php-gtk-doc+get-1590@lists.php.net to get a copy of this message
cweiske Mon Oct 31 05:49:28 2005 EDT Modified files: /php-gtk-doc/stylesheets/html synop.xsl Log: Fixed the optional parameter brackets from > (param, [optional = foo]) to > (param [, optional = foo]) http://cvs.php.net/diff.php/php-gtk-doc/stylesheets/html/synop.xsl?r1=1.6&r2=1.7&ty=u Index: php-gtk-doc/stylesheets/html/synop.xsl diff -u php-gtk-doc/stylesheets/html/synop.xsl:1.6 php-gtk-doc/stylesheets/html/synop.xsl:1.7 --- php-gtk-doc/stylesheets/html/synop.xsl:1.6 Mon Apr 11 17:54:45 2005 +++ php-gtk-doc/stylesheets/html/synop.xsl Mon Oct 31 05:49:27 2005 @@ -7,7 +7,7 @@ version='1.0'> <!-- ******************************************************************** - $Id: synop.xsl,v 1.6 2005/04/11 21:54:45 cweiske Exp $ + $Id: synop.xsl,v 1.7 2005/10/31 10:49:27 cweiske Exp $ ******************************************************************** This file is part of the XSL DocBook Stylesheet distribution. @@ -38,7 +38,13 @@ <xsl:number count="paramdef" format="1"/> </xsl:variable> <xsl:if test="$paramnum=1">(</xsl:if> + <xsl:if test="preceding-sibling::paramdef and $optional&gt;0"> + <xsl:text> </xsl:text> + </xsl:if> <xsl:if test="$optional&gt;0">[</xsl:if> + <xsl:if test="preceding-sibling::paramdef"> + <xsl:text>, </xsl:text> + </xsl:if> <xsl:if test="text() != 'void'"> <xsl:choose> <xsl:when test="$funcsynopsis.style='ansi'"> @@ -49,17 +55,12 @@ </xsl:otherwise> </xsl:choose> </xsl:if> - - <xsl:choose> - <xsl:when test="following-sibling::paramdef"> - <xsl:text>, </xsl:text> - </xsl:when> - <xsl:otherwise> - <xsl:variable name="optionals" select=".//optional|preceding-sibling::paramdef/*/optional"/> - <xsl:for-each select="$optionals">]</xsl:for-each> - <xsl:text>);</xsl:text> - </xsl:otherwise> - </xsl:choose> + + <xsl:if test="not(following-sibling::paramdef)"> + <xsl:variable name="optionals" select=".//optional|preceding-sibling::paramdef/*/optional"/> + <xsl:for-each select="$optionals">]</xsl:for-each> + <xsl:text>);</xsl:text> + </xsl:if> </xsl:template> <xsl:template match="optional">

« previous php.gtk.doc (#1590) next »