java.lang.Object
com.aspose.words.PageVerticalAlignment
public class PageVerticalAlignment
- extends java.lang.Object
Utility class containing constants.
Specifies vertical justification of text on each page.
Example:
Shows how to insert sections using DocumentBuilder, specify page setup for a section and reset page setup to defaults.
DocumentBuilder builder = new DocumentBuilder();
// Modify the first section in the document.
builder.getPageSetup().setOrientation(Orientation.LANDSCAPE);
builder.getPageSetup().setVerticalAlignment(PageVerticalAlignment.CENTER);
builder.writeln("Section 1, landscape oriented and text vertically centered.");
// Start a new section and reset its formatting to defaults.
builder.insertBreak(BreakType.SECTION_BREAK_NEW_PAGE);
builder.getPageSetup().clearFormatting();
builder.writeln("Section 2, back to default Letter paper size, portrait orientation and top alignment.");
builder.getDocument().save(getMyDir() + "PageSetup.ClearFormatting Out.doc");
- See Also:
- PageSetup, PageSetup.VerticalAlignment
Field Summary |
static final int | BOTTOM | |
Text is aligned at the bottom of the page.
|
static final int | CENTER | |
Text is aligned in the middle of the page.
|
static final int | JUSTIFY | |
Text is spread to fill the page.
|
static final int | TOP | |
Text is aligned at the top of the page.
|
BOTTOM | |
public static final int BOTTOM |
-
Text is aligned at the bottom of the page.
CENTER | |
public static final int CENTER |
-
Text is aligned in the middle of the page.
JUSTIFY | |
public static final int JUSTIFY |
-
Text is spread to fill the page.
TOP | |
public static final int TOP |
-
Text is aligned at the top of the page.
See Also:
Aspose.Words Documentation - the home page for the Aspose.Words Product Documentation.
Aspose.Words Support Forum - our preferred method of support.