/// <summary>
 /// Redraws the specified text segment.
 /// </summary>
 internal void Redraw(ISegment segment)
 {
     codeEditor.Redraw(segment, DispatcherPriority.Normal);
 }