Presentation.DefaultTextStyle Property
Gets or sets the default text style for the presentation.
Namespace: DevExpress.Docs.Presentation
Assembly: DevExpress.Docs.Presentation.v25.1.dll
NuGet Package: DevExpress.Docs.Presentation
Declaration
Property Value
| Type | Description |
|---|---|
| TextStyle | Contains text style settings. |
Remarks
The Presentation.DefaultTextStyle is applied to all text elements in the presentation unless you specify a different style for certain text elements.
The following code snippet specifies the default text style properties for Level 1 texts:
using DevExpress.Docs.Presentation;
namespace PresentationApiSample;
public class Program {
public static void Main(string[] _) {
// Load a presentation from a file
Presentation presentation = new Presentation(File.ReadAllBytes(@"..\..\..\data\my-presentation.pptx"));
// Set the paragraph text style properties for texts of Level 1
presentation.DefaultTextStyle.Level1ParagraphProperties.TextProperties.Bold = true;
presentation.DefaultTextStyle.Level1ParagraphProperties.TextProperties.Italic = true;
}
}
See Also