Package org.docx4j.convert.out.fo
Class LayoutMasterSetBuilder
java.lang.Object
org.docx4j.convert.out.fo.LayoutMasterSetBuilder
public class LayoutMasterSetBuilder
extends java.lang.Object
A description of how this stuff works
can be found at /docs/headers_footers.docx
Its not possible to let FOP set the height (@extent) of the header and footer regions
automatically: http://apache-fop.1065347.n5.nabble.com/Auto-size-header-to-fit-with-content-td4455.html
So we need to set the height (@extent) of the header and footer regions explicitly.
We do that by creating a temp FO file which contains essentially just the headers/footers,
then interrogating FOP's area tree representation to find the height of each.
So:
1. create LayoutMasterSet (with large extents)
2. generate area tree from that
3. return LayoutMasterSet (with required extents)
- Author:
- jharrop
-
Field Summary
Fields Modifier and Type Field Description protected static org.slf4j.Loggerlog -
Constructor Summary
Constructors Constructor Description LayoutMasterSetBuilder() -
Method Summary
Modifier and Type Method Description static voidappendLayoutMasterSetFragment(AbstractWmlConversionContext context, org.w3c.dom.Node foRoot)For XSLFOExporterNonXSLTstatic org.w3c.dom.DocumentFragmentgetLayoutMasterSetFragment(AbstractWmlConversionContext context)Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Field Details
-
log
protected static org.slf4j.Logger log
-
-
Constructor Details
-
LayoutMasterSetBuilder
public LayoutMasterSetBuilder()
-
-
Method Details
-
getLayoutMasterSetFragment
public static org.w3c.dom.DocumentFragment getLayoutMasterSetFragment(AbstractWmlConversionContext context) -
appendLayoutMasterSetFragment
public static void appendLayoutMasterSetFragment(AbstractWmlConversionContext context, org.w3c.dom.Node foRoot)For XSLFOExporterNonXSLT- Since:
- 3.0
-