[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]
Subject: RE: DOCBOOK-APPS: Can I turn off numbering for Sections 3-5?
I just tested this. It doesn't work. So, either the template doesn't do what I thought it should, or there are other templates involved. I'm curious now, though, so I'll poke around at this one for a bit more before I give up. -----Original Message----- From: Jeff Beal [mailto:jeff.beal@ansys.com] Sent: Thursday, February 27, 2003 10:55 AM To: 'Brian Burridge'; DocBookApps Subject: RE: DOCBOOK-APPS: Can I turn off numbering for Sections 3-5? There's no parameter or other easy method for doing this, but I was just looking through the labelling code and found this template: <xsl:template name="label.this.section"> <xsl:param name="section" select="."/> <xsl:value-of select="$section.autolabel"/> </xsl:template> My guess is that if you change that to this: <xsl:template name="label.this.section"> <xsl:param name="section" select="."/> <xsl:variable name="elementname" select="local-name($section)"/> <xsl:choose> <xsl:when test="$elementname = sect1"> <xsl:value-of select="$section.autolabel"/> </xsl:when> <xsl:when test="$elementname = sect2"> <xsl:value-of select="$section.autolabel"/> </xsl:when> <xsl:when test="$elementname = section"> <xsl:choose> <xsl:when test="count($section/ancestor::section > 2)"> <xsl:value-of select="$section.autolabel"/> </xsl:when> <xsl:otherwise> <xsl:value-of select="false()"/> </xsl:otherwise> </xsl:choose> </xsl:when> <xsl:otherwise> <xsl:value-of select="false()"/> </xsl:otherwise> </xsl:choose> </xsl:template> you will get what you want. Jeff -----Original Message----- From: Brian Burridge [mailto:maillist@burridge.net] Sent: Wednesday, February 26, 2003 5:32 PM To: DocBookApps Subject: DOCBOOK-APPS: Can I turn off numbering for Sections 3-5? I have a situation where I'm numbering the chapters and sections 1-2, but now one of my "sect2"'s contains a huge amount of text that has subsections, and I don't want them numbered (as the numbering gets a bit ridiculous, 1.1.1.1.1.2). Or is there a another tag that will allow my to have something like sections but without numbering? Brian
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]
Powered by eList eXpress LLC