ParagraphFormatLineSpacingRule Property |
Gets or sets the line spacing for the paragraph.
Namespace:
Aspose.Words
Assembly:
Aspose.Words (in Aspose.Words.dll) Version: 21.1.0
Syntax
public LineSpacingRule LineSpacingRule { get; set; }
Public Property LineSpacingRule As LineSpacingRule
Get
Set
public:
property LineSpacingRule LineSpacingRule {
LineSpacingRule get ();
void set (LineSpacingRule value);
}
member LineSpacingRule : LineSpacingRule with get, set
Property Value
Type:
LineSpacingRule
Examples
Shows how to work with line spacing.
Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);
builder.ParagraphFormat.LineSpacingRule = LineSpacingRule.AtLeast;
builder.ParagraphFormat.LineSpacing = 20;
builder.Writeln("Minimum line spacing of 20.");
builder.Writeln("Minimum line spacing of 20.");
builder.ParagraphFormat.LineSpacingRule = LineSpacingRule.Exactly;
builder.ParagraphFormat.LineSpacing = 5;
builder.Writeln("Line spacing of exactly 5.");
builder.Writeln("Line spacing of exactly 5.");
builder.ParagraphFormat.LineSpacingRule = LineSpacingRule.Multiple;
builder.ParagraphFormat.LineSpacing = 18;
builder.Writeln("Line spacing of 1.5 default lines.");
builder.Writeln("Line spacing of 1.5 default lines.");
doc.Save(ArtifactsDir + "ParagraphFormat.LineSpacing.docx");
See Also