Re: XSL-FO two-page layout


Below is an XSL that you could adopt to the Antennahouse area tree format. This does n-up processing of RenderX's intermediate format to 2-up and more.

From the comments:

        This style sheet performs transformations on the XEP intermediate format (XEPOUT)

        to format various layouts of documents. 


        It is based on the <xep:transform> element which can apply an affine matix

        transformation to content. This is used to shrink pages to fit within the

        output page. It is also based on the <xep:translate> element to move pages

        in a grid layout in the new document.


        The stylesheet is used to take an input document and create various styles of output

        by shrinking and translating input pages from the document into a new output document

        with these pages.


        It does assume all the pages are uniform, all being the same dimensions of the first

        page. The scaling and configuration are based on this layout. It does work woth both

        landscape and portrait documents. And of course, it does not work with documents with

        intra-document links or bookmarks. It is meant to produce a print output document with

        the desired n-up layout.

        2-up: Two per page

            opposite final layout

            scaled to (width/height) for portrait

            scaled to (height/width) for landscape

            2 cols, 1 row for portrait

            1 col, 2 rows for landscape

        4-up: Four per page

            same final layout

            scaled to 1/2

        6-up: Six per page

            opposite final layout

            scaled to 1/2 (width/height) for portrait

            scaled to 1/2 (height/width) for landscape

            3 cols, 2 rows for portrait

            2 cols, 3 rows for landscape

        9-up: Nine per page 

            same final layout

            scaled to 1/3

        16-up: Sixteen per page 

            same final layout


            scaled to 1/4


Join to automatically receive all group messages.