internal void RemoveSelectedText()
{
if (this.Document == null)
{
throw ThrowUtil.NoDocumentAssigned();
}
selection.ReplaceSelectionWithText(string.Empty);
if (!selection.IsEmpty)
{
foreach (ISegment s in selection.Segments)
{
Debug.Assert(this.ReadOnlySectionProvider.GetDeletableSegments(s).Count() == 0);
}
}
}