[]
        
(Showing Draft Content)

C1.WPF.RichTextBox.Documents.C1TextElement.Split

Split Method

Split(int, bool)

Splits this C1TextElement at the specified offset into two elements of the same type with the same style properties.

Declaration
public virtual C1TextPointer Split(int offset, bool splitEdges)
Parameters
Type Name Description
int offset

The offset where to split, elements in positions greater or equal to the offset are added to the second element.

bool splitEdges

Indicates whether the element should be split when the position is at the start or end of the element.

Returns
Type Description
C1TextPointer

Returns the position in the parent element between this element and the new element.

Exceptions
Type Condition
InvalidOperationException

this element has no parent.

Split(int)

Splits this C1TextElement at the specified offset into two elements of the same type with the same style properties.

Declaration
public C1TextPointer Split(int offset)
Parameters
Type Name Description
int offset

The offset where to split, elements in positions greater or equal to the offset are added to the second element.

Returns
Type Description
C1TextPointer

Returns the position in the parent element between this element and the new element.

Exceptions
Type Condition
InvalidOperationException

this element has no parent.