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: Keep a table from splitting across pages


I have an informaltable with one head row and three data rows, coded as the example below:

	  <informaltable>
	    <tgroup cols="1">
	      <thead>
		<row>
		  <entry>Examples:</entry>
		</row>
	      </thead>
	      
	      <tbody>
		<row>
		  <entry>
		    <para>
                                       stuff...
		     </para>
		  </entry>
		</row>
		
		<row>
		  <entry>
		    <para>
		      more stuff...
		    </para>
		  </entry>
		</row>
		
		<row>
		  <entry>
		    <para>
		      even more stuff...
		    </para>
		  </entry>
		</row>
	      </tbody>
	    </tgroup>
	  </informaltable>

I *don't* want this table to split at a page end; I would rather have the entire table carry over to the next page.

I note from Bob Stayton's book that "[t]he dbfo keep-together processing instruction can be used with tables, examples, figures, and equations (and their informal versions too). By default, each of those elements is automatically kept together, by means of the following attribute in the formal.object.properties attribute-set in fo/param.xsl...." (see http://www.sagehill.net/docbookxsl/PageBreaking.html)

I read this to mean that by default tables don't break. Am I reading this wrong? (Probably.)

In any event, further down that page, I read that I can use a dbfo processing instruction to either make the break occur automatically, or turn it always on. So I coded my informaltable like this:

	  <informaltable>
	  <?dbfo keep-together="always" ?>
	    <tgroup cols="1">
	      <thead>
		<row>
		  <entry>Examples:</entry>
		</row>
	      </thead>
	      
	      <tbody>
		<row>
		  <entry>
		    <para>
                                       stuff...
		     </para>
		  </entry>
		</row>
		
		<row>
		  <entry>
		    <para>
		      more stuff...
		    </para>
		  </entry>
		</row>
		
		<row>
		  <entry>
		    <para>
		      even more stuff...
		    </para>
		  </entry>
		</row>
	      </tbody>
	    </tgroup>
	  </informaltable>

I have added the dbfo processing instruction immediately below the open tag of the informaltable element. But the table still splits.

I am using xsltproc to create the fo file with the following command lines:

xsltproc --output manual.rulewriter.xml --stringparam profile.userlevel "rulewriter" C:/xml/style/docbook-xsl-1.69.1/profiling/profile.xsl manual.dcbk

xsltproc --output manual.rulewriter.fo --stringparam xep.extensions 1 ./style/manual-pdf.xsl manual.rulewriter.xml

Then I use XEP 4.5 to create the PDF output with the following command line:

C:\Programs\RenderX\XEP\xep.bat -fo manual.rulewriter.fo -pdf manual.rulewriter.pdf

What (probably painfully obvious thing) have I missed?

Thanks,

Mike


----------------------------

Mike Broschinsky
Administrative Code Editor
Utah State Division of Administrative Rules
801-538-3003
mbroschi@utah.gov 



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