public virtual void DeleteText(int startPos, int length) { String str = Text; str = str.Remove(startPos, length); SetText(str); if (m_CursorPos > startPos) { CursorPos = m_CursorPos - length; } CursorEnd = m_CursorPos; }