public static void replaceText(TextBuffer target,
Replaces text in the target TextBuffer with the input data with
the smallest changes possible. In particular, this will use the
compare algorithm to determine the smallest changes (to the
TextBuffer) to make to the TextBuffer to, in effect, replace the
target region of text with the input data text.
Used when it's important to preserve OffsetMark's in the
target - The TextBuffer we'll be making changes to.
offset - The start offset of the target region in "target".
length - The length of the target region in "target".
data - The new characters that we'll be inserting into "target".