public class MarginInfo extends Object implements com.aspose.ms.System.ICloneable
Encapsulates margin info.
[C#] Pdf pdf1 = new Pdf(); pdf1.PageSetup.PageHeight = PageSize.A2Height; Section sec1 = pdf1.Sections.Add(); Text text1 = new Text(sec1,"this is text content"); text1.Margin.Top = 30; sec1.Paragraphs.Add(text1); pdf1.Save(...); [Visual Basic] Dim pdf1 As Pdf = New Pdf() pdf1.PageSetup.PageHeight = PageSize.A2Height Dim sec1 As Section = pdf1.Sections.Add() Dim text1 As Text = New Text(sec1, "this is text content") text1.Margin.Top = 30 sec1.Paragraphs.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 and Description |
---|
MarginInfo()
Initializes a new instance of the
MarginInfo class. |
MarginInfo(float widthOfEachPart)
Initializes a new instance of the
MarginInfo class with all side's width set in specified value. |
Modifier and Type | Method and Description |
---|---|
Object |
deepClone()
Clones a new
MarginInfo object. |
float |
getBottom()
Gets or sets a float value that indicates the bottom margin.
|
float |
getInner()
Gets or sets a float value that indicates the inner margin.
|
float |
getLeft()
Gets or sets a float value that indicates the left margin.
|
float |
getOuter()
Gets or sets a float value that indicates the outer margin.
|
float |
getRight()
Gets or sets a float value that indicates the right margin.
|
float |
getTop()
Gets or sets a float value that indicates the top margin.
|
void |
setBottom(float value) |
void |
setInner(float value) |
void |
setLeft(float value) |
void |
setOuter(float value) |
void |
setRight(float value) |
void |
setTop(float value) |
public MarginInfo()
Initializes a new instance of the MarginInfo
class.
public MarginInfo(float widthOfEachPart)
Initializes a new instance of the MarginInfo
class with all side's width set in specified value.
public float getLeft()
Gets or sets a float value that indicates the left margin. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,"10cm" or "5inch".
public void setLeft(float value)
public float getRight()
Gets or sets a float value that indicates the right margin. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,"10cm" or "5inch".
public void setRight(float value)
public float getTop()
Gets or sets a float value that indicates the top margin. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,"10cm" or "5inch".
public void setTop(float value)
public float getBottom()
Gets or sets a float value that indicates the bottom margin. The unit is point. In XML,the default unit is point,but cm and inch are also supported. For example,"10cm" or "5inch".
public void setBottom(float value)
public float getInner()
Gets or sets a float value that indicates the inner margin. The unit is point. In case of mirror margins we can use Inner and Outer instead of Left and Right In XML,the default unit is point,but cm and inch are also supported. For example,"10cm" or "5inch".
public void setInner(float value)
public float getOuter()
Gets or sets a float value that indicates the outer margin. The unit is point. In case of mirror margins we can use Inner and Outer instead of Left and Right In XML,the default unit is point,but cm and inch are also supported. For example,"10cm" or "5inch".
public void setOuter(float value)
public Object deepClone()
Clones a new MarginInfo
object.
deepClone
in interface com.aspose.ms.System.ICloneable
Copyright © 2016 Aspose. All Rights Reserved.