public static WordEndOffset ( string searchText, int offset ) : int | ||
searchText | string | |
offset | int | |
return | int |
protected override void Run() { for (int i = 0; i < Count; i++) { Editor.Caret.Offset = StringUtils.WordEndOffset(Editor.Text, Editor.Caret.Offset); } }
protected override void Run() { int offset = Editor.Caret.Offset; for (int i = 0; i < Count && offset < Editor.Length; i++) { offset = StringUtils.WordEndOffset(Editor.Text, offset); } offset = (offset < Editor.Length) ? offset + 1 : offset; Editor.SetSelection(Editor.Caret.Offset, offset); ClipboardActions.Cut(Editor); }