Fix coverage_doctest calculations again

The Sphinx percentages should hopefully now be correct.  Assuming they are,
then the actual Sphinx score is 39% (2241 of 5682).

Also start to factor out the colors, so they can more easily be added in
verbose mode.