Home > Programming > Contrast reader

Contrast reader

June 28th, 2008

If you ever used Google AdSense or an other advertising company that allows you to modify the colours/layout of your advertisement, you may have noticed that they automatically adjust the colour of the text if the background doesn't provide enough contrast. This is a method these companies use to make sure no one makes their advertisement blocks invisible, like a white zone on which people can accidentally click.

I wondered how they did this, and did my own little experiment. It turned out quite different than I had in mind, but its still a fun tool. Contrast reader uses Javascript to check the difference in colour and gives you a rating between 0 and 765. The closer you are to zero, the harder your text is to read. Please don't mind the text ratings I added, it could be it gives your text a "bad" but it can still be perfectly readable.

Contrast reader

Iron Programming

  1. No comments yet.
  1. No trackbacks yet.
Porn Misson, Crackers