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: Change in titlepage mechanism (Re: [docbook-apps] DocBook epub3 beta 3 stylesheets available)

On 4.10.2011 17:49, Bob Stayton wrote:

> <xsl:template match="t:templates">
>  <xsl:element name="xsl:stylesheet">
>    <!-- add this attribute -->
>    <xsl:attribute name="xmlns">http://www.w3.org/1999/xhtml</xsl:attribute>
> and it seems to add
> xmlns="http://www.w3.org/1999/xhtml";
> in the right place.  That seems too easy.  I'm used to doing all kinds
> of contortions to get namespaces correct.  But I guess in this case we
> are not actually handling a namespace.

Hi Bob,

this should raise error as xmlns is not attribute in XPath data model.
Saxon throws the following message:

Recoverable error
at xsl:attribute on line 78 of
  Invalid attribute name: xmlns

and xmlns is ignored. Of course this is little bit edge case so other
processors might give different results.

> If it is that easy, then we could add a stylesheet  parameter to
> template/titlepage.xsl to specify a default namespace,  and
> conditionally add it if not blank.  The customizer would have to know 
> to set the param, but I think that would be ok.

I have added ns parameter to titlepage.xsl. It has to be set for FO and
XHTML, but should be empty for HTML. I have used different means for
setting namespace, but result seems ok. I have modified Makefiles as
well. You can see it as revision 9112.

We should warn users in release notes that when generating custom
titlepage templates this additional parameter has to be set fo FO/XHTML.


  Jirka Kosek      e-mail: jirka@kosek.cz      http://xmlguru.cz
       Professional XML consulting and training services
  DocBook customization, custom XSLT/XSL-FO document processing
 OASIS DocBook TC member, W3C Invited Expert, ISO JTC1/SC34 member

Attachment: signature.asc
Description: OpenPGP digital signature

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