1
votes

I am using Apache FOP 1.0 to generate PDF. I want to extend the end-indent of the table such that I do not get the INFO warnings:

INFO: An fo:table is wider than the available room in inline-progression-dimension. Adjusting end-indent based on overconstrained geometry rules (XSL 1.1, ch. 5.3.4).

Here is a table with overflowing table width:

<?xml version="1.0" encoding="UTF-8"?>
   <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
   <fo:layout-master-set>
      <fo:simple-page-master 
         master-name="CommonMasterLayout"
         page-height="11in" page-width="8.5in" 
         margin-top=".5in" margin-bottom=".5in" 
         margin-left="1in" margin-right="1in">
         <fo:region-body region-name="middle" margin-bottom=".75in" margin-top=".75in"/>
         <fo:region-before region-name="top" extent=".75in"/>
         <fo:region-after region-name="bottom" extent=".5in"/>
       </fo:simple-page-master>
     </fo:layout-master-set>
     <fo:page-sequence master-reference="CommonMasterLayout">
       <fo:flow flow-name="middle">
         <fo:block>
           <fo:table end-indent="-0.5in" width="100%" table-layout="fixed">
             <fo:table-column column-width="2.033in"/>
             <fo:table-column column-width="4.616in"/>
             <fo:table-body>
               <fo:table-row>
                 <fo:table-cell border="0.5pt solid black">
                  <fo:block>Some text that will flow over to the neighboring cell</fo:block>
                 </fo:table-cell>
                 <fo:table-cell border="0.5pt solid black">
                   <fo:block>Other text within a box</fo:block>
                 </fo:table-cell>
               </fo:table-row>
             </fo:table-body>
           </fo:table>
         </fo:block>
       </fo:flow>
     </fo:page-sequence>
   </fo:root>

The page width is 6.5inches and the table is 6.649in wide, clearly exceeding the dimension. I have 1in padding on both sides so I want to extend the right a little.

Using the table attribute end-indent="-0.5in" causes the text within cells to overflow into neighboring cells as if the column width changed. Am I using the correct attribute for this?

1

1 Answers

1
votes

Add end-indent="0in" to fo:table-body.