public static class PageFormat.PageFormatBuilder extends Object
| Modifier | Constructor and Description |
|---|---|
protected |
PageFormatBuilder() |
| Modifier and Type | Method and Description |
|---|---|
PageFormat.PageFormatBuilder |
A0()
Sets the media box to size
Constants.A0. |
PageFormat.PageFormatBuilder |
A1()
Sets the media box to size
Constants.A1. |
PageFormat.PageFormatBuilder |
A2()
Sets the media box to size
Constants.A2. |
PageFormat.PageFormatBuilder |
A3()
Sets the media box to size
Constants.A3. |
PageFormat.PageFormatBuilder |
A4()
Sets the media box to size
Constants.A4. |
PageFormat.PageFormatBuilder |
A5()
Sets the media box to size
Constants.A5. |
PageFormat.PageFormatBuilder |
A6()
Sets the media box to size
Constants.A6. |
PageFormat |
build()
Actually builds the PageFormat.
|
PageFormat.PageFormatBuilder |
landscape()
Sets the orientation to
Orientation.Landscape. |
PageFormat.PageFormatBuilder |
letter()
Sets the media box to size
Constants.Letter. |
PageFormat.PageFormatBuilder |
marginBottom(float marginBottom)
Sets the bottom margin.
|
PageFormat.PageFormatBuilder |
marginLeft(float marginLeft)
Sets the left margin.
|
PageFormat.PageFormatBuilder |
marginRight(float marginRight)
Sets the right margin.
|
PageFormat.PageFormatBuilder |
margins(float marginLeft,
float marginRight,
float marginTop,
float marginBottom)
Sets the margins.
|
PageFormat.PageFormatBuilder |
marginTop(float marginTop)
Sets the top margin.
|
PageFormat.PageFormatBuilder |
mediaBox(org.apache.pdfbox.pdmodel.common.PDRectangle mediaBox)
Sets the media box to the given size.
|
PageFormat.PageFormatBuilder |
orientation(Orientation orientation)
Sets the orientation to the given one.
|
PageFormat.PageFormatBuilder |
portrait()
Sets the orientation to
Orientation.Portrait. |
PageFormat.PageFormatBuilder |
rotation(int angle)
Sets the rotation to apply to the page after rendering.
|
public PageFormat build()
public PageFormat.PageFormatBuilder marginLeft(float marginLeft)
marginLeft - the left margin to use.public PageFormat.PageFormatBuilder marginRight(float marginRight)
marginRight - the right margin to use.public PageFormat.PageFormatBuilder marginTop(float marginTop)
marginTop - the top margin to use.public PageFormat.PageFormatBuilder marginBottom(float marginBottom)
marginBottom - the bottom margin to use.public PageFormat.PageFormatBuilder margins(float marginLeft, float marginRight, float marginTop, float marginBottom)
marginLeft - the left margin to use.marginRight - the right margin to use.marginTop - the top margin to use.marginBottom - the bottom margin to use.public PageFormat.PageFormatBuilder mediaBox(org.apache.pdfbox.pdmodel.common.PDRectangle mediaBox)
mediaBox - the media box to use.public PageFormat.PageFormatBuilder A0()
Constants.A0.public PageFormat.PageFormatBuilder A1()
Constants.A1.public PageFormat.PageFormatBuilder A2()
Constants.A2.public PageFormat.PageFormatBuilder A3()
Constants.A3.public PageFormat.PageFormatBuilder A4()
Constants.A4.public PageFormat.PageFormatBuilder A5()
Constants.A5.public PageFormat.PageFormatBuilder A6()
Constants.A6.public PageFormat.PageFormatBuilder letter()
Constants.Letter.public PageFormat.PageFormatBuilder orientation(Orientation orientation)
orientation - the orientation to use.public PageFormat.PageFormatBuilder portrait()
Orientation.Portrait.public PageFormat.PageFormatBuilder landscape()
Orientation.Landscape.public PageFormat.PageFormatBuilder rotation(int angle)
angle - the angle to rotate.Copyright © 2021. All rights reserved.