다음을 통해 공유


FlowDocument.ContentEnd 속성

정의

TextPointer에 있는 콘텐츠의 끝을 나타내는 FlowDocument를 가져옵니다.

public:
 property System::Windows::Documents::TextPointer ^ ContentEnd { System::Windows::Documents::TextPointer ^ get(); };
public System.Windows.Documents.TextPointer ContentEnd { get; }
member this.ContentEnd : System.Windows.Documents.TextPointer
Public ReadOnly Property ContentEnd As TextPointer

속성 값

TextPointer

TextPointer에 있는 콘텐츠의 끝을 나타내는 FlowDocument입니다.

예제

다음 예제에서는 속성을 사용하여 ContentEnd 콘텐츠를 에 추가합니다 FlowDocument.

// Create a new, empty FlowDocument.
FlowDocument flowDoc = new FlowDocument();

// Append an initial paragraph at the "end" of the empty FlowDocument.
flowDoc.Blocks.Add(new Paragraph(new Run(
    "Since the new FlowDocument is empty at this point, this will be the initial content " +
    "in the FlowDocument."
)));
// Append a line-break.
flowDoc.Blocks.Add(new Paragraph(new LineBreak()));
// Append another paragraph.
flowDoc.Blocks.Add(new Paragraph(new Run(
    "This text will be in a paragraph that is inserted at the end of the FlowDocument.")));
    ' Create a new, empty FlowDocument.
Dim flowDocEnd As New FlowDocument()

    ' Append an initial paragraph at the "end" of the empty FlowDocument.
flowDocEnd.Blocks.Add(New Paragraph(New Run("Since the new FlowDocument is empty at this point, this will be the initial content " & "in the FlowDocument.")))
    ' Append a line-break.
flowDocEnd.Blocks.Add(New Paragraph(New LineBreak()))
    ' Append another paragraph.
flowDocEnd.Blocks.Add(New Paragraph(New Run("This text will be in a paragraph that is inserted at the end of the FlowDocument.")))

설명

합니다 ContentEnd 속성은 콘텐츠 끝에 추가 하는 데 자주 사용 된 FlowDocument합니다.

TextPointer 이 속성에서 반환한 항상 해당 LogicalDirectionLogicalDirection.Forward합니다.

적용 대상

추가 정보