API Reference
PowerPointTextStyle
Defines text formatting that can be applied to runs or paragraphs.
Inheritance
- ValueType
- PowerPointTextStyle
Constructors
public PowerPointTextStyle(Nullable<Int32> fontSize = null, String fontName = null, String color = null, Nullable<Boolean> bold = null, Nullable<Boolean> italic = null, Nullable<Boolean> underline = null, String highlightColor = null) #Creates a new text style instance.
Parameters
- fontSize System.Nullable{System.Int32} = null
- fontName System.String = null
- color System.String = null
- bold System.Nullable{System.Boolean} = null
- italic System.Nullable{System.Boolean} = null
- underline System.Nullable{System.Boolean} = null
- highlightColor System.String = null
Methods
public Void Apply(PowerPointParagraph paragraph) #VoidApplies the style to a text run.
Parameters
- run OfficeIMO.PowerPoint.PowerPointTextRun
Apply(OfficeIMO.PowerPoint.PowerPointParagraph paragraph) #Applies the style to a paragraph's default run.
Parameters
- paragraph OfficeIMO.PowerPoint.PowerPointParagraph
public PowerPointTextStyle WithBold(Nullable<Boolean> bold) #PowerPointTextStyleReturns a copy with bold formatting updated.
Parameters
- bold System.Nullable{System.Boolean}
public PowerPointTextStyle WithColor(String color) #PowerPointTextStyleReturns a copy with a new color.
Parameters
- color System.String
public PowerPointTextStyle WithFontName(String fontName) #PowerPointTextStyleReturns a copy with a new font name.
Parameters
- fontName System.String
public PowerPointTextStyle WithFontSize(Nullable<Int32> fontSize) #PowerPointTextStyleReturns a copy with a new font size.
Parameters
- fontSize System.Nullable{System.Int32}
public PowerPointTextStyle WithHighlightColor(String highlightColor) #PowerPointTextStyleReturns a copy with a new highlight color.
Parameters
- highlightColor System.String
public PowerPointTextStyle WithItalic(Nullable<Boolean> italic) #PowerPointTextStyleReturns a copy with italic formatting updated.
Parameters
- italic System.Nullable{System.Boolean}
public PowerPointTextStyle WithUnderline(Nullable<Boolean> underline) #PowerPointTextStyleReturns a copy with underline formatting updated.
Parameters
- underline System.Nullable{System.Boolean}
Inherited Methods
Properties
public Nullable<Int32> FontSize { get; } #Font size in points.
public String Color { get; } #Text color in hex (e.g. "1F4E79").
public Nullable<Boolean> Bold { get; } #Bold formatting.
public Nullable<Boolean> Italic { get; } #Italic formatting.
public Nullable<Boolean> Underline { get; } #Underline formatting.
public String HighlightColor { get; } #Highlight color in hex (e.g. "FFF59D").
public static PowerPointTextStyle Title { get; } #A preset for typical slide titles.
public static PowerPointTextStyle Subtitle { get; } #A preset for subtitles.
public static PowerPointTextStyle Body { get; } #A preset for body text.
public static PowerPointTextStyle Caption { get; } #A preset for captions or footnotes.
public static PowerPointTextStyle Emphasis { get; } #A preset that enables bold emphasis.