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: Re: [docbook-apps] semantics of "replaceable" element.


On 11/05/2012 08:37 PM, Richard Hamilton wrote:
> I just looked at the stylesheets, and they include a parameter called function.parens, which when set will take input of the following type:
>
> <function>foo<replaceable>x</replaceable><replaceable>y</replaceable></function>
> and render it as: foo(x, y).

I see. But isn't that the wrong markup for this desired output ?
Shouldn't that use <parameter> instead of <replaceable> ?

> The problem seems to be that the template for d:function checks this parameter, but the template for d:function/d:replaceable (and d:function/d:parameter) doesn't . The result when function.parens is set to 0 is inconsistent.
>
> I think the following change would fix the problem for Stefan, and leave the capability in for anyone who wants to use function.parens:
>
> <xsl:template match="d:function/d:replaceable" priority="2">
>   <xsl:call-template name="inline.italicmonoseq"/>
>   <xsl:if test="$function.parens != '0' and following-sibling::*">  <!-- here is the changed line -->
>     <xsl:text>, </xsl:text>
>   </xsl:if>
> </xsl:template>
>
> You'd need to do the same with d:function/d:parameter, too, though it appears that parameter is not allowed inside function, so it may be a moot point.

According to http://docbook.org/tdg/en/html/parameter.html parameter is
allowed inside function.

But no matter what, it seems that these two usages of <replaceable> are
radically different, which seems to suggest that I still don't fully
grasp what a "replaceable" represents.

Thanks,
        Stefan

-- 

      ...ich hab' noch einen Koffer in Berlin...



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