java.lang.Objectcom.aspose.words.PageSetup
public class PageSetup
PageSetup object contains all the page setup attributes of a section
(left margin, bottom margin, paper size, and so on) as properties.
Property Getters/Setters Summary | ||
---|---|---|
boolean | getBidi() | |
void | setBidi(boolean value) | |
Specifies that this section contains bidirectional (complex scripts) text. | ||
boolean | getBorderAlwaysInFront() | |
void | setBorderAlwaysInFront(boolean value) | |
Specifies where the page border is positioned relative to intersecting texts and objects. | ||
int | getBorderAppliesTo() | |
void | setBorderAppliesTo(int value) | |
Specifies which pages the page border is printed on. The value of the property is PageBorderAppliesTo integer constant. | ||
int | getBorderDistanceFrom() | |
void | setBorderDistanceFrom(int value) | |
Gets or sets a value that indicates whether the specified page border is measured from the edge of the page or from the text it surrounds. The value of the property is PageBorderDistanceFrom integer constant. | ||
BorderCollection | getBorders() | |
Gets a collection of the page borders. | ||
boolean | getBorderSurroundsFooter() | |
void | setBorderSurroundsFooter(boolean value) | |
Specifies whether the page border includes or excludes the footer. | ||
boolean | getBorderSurroundsHeader() | |
void | setBorderSurroundsHeader(boolean value) | |
Specifies whether the page border includes or excludes the header. | ||
double | getBottomMargin() | |
void | setBottomMargin(double value) | |
Returns or sets the distance (in points) between the bottom edge of the page and the bottom boundary of the body text. | ||
int | getCharactersPerLine() | |
void | setCharactersPerLine(int value) | |
Gets or sets the number of characters per line in the document grid. | ||
boolean | getDifferentFirstPageHeaderFooter() | |
void | setDifferentFirstPageHeaderFooter(boolean value) | |
True if a different header or footer is used on the first page. | ||
EndnoteOptions | getEndnoteOptions() | |
Provides options that control numbering and positioning of endnotes in this section. | ||
int | getFirstPageTray() | |
void | setFirstPageTray(int value) | |
Gets or sets the paper tray (bin) to use for the first page of a section. The value is implementation (printer) specific. | ||
double | getFooterDistance() | |
void | setFooterDistance(double value) | |
Returns or sets the distance (in points) between the footer and the bottom of the page. | ||
FootnoteOptions | getFootnoteOptions() | |
Provides options that control numbering and positioning of footnotes in this section. | ||
double | getGutter() | |
void | setGutter(double value) | |
Gets or sets the amount of extra space added to the margin for document binding. | ||
double | getHeaderDistance() | |
void | setHeaderDistance(double value) | |
Returns or sets the distance (in points) between the header and the top of the page. | ||
int | getLayoutMode() | |
void | setLayoutMode(int value) | |
Gets or sets the layout mode of this section. The value of the property is SectionLayoutMode integer constant. | ||
double | getLeftMargin() | |
void | setLeftMargin(double value) | |
Returns or sets the distance (in points) between the left edge of the page and the left boundary of the body text. | ||
int | getLineNumberCountBy() | |
void | setLineNumberCountBy(int value) | |
Returns or sets the numeric increment for line numbers. | ||
double | getLineNumberDistanceFromText() | |
void | setLineNumberDistanceFromText(double value) | |
Gets or sets distance between the right edge of line numbers and the left edge of the document. | ||
int | getLineNumberRestartMode() | |
void | setLineNumberRestartMode(int value) | |
Gets or sets the way line numbering runs that is, whether it starts over at the beginning of a new page or section or runs continuously. The value of the property is LineNumberRestartMode integer constant. | ||
int | getLinesPerPage() | |
void | setLinesPerPage(int value) | |
Gets or sets the number of lines per page in the document grid. | ||
int | getLineStartingNumber() | |
void | setLineStartingNumber(int value) | |
Gets or sets the starting line number. | ||
boolean | getMirrorMargins() | |
void | setMirrorMargins(boolean value) | |
For multiple page documents, swaps left and right margins on facing pages. | ||
Aspose.Words.Settings.MultiplePagesType | getMultiplePages() | |
For multiple page documents, gets or sets how a document is printed or rendered so that it can be bound as a booklet. | ||
boolean | getOddAndEvenPagesHeaderFooter() | |
void | setOddAndEvenPagesHeaderFooter(boolean value) | |
True if the document has different headers and footers for odd-numbered and even-numbered pages. | ||
int | getOrientation() | |
void | setOrientation(int value) | |
Returns or sets the orientation of the page. The value of the property is Orientation integer constant. | ||
int | getOtherPagesTray() | |
void | setOtherPagesTray(int value) | |
Gets or sets the paper tray (bin) to be used for all but the first page of a section. The value is implementation (printer) specific. | ||
double | getPageHeight() | |
void | setPageHeight(double value) | |
Returns or sets the height of the page in points. | ||
int | getPageNumberStyle() | |
void | setPageNumberStyle(int value) | |
Gets or sets the page number format. The value of the property is NumberStyle integer constant. | ||
int | getPageStartingNumber() | |
void | setPageStartingNumber(int value) | |
Gets or sets the starting page number of the section. | ||
double | getPageWidth() | |
void | setPageWidth(double value) | |
Returns or sets the width of the page in points. | ||
int | getPaperSize() | |
void | setPaperSize(int value) | |
Returns or sets the paper size. The value of the property is PaperSize integer constant. | ||
boolean | getRestartPageNumbering() | |
void | setRestartPageNumbering(boolean value) | |
True if page numbering restarts at the beginning of the section. | ||
double | getRightMargin() | |
void | setRightMargin(double value) | |
Returns or sets the distance (in points) between the right edge of the page and the right boundary of the body text. | ||
boolean | getRtlGutter() | |
void | setRtlGutter(boolean value) | |
Gets or sets whether Microsoft Word uses gutters for the section based on a right-to-left language or a left-to-right language. | ||
int | getSectionStart() | |
void | setSectionStart(int value) | |
Returns or sets the type of section break for the specified object. The value of the property is SectionStart integer constant. | ||
int | getSheetsPerBooklet() | |
void | setSheetsPerBooklet(int value) | |
Returns or sets the number of pages to be included in each booklet. | ||
boolean | getSuppressEndnotes() | |
void | setSuppressEndnotes(boolean value) | |
True if endnotes are printed at the end of the next section that doesn't suppress endnotes. Suppressed endnotes are printed before the endnotes in that section. | ||
TextColumnCollection | getTextColumns() | |
Returns a collection that represents the set of text columns. | ||
int | getTextOrientation() | |
void | setTextOrientation(int value) | |
Allows to specify |
||
double | getTopMargin() | |
void | setTopMargin(double value) | |
Returns or sets the distance (in points) between the top edge of the page and the top boundary of the body text. | ||
int | getVerticalAlignment() | |
void | setVerticalAlignment(int value) | |
Returns or sets the vertical alignment of text on each page in a document or section. The value of the property is PageVerticalAlignment integer constant. |
Method Summary | ||
---|---|---|
void | clearFormatting() | |
Resets page setup to default paper size, margins and orientation. | ||
java.lang.Object | fetchInheritedBorderAttr(int key) | |
Reserved for internal use. | ||
java.lang.Object | getDirectBorderAttr(int key) | |
Reserved for internal use. | ||
java.util.TreeMap | getPossibleBorderKeys() | |
Reserved for internal use. | ||
void | setBorderAttr(int key, java.lang.Object value) | |
Reserved for internal use. |
Property Getters/Setters Detail |
---|
getBidi/setBidi | |
public boolean getBidi() / public void setBidi(boolean value) |
When true, the columns in this section are laid out from right to left.
getBorderAlwaysInFront/setBorderAlwaysInFront | |
public boolean getBorderAlwaysInFront() / public void setBorderAlwaysInFront(boolean value) |
getBorderAppliesTo/setBorderAppliesTo | |
public int getBorderAppliesTo() / public void setBorderAppliesTo(int value) |
getBorderDistanceFrom/setBorderDistanceFrom | |
public int getBorderDistanceFrom() / public void setBorderDistanceFrom(int value) |
getBorders | |
public BorderCollection getBorders() |
getBorderSurroundsFooter/setBorderSurroundsFooter | |
public boolean getBorderSurroundsFooter() / public void setBorderSurroundsFooter(boolean value) |
getBorderSurroundsHeader/setBorderSurroundsHeader | |
public boolean getBorderSurroundsHeader() / public void setBorderSurroundsHeader(boolean value) |
getBottomMargin/setBottomMargin | |
public double getBottomMargin() / public void setBottomMargin(double value) |
getCharactersPerLine/setCharactersPerLine | |
public int getCharactersPerLine() / public void setCharactersPerLine(int value) |
Minimum value of the property is 1. Maximum value depends on page width and font size of the Normal style. Minimum character pitch is 90 percent of the font size. For example, maximum number of characters per line of a Letter page with one-inch margins is 43.
By default, the property has a value, on which character pitch equals to font size of the Normal style.
getDifferentFirstPageHeaderFooter/setDifferentFirstPageHeaderFooter | |
public boolean getDifferentFirstPageHeaderFooter() / public void setDifferentFirstPageHeaderFooter(boolean value) |
getEndnoteOptions | |
public EndnoteOptions getEndnoteOptions() |
getFirstPageTray/setFirstPageTray | |
public int getFirstPageTray() / public void setFirstPageTray(int value) |
getFooterDistance/setFooterDistance | |
public double getFooterDistance() / public void setFooterDistance(double value) |
getFootnoteOptions | |
public FootnoteOptions getFootnoteOptions() |
getGutter/setGutter | |
public double getGutter() / public void setGutter(double value) |
getHeaderDistance/setHeaderDistance | |
public double getHeaderDistance() / public void setHeaderDistance(double value) |
getLayoutMode/setLayoutMode | |
public int getLayoutMode() / public void setLayoutMode(int value) |
getLeftMargin/setLeftMargin | |
public double getLeftMargin() / public void setLeftMargin(double value) |
getLineNumberCountBy/setLineNumberCountBy | |
public int getLineNumberCountBy() / public void setLineNumberCountBy(int value) |
getLineNumberDistanceFromText/setLineNumberDistanceFromText | |
public double getLineNumberDistanceFromText() / public void setLineNumberDistanceFromText(double value) |
getLineNumberRestartMode/setLineNumberRestartMode | |
public int getLineNumberRestartMode() / public void setLineNumberRestartMode(int value) |
getLinesPerPage/setLinesPerPage | |
public int getLinesPerPage() / public void setLinesPerPage(int value) |
Minimum value of the property is 1. Maximum value depends on page height and font size of the Normal style. Minimum line pitch is 136 percent of the font size. For example, maximum number of lines per page of a Letter page with one-inch margins is 39.
By default, the property has a value, on which line pitch is in 1.5 times greater than font size of the Normal style.
getLineStartingNumber/setLineStartingNumber | |
public int getLineStartingNumber() / public void setLineStartingNumber(int value) |
getMirrorMargins/setMirrorMargins | |
public boolean getMirrorMargins() / public void setMirrorMargins(boolean value) |
getMultiplePages | |
public Aspose.Words.Settings.MultiplePagesType getMultiplePages() |
getOddAndEvenPagesHeaderFooter/setOddAndEvenPagesHeaderFooter | |
public boolean getOddAndEvenPagesHeaderFooter() / public void setOddAndEvenPagesHeaderFooter(boolean value) |
getOrientation/setOrientation | |
public int getOrientation() / public void setOrientation(int value) |
Changing Orientation swaps
getOtherPagesTray/setOtherPagesTray | |
public int getOtherPagesTray() / public void setOtherPagesTray(int value) |
getPageHeight/setPageHeight | |
public double getPageHeight() / public void setPageHeight(double value) |
getPageNumberStyle/setPageNumberStyle | |
public int getPageNumberStyle() / public void setPageNumberStyle(int value) |
getPageStartingNumber/setPageStartingNumber | |
public int getPageStartingNumber() / public void setPageStartingNumber(int value) |
getPageWidth/setPageWidth | |
public double getPageWidth() / public void setPageWidth(double value) |
getPaperSize/setPaperSize | |
public int getPaperSize() / public void setPaperSize(int value) |
Setting this property updates
getRestartPageNumbering/setRestartPageNumbering | |
public boolean getRestartPageNumbering() / public void setRestartPageNumbering(boolean value) |
getRightMargin/setRightMargin | |
public double getRightMargin() / public void setRightMargin(double value) |
getRtlGutter/setRtlGutter | |
public boolean getRtlGutter() / public void setRtlGutter(boolean value) |
getSectionStart/setSectionStart | |
public int getSectionStart() / public void setSectionStart(int value) |
getSheetsPerBooklet/setSheetsPerBooklet | |
public int getSheetsPerBooklet() / public void setSheetsPerBooklet(int value) |
getSuppressEndnotes/setSuppressEndnotes | |
public boolean getSuppressEndnotes() / public void setSuppressEndnotes(boolean value) |
getTextColumns | |
public TextColumnCollection getTextColumns() |
getTextOrientation/setTextOrientation | |
public int getTextOrientation() / public void setTextOrientation(int value) |
getTopMargin/setTopMargin | |
public double getTopMargin() / public void setTopMargin(double value) |
getVerticalAlignment/setVerticalAlignment | |
public int getVerticalAlignment() / public void setVerticalAlignment(int value) |
Method Detail |
---|
clearFormatting | |
public void clearFormatting() |
fetchInheritedBorderAttr | |
public java.lang.Object fetchInheritedBorderAttr(int key) |
getDirectBorderAttr | |
public java.lang.Object getDirectBorderAttr(int key) |
getPossibleBorderKeys | |
public java.util.TreeMap getPossibleBorderKeys() |
setBorderAttr | |
public void setBorderAttr(int key, java.lang.Object value) |