Italic

Font.Italic property

如果字体格式为斜体,则为 True。

public bool Italic { get; set; }

例子

演示如何使用文档生成器编写斜体文本。

Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);

builder.Font.Size = 36;
builder.Font.Italic = true;
builder.Writeln("Hello world!");

doc.Save(ArtifactsDir + "Font.Italic.docx");

也可以看看