API Reference
PowerPointParagraph
Represents a paragraph within a textbox.
Inheritance
- Object
- PowerPointParagraph
Methods
public PowerPointParagraph AddFormattedText(String text, Boolean bold = false, Boolean italic = false, Nullable<TextUnderlineValues> underline = null) #PowerPointParagraphAdds formatted text to the paragraph and returns the paragraph for chaining.
Parameters
- text System.String
- bold System.Boolean = false
- italic System.Boolean = false
- underline System.Nullable{DocumentFormat.OpenXml.Drawing.TextUnderlineValues} = null
public PowerPointTextRun AddRun(String text, Action<PowerPointTextRun> configure = null) #PowerPointTextRunAdds a run to the paragraph.
Parameters
- text System.String
- configure System.Action{OfficeIMO.PowerPoint.PowerPointTextRun} = null
public PowerPointParagraph AddText(String text, Action<PowerPointTextRun> configure = null) #PowerPointParagraphAdds a run to the paragraph and returns the paragraph for chaining.
Parameters
- text System.String
- configure System.Action{OfficeIMO.PowerPoint.PowerPointTextRun} = null
public Int32 ReplaceText(String oldValue, String newValue) #Int32Replaces text within the paragraph runs while preserving formatting.
Parameters
- oldValue System.String
- newValue System.String
public PowerPointParagraph SetAlignment(TextAlignmentTypeValues alignment) #PowerPointParagraphSets paragraph alignment and returns the paragraph for chaining.
Parameters
- alignment DocumentFormat.OpenXml.Drawing.TextAlignmentTypeValues
public PowerPointParagraph SetBold(Boolean isBold = true) #PowerPointParagraphSets the current run bold property and returns the paragraph for chaining.
Parameters
- isBold System.Boolean = true
public Void SetBullet(Char bulletChar = '•') #VoidApplies a character bullet to the paragraph.
Parameters
- bulletChar System.Char = '•'
public PowerPointParagraph SetBulletFont(String fontName) #PowerPointParagraphSets the bullet font and returns the paragraph for chaining.
Parameters
- fontName System.String
public PowerPointParagraph SetBulletSizePercent(Int32 percent) #PowerPointParagraphSets the bullet size in percent (100 = 100%) and returns the paragraph for chaining.
Parameters
- percent System.Int32
public PowerPointParagraph SetBulletSizePoints(Int32 sizePoints) #PowerPointParagraphSets the bullet size in points and returns the paragraph for chaining.
Parameters
- sizePoints System.Int32
public PowerPointParagraph SetColor(String color) #PowerPointParagraphSets the current run color and returns the paragraph for chaining.
Parameters
- color System.String
public PowerPointParagraph SetFontName(String fontName) #PowerPointParagraphSets the current run font name and returns the paragraph for chaining.
Parameters
- fontName System.String
public PowerPointParagraph SetFontSize(Int32 size) #PowerPointParagraphSets the current run font size in points and returns the paragraph for chaining.
Parameters
- size System.Int32
public PowerPointParagraph SetHangingCm(Double centimeters) #PowerPointParagraphSets a hanging indent in centimeters and returns the paragraph for chaining.
Parameters
- centimeters System.Double
public PowerPointParagraph SetHangingInches(Double inches) #PowerPointParagraphSets a hanging indent in inches and returns the paragraph for chaining.
Parameters
- inches System.Double
public PowerPointParagraph SetHangingPoints(Double points) #PowerPointParagraphSets a hanging indent in points and returns the paragraph for chaining.
Parameters
- points System.Double
public PowerPointParagraph SetHighlightColor(String color) #PowerPointParagraphSets the current run highlight color and returns the paragraph for chaining.
Parameters
- color System.String
public PowerPointParagraph SetIndentCm(Double centimeters) #PowerPointParagraphSets indentation in centimeters and returns the paragraph for chaining.
Parameters
- centimeters System.Double
public PowerPointParagraph SetIndentInches(Double inches) #PowerPointParagraphSets indentation in inches and returns the paragraph for chaining.
Parameters
- inches System.Double
public PowerPointParagraph SetIndentPoints(Double points) #PowerPointParagraphSets indentation in points and returns the paragraph for chaining.
Parameters
- points System.Double
public PowerPointParagraph SetItalic(Boolean isItalic = true) #PowerPointParagraphSets the current run italic property and returns the paragraph for chaining.
Parameters
- isItalic System.Boolean = true
public PowerPointParagraph SetLeftMarginCm(Double centimeters) #PowerPointParagraphSets left margin in centimeters and returns the paragraph for chaining.
Parameters
- centimeters System.Double
public PowerPointParagraph SetLeftMarginInches(Double inches) #PowerPointParagraphSets left margin in inches and returns the paragraph for chaining.
Parameters
- inches System.Double
public PowerPointParagraph SetLeftMarginPoints(Double points) #PowerPointParagraphSets left margin in points and returns the paragraph for chaining.
Parameters
- points System.Double
public PowerPointParagraph SetLevel(Int32 level) #PowerPointParagraphSets the bullet/list level and returns the paragraph for chaining.
Parameters
- level System.Int32
public PowerPointParagraph SetLineSpacingMultiplier(Double multiplier) #PowerPointParagraphSets line spacing as a multiplier (1.0 = 100%) and returns the paragraph for chaining.
Parameters
- multiplier System.Double
public PowerPointParagraph SetLineSpacingPoints(Double points) #PowerPointParagraphSets line spacing in points and returns the paragraph for chaining.
Parameters
- points System.Double
public Void SetNumbered(TextAutoNumberSchemeValues style, Int32 startAt = 1) #VoidApplies an auto-numbered bullet to the paragraph.
Parameters
- style DocumentFormat.OpenXml.Drawing.TextAutoNumberSchemeValues
- startAt System.Int32 = 1
public Void SetNumbered(TextAutoNumberSchemeValues style) #VoidApplies an auto-numbered bullet to the paragraph without resetting the start value.
Parameters
- arg1 DocumentFormat.OpenXml.Drawing.TextAutoNumberSchemeValues
public Void SetNumbered(Int32 startAt = 1) #VoidApplies a default auto-numbered bullet (Arabic period) to the paragraph.
Parameters
- startAt System.Int32 = 1
public PowerPointParagraph SetSpaceAfterPoints(Double points) #PowerPointParagraphSets space after the paragraph in points and returns the paragraph for chaining.
Parameters
- points System.Double
public PowerPointParagraph SetSpaceBeforePoints(Double points) #PowerPointParagraphSets space before the paragraph in points and returns the paragraph for chaining.
Parameters
- points System.Double
public PowerPointParagraph SetText(String text) #PowerPointParagraphSets the paragraph text and returns the paragraph for chaining.
Parameters
- text System.String
public PowerPointParagraph SetUnderline(Boolean underline = true) #PowerPointParagraphSets the current run underline property and returns the paragraph for chaining.
Parameters
- underline System.Boolean = true
Inherited Methods
public override Boolean Equals(Object obj) #BooleanParameters
- obj Object
Properties
public String Text { get; set; } #Text content of the paragraph.
public IReadOnlyList<PowerPointTextRun> Runs { get; } #Runs within the paragraph.
public Nullable<TextAlignmentTypeValues> Alignment { get; set; } #Gets or sets paragraph alignment.
public Nullable<Int32> Level { get; set; } #Gets or sets the bullet/list level (0-8).
public Nullable<Double> IndentPoints { get; set; } #Gets or sets paragraph indentation in points.
public Nullable<Double> LeftMarginPoints { get; set; } #Gets or sets paragraph left margin in points.
public Nullable<Double> LineSpacingPoints { get; set; } #Gets or sets line spacing in points.
public Nullable<Double> LineSpacingMultiplier { get; set; } #Gets or sets line spacing as a multiplier (1.0 = 100%).
public Nullable<Double> SpaceBeforePoints { get; set; } #Gets or sets space before the paragraph in points.
public Nullable<Double> SpaceAfterPoints { get; set; } #Gets or sets space after the paragraph in points.
public String BulletFontName { get; set; } #Gets or sets the bullet font name.
public Nullable<Int32> BulletSizePoints { get; set; } #Gets or sets the bullet size in points.
public Nullable<Int32> BulletSizePercent { get; set; } #Gets or sets the bullet size in percent (100 = 100%).