GlenKPeterson / PdfLayoutManager

Adds line-breaking, page-breaking, tables, and styles to PDFBox
45 stars 20 forks source link

Enable Portrait Page Orientation #3

Closed GlenKPeterson closed 9 years ago

GlenKPeterson commented 9 years ago

Eric Schwarzer asks, "Is there anyway to have it generated in portrait mode?" https://twitter.com/EricHans76/status/572875346556547075

GlenKPeterson commented 9 years ago

I think it's currently hard-coded here: https://github.com/GlenKPeterson/PdfLayoutManager/blob/master/src/main/java/com/planbase/pdf/layoutmanager/PdfLayoutMgr.java#L470

Allowing portrait would be a great enhancement!

EricHans76 commented 9 years ago

I updated the rotation to 0, and the PDF orientation does change to portrait, but the content in the PDF is still laying out on the PDF in landscape.

GlenKPeterson commented 9 years ago

I haven't forgotten, just been busy. Waiting for the weekend once again...

I think this is the URL that made me think not setting a rotation would yield portrait: https://svn.apache.org/repos/asf/pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/pdmodel/CreateLandscapePDF.java

GlenKPeterson commented 9 years ago

This enhancement has been made in version 0.3.0. Let me know if it works for you. Thank you for suggesting it - great idea!