2009/1/16 Jakub Vrana <[email protected]>:
> vrana Fri Jan 16 16:12:42 2009 UTC
>
> Modified files:
> /phpdoc/en/reference/strings/functions number-format.xml
> Log:
> Join two syntaxes
>
> http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/strings/functions/number-format.xml?r1=1.13&r2=1.14&diff_format=u
> Index: phpdoc/en/reference/strings/functions/number-format.xml
> diff -u phpdoc/en/reference/strings/functions/number-format.xml:1.13
> phpdoc/en/reference/strings/functions/number-format.xml:1.14
> --- phpdoc/en/reference/strings/functions/number-format.xml:1.13 Wed
> May 21 21:13:53 2008
> +++ phpdoc/en/reference/strings/functions/number-format.xml Fri Jan 16
> 16:12:42 2009
> @@ -1,5 +1,5 @@
> <?xml version="1.0" encoding="utf-8"?>
> -<!-- $Revision: 1.13 $ -->
> +<!-- $Revision: 1.14 $ -->
> <refentry xmlns="http://docbook.org/ns/docbook"
> xml:id="function.number-format" xmlns:xlink="http://www.w3.org/1999/xlink">
> <refnamediv>
> <refname>number_format</refname>
> @@ -12,12 +12,7 @@
> <type>string</type><methodname>number_format</methodname>
> <methodparam><type>float</type><parameter>number</parameter></methodparam>
> <methodparam
> choice="opt"><type>int</type><parameter>decimals</parameter></methodparam>
> - </methodsynopsis>
> - <methodsynopsis>
> - <type>string</type><methodname>number_format</methodname>
> - <methodparam><type>float</type><parameter>number</parameter></methodparam>
> - <methodparam><type>int</type><parameter>decimals</parameter></methodparam>
> -
> <methodparam><type>string</type><parameter>dec_point</parameter></methodparam>
> + <methodparam
> choice="opt"><type>string</type><parameter>dec_point</parameter></methodparam>
>
> <methodparam><type>string</type><parameter>thousands_sep</parameter></methodparam>
> </methodsynopsis>
> <para>
Jakub,
The choice="opt" attribute only applies to a single parameter. phd
incorrectly renders this as ...
string number_format ( float $number [, int $decimals [, string
$dec_point ]], string $thousands_sep )
Rather than ...
string number_format ( float $number [, int $decimals [, string
$dec_point, string $thousands_sep]] )
I put a proposal through to DocBook (and it was accepted and is to be
part of DocBook 5.1) to introduce a <methodparamgroup> tag.
This tag would allow for grouping of optional params.
The correct methodsynopsis would be (when phd supports DocBook 5.1)
<methodsynopsis>
<type>string</type><methodname>number_format</methodname>
<methodparam><type>float</type><parameter>number</parameter></methodparam>
<methodparamgroup choice="opt">
<methodparam><type>int</type><parameter>decimals</parameter></methodparam>
<methodparamgroup choice="opt">
<methodparam><type>string</type><parameter>dec_point</parameter></methodparam>
<methodparam><type>string</type><parameter>thousands_sep</parameter></methodparam>
</methodparamgroup>
</methodparamgroup>
</methodsynopsis>
See : [docbook] RFE #1998852: Provide a mechanism to group parameters
http://www.nabble.com/Grouping-methodparams-td18971164.html
I know Hannes is aware of this, but I've not got the expertise to
integrate it into phd.
In the meantime, I think this change should be reverted to maintain an
accurate rendering
Regards,
Richard.
--
-----
Richard Quadling
Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498&r=213474731
"Standing on the shoulders of some very clever giants!"