Moves start and end pointers of the range to exclude leading and trailing white-space characters from the current range.
Namespace:
C1.Win.XmlEditorAssembly:
C1.Win.XmlEditor.2 (in C1.Win.XmlEditor.2.dll)
Syntax
| Visual Basic (Declaration) |
|---|
Public Sub Trim |
Examples
The code below sets new background color for all words in selection, excluding leading and trailing white spaces.
Copy CodeC#
privatevoid button1_Click(object sender, EventArgs e)
{
C1TextRange r = c1XmlEditor1.Selection.Clone();
r.Trim();
r.ApplyStyle("background-color", "#999999", C1StyleType.Character);
} |
See Also