<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: Testing Color Contrast for WCAG 1 &#038; 2</title>
	<atom:link href="http://www.joedolson.com/articles/2008/05/testing-color-contrast/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.joedolson.com/articles/2008/05/testing-color-contrast/</link>
	<description>Tips and Commentary on Web Accessibility, Usability, and Search Marketing best practices.</description>
	<pubDate>Sun, 12 Oct 2008 16:52:51 +0000</pubDate>
	<generator>http://wordpress.org/?v=abc</generator>
		<item>
		<title>By: Joe Dolson</title>
		<link>http://www.joedolson.com/articles/2008/05/testing-color-contrast/#comment-27698</link>
		<dc:creator>Joe Dolson</dc:creator>
		<pubDate>Fri, 03 Oct 2008 14:02:03 +0000</pubDate>
		<guid isPermaLink="false">http://www.joedolson.com/articles/?p=242#comment-27698</guid>
		<description>As mysterious as it is, it's nice to know that I don't have to recode anything! Glad you "solved" your problem.

(Don't you just love it when you "solve" problems without having the faintest idea what you might have changed?)</description>
		<content:encoded><![CDATA[<p>As mysterious as it is, it&#8217;s nice to know that I don&#8217;t have to recode anything! Glad you &#8220;solved&#8221; your problem.</p>
<p>(Don&#8217;t you just love it when you &#8220;solve&#8221; problems without having the faintest idea what you might have&nbsp;changed?)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Christophe Strobbe</title>
		<link>http://www.joedolson.com/articles/2008/05/testing-color-contrast/#comment-27680</link>
		<dc:creator>Christophe Strobbe</dc:creator>
		<pubDate>Fri, 03 Oct 2008 00:49:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.joedolson.com/articles/?p=242#comment-27680</guid>
		<description>Hi Joe,
I redid my spreadsheet with more intermediate columns (i.e. additional columns for the sRGB values) and the discrepancies are now gone. I still don’t know what was wrong with the original version. At least you don’t need to worry about your PHP function.</description>
		<content:encoded><![CDATA[<p>Hi Joe,<br />
I redid my spreadsheet with more intermediate columns (i.e. additional columns for the sRGB values) and the discrepancies are now gone. I still don’t know what was wrong with the original version. At least you don’t need to worry about your <acronym title="Hypertext PreProcessing">PHP</acronym>&nbsp;function.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joe Dolson</title>
		<link>http://www.joedolson.com/articles/2008/05/testing-color-contrast/#comment-27665</link>
		<dc:creator>Joe Dolson</dc:creator>
		<pubDate>Thu, 02 Oct 2008 16:27:03 +0000</pubDate>
		<guid isPermaLink="false">http://www.joedolson.com/articles/?p=242#comment-27665</guid>
		<description>The font size isn't part of the contrast comparison; it's simply that large font sizes have a different boundary measurement. So although a font size of 18pts will pass where 12pts won't, it's not because the algorithm is different; just because the judgement is different.

It would be interesting to experiment with incorporating the font-size directly into the algorithm, and if the guidelines specified a sliding scale that would probably be pretty reasonable; but with the guidelines having only a couple of markers, it doesn't really make any sense to incorporate that element into the algorithm itself.</description>
		<content:encoded><![CDATA[<p>The font size isn&#8217;t part of the contrast comparison; it&#8217;s simply that large font sizes have a different boundary measurement. So although a font size of 18pts will pass where 12pts won&#8217;t, it&#8217;s not because the algorithm is different; just because the judgement is different.</p>
<p>It would be interesting to experiment with incorporating the font-size directly into the algorithm, and if the guidelines specified a sliding scale that would probably be pretty reasonable; but with the guidelines having only a couple of markers, it doesn&#8217;t really make any sense to incorporate that element into the algorithm&nbsp;itself.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mike Cherim</title>
		<link>http://www.joedolson.com/articles/2008/05/testing-color-contrast/#comment-27664</link>
		<dc:creator>Mike Cherim</dc:creator>
		<pubDate>Thu, 02 Oct 2008 16:18:32 +0000</pubDate>
		<guid isPermaLink="false">http://www.joedolson.com/articles/?p=242#comment-27664</guid>
		<description>I'm curious, when concerning WCAG2, the font size affects the requirements (bigger text, less contrast allowed). Is this considered? Is this possibly affecting the outcome?</description>
		<content:encoded><![CDATA[<p>I&#8217;m curious, when concerning WCAG2, the font size affects the requirements (bigger text, less contrast allowed). Is this considered? Is this possibly affecting the&nbsp;outcome?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joe Dolson</title>
		<link>http://www.joedolson.com/articles/2008/05/testing-color-contrast/#comment-27663</link>
		<dc:creator>Joe Dolson</dc:creator>
		<pubDate>Thu, 02 Oct 2008 15:37:02 +0000</pubDate>
		<guid isPermaLink="false">http://www.joedolson.com/articles/?p=242#comment-27663</guid>
		<description>Interesting...it's certainly enough of a difference that you can be reasonably sure it's not a rounding error!

Without seeing your spreadsheet, obviously I can't make any practical comparisons between the two formulas - but something is clearly fishy!</description>
		<content:encoded><![CDATA[<p>Interesting&#8230;it&#8217;s certainly enough of a difference that you can be reasonably sure it&#8217;s not a rounding error!</p>
<p>Without seeing your spreadsheet, obviously I can&#8217;t make any practical comparisons between the two formulas - but something is clearly&nbsp;fishy!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Christophe Strobbe</title>
		<link>http://www.joedolson.com/articles/2008/05/testing-color-contrast/#comment-27660</link>
		<dc:creator>Christophe Strobbe</dc:creator>
		<pubDate>Thu, 02 Oct 2008 13:24:09 +0000</pubDate>
		<guid isPermaLink="false">http://www.joedolson.com/articles/?p=242#comment-27660</guid>
		<description>Hi Joe,
Thanks for posting the function. My implementation is in an ODF spreadsheet. I can't see anything wrong in your function. And after several rechecks I can't see anything wrong in my spreadsheet. Go figure!

Below are a few colour combinations that I tested yesterday:
#F0FFD2 on #006400: 
  7.06:1 (Spectrum Tester), 
  7.06:1 (Color Contrast Comparison), 
  6.8 (my spreadsheet)
#FFFFD2 on  #006400: 
  7.26:1 (Spectrum Tester), 
  7.26:1 (Color Contrast Comparison), 
  6.98 (my spreadsheet)
#EEEECC on #004B2D: 
  8.68:1(Color Contrast Comparison), 
  8.59 (my spreadsheet)

I discovered this while working on a WCAG 2.0 implementation. The first two combinations would meet WCAG 2 Level AAA according to your function, but would fail according to mine. Hmm.</description>
		<content:encoded><![CDATA[<p>Hi Joe,<br />
Thanks for posting the function. My implementation is in an ODF spreadsheet. I can&#8217;t see anything wrong in your function. And after several rechecks I can&#8217;t see anything wrong in my spreadsheet. Go figure!</p>
<p>Below are a few colour combinations that I tested yesterday:<br />
#F0FFD2 on #006400:<br />
  7.06:1 (Spectrum Tester),<br />
  7.06:1 (Color Contrast Comparison),<br />
  6.8 (my spreadsheet)<br />
#FFFFD2 on  #006400:<br />
  7.26:1 (Spectrum Tester),<br />
  7.26:1 (Color Contrast Comparison),<br />
  6.98 (my spreadsheet)<br />
#EEEECC on #004B2D:<br />
  8.68:1(Color Contrast Comparison),<br />
  8.59 (my spreadsheet)</p>
<p>I discovered this while working on a <acronym title="Web Content Accessibility Guidelines">WCAG</acronym> 2.0 implementation. The first two combinations would meet <acronym title="Web Content Accessibility Guidelines">WCAG</acronym> 2 Level AAA according to your function, but would fail according to mine.&nbsp;Hmm.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joe Dolson</title>
		<link>http://www.joedolson.com/articles/2008/05/testing-color-contrast/#comment-27637</link>
		<dc:creator>Joe Dolson</dc:creator>
		<pubDate>Wed, 01 Oct 2008 19:32:15 +0000</pubDate>
		<guid isPermaLink="false">http://www.joedolson.com/articles/?p=242#comment-27637</guid>
		<description>Thanks for comment, Christophe! The actual function I'm using to test relative luminance is this: 

&lt;pre&gt;
&lt;code&gt;
function luminosity($r,$r2,$g,$g2,$b,$b2) {
	$RsRGB = $r/255;
	$GsRGB = $g/255;
	$BsRGB = $b/255;
	$R = ($RsRGB &lt;= 0.03928) ? $RsRGB/12.92 : pow(($RsRGB+0.055)/1.055, 2.4);
	$G = ($GsRGB &lt;= 0.03928) ? $GsRGB/12.92 : pow(($GsRGB+0.055)/1.055, 2.4);
	$B = ($BsRGB &lt;= 0.03928) ? $BsRGB/12.92 : pow(($BsRGB+0.055)/1.055, 2.4);

	$RsRGB2 = $r2/255;
	$GsRGB2 = $g2/255;
	$BsRGB2 = $b2/255;
	$R2 = ($RsRGB2 &lt;= 0.03928) ? $RsRGB2/12.92 : pow(($RsRGB2+0.055)/1.055, 2.4);
	$G2 = ($GsRGB2 &lt;= 0.03928) ? $GsRGB2/12.92 : pow(($GsRGB2+0.055)/1.055, 2.4);
	$B2 = ($BsRGB2 &lt;= 0.03928) ? $BsRGB2/12.92 : pow(($BsRGB2+0.055)/1.055, 2.4);

	if ($r+$g+$b &lt;= $r2+$g2+$b2) {	
	$l2 = (.2126 * $R + 0.7152 * $G + 0.0722 * $B);
	$l1 = (.2126 * $R2 + 0.7152 * $G2 + 0.0722 * $B2);
	} else {
	$l1 = (.2126 * $R + 0.7152 * $G + 0.0722 * $B);
	$l2 = (.2126 * $R2 + 0.7152 * $G2 + 0.0722 * $B2);	
	}
	$luminosity = round(($l1 + 0.05)/($l2 + 0.05),2);
	return $luminosity;
}
&lt;/code&gt;
&lt;/pre&gt;

So, yes, I am actually applying that adjustment. The information posted in the article is just the definition of the ratio, not the actual formula used to derive the ratio -- it's simplified. I certainly won't claim that there can't be a bug in that function - and if you see one, by all means let me know!

Can you give me an example of the difference you're getting?</description>
		<content:encoded><![CDATA[<p>Thanks for comment, Christophe! The actual function I&#8217;m using to test relative luminance is this: </p>
<pre>
<code>
function luminosity($r,$r2,$g,$g2,$b,$b2) {
	$RsRGB = $r/255;
	$GsRGB = $g/255;
	$BsRGB = $b/255;
	$R = ($RsRGB < = 0.03928) ? $RsRGB/12.92 : pow(($RsRGB+0.055)/1.055, 2.4);
	$G = ($GsRGB <= 0.03928) ? $GsRGB/12.92 : pow(($GsRGB+0.055)/1.055, 2.4);
	$B = ($BsRGB <= 0.03928) ? $BsRGB/12.92 : pow(($BsRGB+0.055)/1.055, 2.4);

	$RsRGB2 = $r2/255;
	$GsRGB2 = $g2/255;
	$BsRGB2 = $b2/255;
	$R2 = ($RsRGB2 <= 0.03928) ? $RsRGB2/12.92 : pow(($RsRGB2+0.055)/1.055, 2.4);
	$G2 = ($GsRGB2 <= 0.03928) ? $GsRGB2/12.92 : pow(($GsRGB2+0.055)/1.055, 2.4);
	$B2 = ($BsRGB2 <= 0.03928) ? $BsRGB2/12.92 : pow(($BsRGB2+0.055)/1.055, 2.4);

	if ($r+$g+$b <= $r2+$g2+$b2) {
	$l2 = (.2126 * $R + 0.7152 * $G + 0.0722 * $B);
	$l1 = (.2126 * $R2 + 0.7152 * $G2 + 0.0722 * $B2);
	} else {
	$l1 = (.2126 * $R + 0.7152 * $G + 0.0722 * $B);
	$l2 = (.2126 * $R2 + 0.7152 * $G2 + 0.0722 * $B2);
	}
	$luminosity = round(($l1 + 0.05)/($l2 + 0.05),2);
	return $luminosity;
}
</code>
</code></pre>
<p>So, yes, I am actually applying that adjustment. The information posted in the article is just the definition of the ratio, not the actual formula used to derive the ratio&thinsp;&#8212;&thinsp;it&#8217;s simplified. I certainly won&#8217;t claim that there can&#8217;t be a bug in that function - and if you see one, by all means let me know!</p>
<p>Can you give me an example of the difference you&#8217;re&nbsp;getting?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Christophe Strobbe</title>
		<link>http://www.joedolson.com/articles/2008/05/testing-color-contrast/#comment-27625</link>
		<dc:creator>Christophe Strobbe</dc:creator>
		<pubDate>Wed, 01 Oct 2008 10:07:28 +0000</pubDate>
		<guid isPermaLink="false">http://www.joedolson.com/articles/?p=242#comment-27625</guid>
		<description>My own calculations of colour contrast with the relative luminance formula from WCAG 2 generate slightly different results from what I get with the colour spectrum tester. In the last section of your article (“Color Comparison Formulas”) you list the formulas you use, but the section on the WCAG 2 formula does not mention how R, G and B are defined. WCAG 2's relative luminance definition also says: “if RsRGB &#60;= 0.03928 then R = RsRGB/12.92 else R = ((RsRGB+0.055)/1.055) ^ 2.4”. You don't mention this. Does that mean that you don't use this in your tool?</description>
		<content:encoded><![CDATA[<p>My own calculations of colour contrast with the relative luminance formula from <acronym title="Web Content Accessibility Guidelines">WCAG</acronym> 2 generate slightly different results from what I get with the colour spectrum tester. In the last section of your article (“Color Comparison Formulas”) you list the formulas you use, but the section on the <acronym title="Web Content Accessibility Guidelines">WCAG</acronym> 2 formula does not mention how R, G and B are defined. <acronym title="Web Content Accessibility Guidelines">WCAG</acronym> 2&#8217;s relative luminance definition also says: “if RsRGB &lt;= 0.03928 then R = RsRGB/12.92 else R = ((RsRGB+0.055)/1.055) ^ 2.4”. You don&#8217;t mention this. Does that mean that you don&#8217;t use this in your&nbsp;tool?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joe Dolson</title>
		<link>http://www.joedolson.com/articles/2008/05/testing-color-contrast/#comment-26395</link>
		<dc:creator>Joe Dolson</dc:creator>
		<pubDate>Mon, 18 Aug 2008 20:54:44 +0000</pubDate>
		<guid isPermaLink="false">http://www.joedolson.com/articles/?p=242#comment-26395</guid>
		<description>Thanks! Glad it helped you out, Gustavo.</description>
		<content:encoded><![CDATA[<p>Thanks! Glad it helped you out,&nbsp;Gustavo.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gustavo Fischer</title>
		<link>http://www.joedolson.com/articles/2008/05/testing-color-contrast/#comment-26385</link>
		<dc:creator>Gustavo Fischer</dc:creator>
		<pubDate>Mon, 18 Aug 2008 13:19:09 +0000</pubDate>
		<guid isPermaLink="false">http://www.joedolson.com/articles/?p=242#comment-26385</guid>
		<description>Thank you, the Color Contrast Spectrum Tester was exactly the tool I was looking for.</description>
		<content:encoded><![CDATA[<p>Thank you, the Color Contrast Spectrum Tester was exactly the tool I was looking&nbsp;for.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
