Why don't you see what it would take to implement the colorizer
as a proper io.Writer (or io.Reader), respecting line boundaries?
I promise it won't be ugly. It'll also be easier to test, and to test
more thoroughly.

(Veering offtopic, I find some parts of the the wikipedia page on
SOLID disturbing. Some of those principles are just plain wrong or
inapplicable. Or at least phrased so badly as to encourage bad
programming, which amounts to the same thing. E.g. "many client-
specific interfaces are better than one general-purpose interface".
This would seem to encourage our LineWriter as inherently better
than io.Writer. Ludicrous. "objects in a program should be replaceable
with instances of their subtypes". Go types do not have subtypes.
Anyway, Go is not an object-oriented language, at least not in that
sense. You might be better served by the book [The Practice of
Programming](http://cm.bell-labs.com/cm/cs/tpop/), and its previous, somewhat dated incarnation, The
Elements of Programming Style, pithily summarized:
http://ellard.org/dan/www/libsq/ref/style.html)