public void AddTextRunsToCurrentLine(IEnumerable<EditableRun> textRuns)
{
RemoveSelectedText();
int startLineNum = textLineWriter.LineNumber;
int startCharIndex = textLineWriter.CharIndex;
bool isRecordingHx = EnableUndoHistoryRecording;
EnableUndoHistoryRecording = false;
foreach (EditableRun t in textRuns)
{
if (t.IsLineBreak)
{
textLineWriter.SplitToNewLine();
CurrentLineNumber++;
}
else
{
textLineWriter.AddTextSpan(t);
}
}
EnableUndoHistoryRecording = isRecordingHx;
commandHistory.AddDocAction(
new DocActionInsertRuns(textRuns, startLineNum, startCharIndex,
textLineWriter.LineNumber, textLineWriter.CharIndex));
updateJustCurrentLine = false;
TextEditRenderBox.NotifyTextContentSizeChanged(visualTextSurface);
}
public void AddTextRunToCurrentLine(EditableRun t)