public final class PageSize extends Object
Class representing size of page in PDF document.
Modifier and Type | Field and Description |
---|---|
static float |
LEAVE_INTACT
For internal usage only
|
Constructor and Description |
---|
PageSize(float x,
float y)
Constructor for PageSize.
|
Modifier and Type | Method and Description |
---|---|
static PageSize |
getA0()
A0 size (1189x840 mm).
|
static PageSize |
getA1()
A1 size (840x594 mm).
|
static PageSize |
getA2()
A2 size (594x420 mm).
|
static PageSize |
getA3()
A3 size (420x297 mm).
|
static PageSize |
getA4()
A4 size (297x210 mm).
|
static PageSize |
getA5()
A5 size (210x148 mm).
|
static PageSize |
getA6()
A6 size (148x105 mm).
|
static PageSize |
getB5()
B5 size (250x176 mm).
|
float |
getHeight()
Gets page height.
|
static PageSize |
getP11x17()
11x17 inches format.
|
static PageSize |
getPageLedger()
Ledger size (432x279 mm).
|
static PageSize |
getPageLegal()
Legal size (356x216 mm).
|
static PageSize |
getPageLetter()
Letter size (279x216 mm).
|
float |
getWidth()
Gets page width.
|
boolean |
isLandscape()
Gets page orientation.
|
void |
setHeight(float value)
Sets page height.
|
void |
setLandscape(boolean value)
Sets page orientation.
|
void |
setWidth(float value)
Sets page width.
|
public static final float LEAVE_INTACT
public PageSize(float x, float y)
Constructor for PageSize.
x
- Width of the page.y
- Height of the page.public float getWidth()
Gets page width.
public void setWidth(float value)
Sets page width.
value
- page width.public float getHeight()
Gets page height.
public void setHeight(float value)
Sets page height.
value
- page height.public boolean isLandscape()
Gets page orientation. Returns true of this is landscape orientation and false if this is portrait.
public void setLandscape(boolean value)
Sets page orientation. Returns true of this is landscape orientation and false if this is portrait.
value
- boolean valuepublic static PageSize getA0()
A0 size (1189x840 mm).
public static PageSize getA1()
A1 size (840x594 mm).
public static PageSize getA2()
A2 size (594x420 mm).
public static PageSize getA3()
A3 size (420x297 mm).
public static PageSize getA4()
A4 size (297x210 mm).
public static PageSize getA5()
A5 size (210x148 mm).
public static PageSize getA6()
A6 size (148x105 mm).
public static PageSize getB5()
B5 size (250x176 mm).
public static PageSize getPageLetter()
Letter size (279x216 mm).
public static PageSize getPageLegal()
Legal size (356x216 mm).
public static PageSize getPageLedger()
Ledger size (432x279 mm).
public static PageSize getP11x17()
11x17 inches format.