Paragraph 构造函数

定义

初始化 Paragraph 类的新实例。

重载

名称 说明
Paragraph()

初始化类的新空实例 Paragraph

Paragraph(Inline)

初始化类的新实例 Paragraph ,以指定 Inline 对象作为其初始内容。

Paragraph()

初始化类的新空实例 Paragraph

public:
 Paragraph();
public Paragraph();
Public Sub New ()

适用于

Paragraph(Inline)

初始化类的新实例 Paragraph ,以指定 Inline 对象作为其初始内容。

public:
 Paragraph(System::Windows::Documents::Inline ^ inline);
public Paragraph(System.Windows.Documents.Inline inline);
new System.Windows.Documents.Paragraph : System.Windows.Documents.Inline -> System.Windows.Documents.Paragraph
Public Sub New (inline As Inline)

参数

inline
Inline

一个 Inline 对象,指定新 Paragraph内容的初始内容。

示例

以下示例演示了此构造函数的用法。

// A child Inline element for the new Paragraph element.
Run runx = new Run("Text to be hosted in the new paragraph...");

// After this line executes, the new element "parx"
// contains the specified Inline element, "runx".
Paragraph parx = new Paragraph(runx);
' A child Inline element for the new Paragraph element.
Dim runx As New Run("Text to be hosted in the new paragraph...")

' After this line executes, the new element "parx"
' contains the specified Inline element, "runx".
Dim parx As New Paragraph(runx)

适用于