public CombinedChunk(ITextChunk left, ITextChunk right) { _chunks = new ITextChunk[2]; _chunks[0] = left; _chunks[1] = right; _length = left.Length + right.Length; }
public SeparatedChunk(string separator, ITextChunk left, ITextChunk right) { _separator = separator; _chunks = new ITextChunk[2]; _chunks[0] = left; _chunks[1] = right; _length = left.Length + right.Length; }
public static string ToText(this ITextChunk chunk) { var sb = new System.Text.StringBuilder(chunk.Length); var writer = new System.IO.StringWriter(sb); chunk.WriteTo(writer); return(sb.ToString()); }
public WrappedChunk(WrappedTextProvider wrapper, ITextChunk chunk) { _text = wrapper; _chunk = chunk; }