This is the mail archive of the docbook-apps@lists.oasis-open.org mailing list .
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
Fundamentally, I want (and have wanted for some time) to exorcise the <a name="source_id_val.or.generated"/> gremlins from the (x)html output in the stylesheets. (Incidentally, this post is motivated by the recent thread regarding the redesign of the xhtml output mode. It is somewhat tangential, but I would appreciate it if my requests would be considered by that design committee.) It is my opinion that any future xhtml output mode should use (or allow the use of, as an option) id attributes on the container that most closely maps to the source (DocBook) container as an xhtml "anchor". To that end, I've started on some minor DocBook-XSL cosmetic surgery. First, I replaced the old "anchor" template with the following (as always, props to Norm and co. for the modular design here): <xsl:template name="anchor"> <xsl:param name="node" select="."/> <xsl:param name="conditional" select="1"/> <xsl:variable name="id"> <xsl:call-template name="object.id"> <xsl:with-param name="object" select="$node"/> </xsl:call-template> </xsl:variable> <xsl:if test="$conditional = 0 or $node/@id or $node/@xml:id"> <xsl:attribute name="id"> <xsl:value-of select="$id"/> </xsl:attribute> </xsl:if> </xsl:template> That's a step, but a bit of testing quickly shows it to be insufficient. The first speedbump is the fact that the anchors for sections get attached not to the div container corresponding to that section, but to the *title* container for that section. My question at this point is simple - why? I simply do not understand the design decision here. I wanted to know what I might be breaking by ripping this out, and I wanted to know if there might be any interest in pushing this work back upstream once completed. Take care, John L. Clark
Attachment:
pgp00000.pgp
Description: PGP signature
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |