-
Suggestion
-
Resolution: Duplicate
-
None
Being able to force page breaks in PDF output is very useful, and we've added this functionality via a user macro and a patch to xhtml2fo.xsl - it would be great if this or similar functionality was included in confluence so we don't have to continue to patch it ourselves.
Our implementation requires two patches to xhtml2fo.xsl:
In the attribute-set section
<!-- START pagebreak macro patch --> <xsl:attribute-set name="pagebreak"> <xsl:attribute name="break-before">page</xsl:attribute> </xsl:attribute-set> <!-- END pagebreak macro patch -->
In the templates
<!-- START pagebreak macro patch --> <xsl:template match="html:div[@class='pagebreak']"> <fo:block xsl:use-attribute-sets="pagebreak"> </fo:block> </xsl:template> <!-- END pagebreak macro patch -->
and a user macro to reference the templates (set to Macro generates HTML markup, no body)
<div class="pagebreak"> </div>
Please consider adding this as a feature!
- duplicates
-
CONFSERVER-8436 Add support for page breaks in PDF page exports
- Closed