aspose.pdf
Class PageSetup

java.lang.Object
  extended by aspose.pdf.PageSetup

public class PageSetup
extends java.lang.Object

Encapsulates info for page setup.

Typical usages are the following:

[Java] Pdf pdf1 = new Pdf(); pdf1.getPageSetup().setPageHeight(PageSize.A2Height); Section sec = pdf1.getSections().add(); Text text1 = new Text("this is text content"); text1.getMargin().Top = 30; sec.getParagraphs().add(text1); pdf1.save(....); [XML] <?xml version="1.0" encoding="utf-8" ?> <Pdf xmlns="Aspose.Pdf"> <Section PageHeight="1684"> <Text MarginTop="30"> <Segment>this is text content</Segment> </Text> </Section> </Pdf>


Constructor Summary
PageSetup()
          Initializes a new instance of the PageSetup class.
PageSetup(Section section)
          Initializes a new instance of the PageSetup class.
 
Method Summary
 java.lang.Object clone()
          Clones a new PageSetup object.
 RectData getArtBox()
          Gets a RectData object that indicates the art box of the page.
 RectData getBleedBox()
          Gets a RectData object that indicates the bleed box of the page.
 RectData getCropBox()
          Gets a RectData object that indicates the crop box of the page.
 MarginInfo getMargin()
          Gets a MarginInfo object that indicates the page margin info.
 BorderInfo getPageBorder()
          Gets a BorderInfo object that indicates the page border.
 MarginInfo getPageBorderMargin()
          Gets a MarginInfo object that indicates the margin between the page border and the page edge.
 PageGutter getPageGutter()
          Gets a PageGutter object that indicates the page gutter.
 float getPageHeight()
          Gets a float value that indicates the page height.
 float getPageWidth()
          Gets a float value that indicates the page width.
 RectData getTrimBox()
          Gets a RectData object that indicates the trim box of the page.
 void setArtBox(RectData value)
          Sets a RectData object that indicates the art box of the page.
 void setBleedBox(RectData value)
          Sets a RectData object that indicates the bleed box of the page.
 void setCropBox(RectData value)
          Sets a float value that indicates the page height.
 void setMargin(MarginInfo value)
          Sets a MarginInfo object that indicates the page margin info.
 void setPageBorder(BorderInfo value)
          Sets a BorderInfo object that indicates the page border.
 void setPageBorderMargin(MarginInfo value)
          Sets a MarginInfo object that indicates the margin between the page border and the page edge.
 void setPageGutter(PageGutter value)
          Sets a PageGutter object that indicates the page gutter.
 void setPageHeight(float value)
          Sets a float value that indicates the page height.
 void setPageWidth(float value)
          Sets a float value that indicates the page width.
 void setTrimBox(RectData value)
          Sets a RectData object that indicates the trim box of the page.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PageSetup

public PageSetup()
Initializes a new instance of the PageSetup class.


PageSetup

public PageSetup(Section section)
Initializes a new instance of the PageSetup class.

Parameters:
section - The section in which this PageSetup is used for.
Method Detail

getMargin

public MarginInfo getMargin()
Gets a MarginInfo object that indicates the page margin info.


setMargin

public void setMargin(MarginInfo value)
Sets a MarginInfo object that indicates the page margin info.

Parameters:
value -

getPageWidth

public float getPageWidth()
Gets a float value that indicates the page width.


setPageWidth

public void setPageWidth(float value)
Sets a float value that indicates the page width.

Parameters:
value -

getPageHeight

public float getPageHeight()
Gets a float value that indicates the page height.


setPageHeight

public void setPageHeight(float value)
Sets a float value that indicates the page height.

Parameters:
value -

getCropBox

public RectData getCropBox()
Gets a RectData object that indicates the crop box of the page.


setCropBox

public void setCropBox(RectData value)
Sets a float value that indicates the page height.

Parameters:
value -

getBleedBox

public RectData getBleedBox()
Gets a RectData object that indicates the bleed box of the page. The bleed box (PDF 1.3) defines the region to which the contents of the page should be clipped when output in a production environment. This may include any extra ¡°bleed area¡± needed to accommodate the physical limitations of cutting, folding, and trimming equipment. The actual printed page may include printing marks that fall outside the bleed box.


setBleedBox

public void setBleedBox(RectData value)
Sets a RectData object that indicates the bleed box of the page. The bleed box (PDF 1.3) defines the region to which the contents of the page should be clipped when output in a production environment. This may include any extra ¡°bleed area¡± needed to accommodate the physical limitations of cutting, folding, and trimming equipment. The actual printed page may include printing marks that fall outside the bleed box.

Parameters:
value -

getArtBox

public RectData getArtBox()
Gets a RectData object that indicates the art box of the page. The art box (PDF 1.3) defines the extent of the page¡¯s meaningful content (including potential white space) as intended by the page¡¯s creator.


setArtBox

public void setArtBox(RectData value)
Sets a RectData object that indicates the art box of the page. The art box (PDF 1.3) defines the extent of the page¡¯s meaningful content (including potential white space) as intended by the page¡¯s creator.

Parameters:
value -

getTrimBox

public RectData getTrimBox()
Gets a RectData object that indicates the trim box of the page. The trim box (PDF 1.3) defines the intended dimensions of the finished page after trimming. It may be smaller than the media box, to allow for productionrelated content such as printing instructions, cut marks, or color bars.


setTrimBox

public void setTrimBox(RectData value)
Sets a RectData object that indicates the trim box of the page. The trim box (PDF 1.3) defines the intended dimensions of the finished page after trimming. It may be smaller than the media box, to allow for productionrelated content such as printing instructions, cut marks, or color bars.

Parameters:
value -

getPageBorder

public BorderInfo getPageBorder()
Gets a BorderInfo object that indicates the page border.


setPageBorder

public void setPageBorder(BorderInfo value)
Sets a BorderInfo object that indicates the page border.

Parameters:
value -

getPageBorderMargin

public MarginInfo getPageBorderMargin()
Gets a MarginInfo object that indicates the margin between the page border and the page edge. The default value is half of the page margin.


setPageBorderMargin

public void setPageBorderMargin(MarginInfo value)
Sets a MarginInfo object that indicates the margin between the page border and the page edge. The default value is half of the page margin.

Parameters:
value -

getPageGutter

public PageGutter getPageGutter()
Gets a PageGutter object that indicates the page gutter.


setPageGutter

public void setPageGutter(PageGutter value)
Sets a PageGutter object that indicates the page gutter.

Parameters:
value -

clone

public java.lang.Object clone()
Clones a new PageSetup object.

Overrides:
clone in class java.lang.Object
Returns:
The new cloned PageSetup object.