xls-fo fop 0.94 Using the keep-together with wrap-option="wrap"

Thunder picture Thunder · Feb 9, 2010 · Viewed 8.3k times · Source

In xls-fo fop 0.94 Using the keep-together along with with wrap-option="wrap" ignores the wrap option ? Is there a way to make them both work?

   <fo:table-row border="1pt solid black" keep-together="always">
        <fo:table-cell>
            <fo:block overflow="scroll" wrap-option="wrap">
          This is a long text It is desired that this text be wrapped in the table cell but just can not make it happen!
            </fo:block>
        </fo:table-cell>
   </fo:table-row>

Answer

Jeremias M&#228;rki picture Jeremias Märki · Feb 9, 2010

keep-together="always" implicitely sets keep-together.within-line="always" which basically forbids line breaking. Use keep-together.within-column="always" instead!

See also: http://xmlgraphics.apache.org/fop/faq.html#keep-together

BWT, overflow="scroll" is not supported by FOP. That's only relevant for XSL-FO in browser mode. You can't scroll on paper.