title: Pixels of Thin Chars are not of the Exact Requested Color
body: <p>To recover character bounding boxes I draw the full HTML onto HTML canvas in different colors so I can locate them by their pixel color values. Not all pixel colors are those that I assigned to the character, but most are e.g. majority of the pixels of an 'a' drawn with font color rgb(0,0,100) have the color rgb(0,0,100).</p>
  <p>However, for pixels of some thin chars such as '-' or '2' of the exponent, the colors are none of those assigned. If I assigned (0,20,71) as the font color, majority of the pixels color values are NOT (0,20,71) but instead (66,81,119). Due to these alternate colors, when I go looking for pixels with color (0,20,71) I find none, and end up without a bounding box for '-' etc.</p>
  <ol>
  <li>Are there color choices that minimize use of alternate colors to display a character? If yes then perhaps I could use those colors instead of random color values.</li>
  <li>Is there an HTML rendering attribute that I could turn on/off to minimize the use of alternate colors?</li>
  <li>Or is there perhaps a simpler way of doing all this? I used to draw those characters one after another, which worked better, but was too slow to be useful.</li>
  </ol>
  <p>Note that I don't need the bounding boxes that could be recovered using the font information or getBoundingClientRect as they are not always exact.</p>
  <p>Note: This question is cross posted from graphicdesign as it is more appropriate for this forum.</p>