W3C home > Mailing lists > Public > w3c-wai-ig@w3.org > July to September 2014

Re: measuring contrast ratio and Windows Clear Type

From: Greg Kraus <greg_kraus@ncsu.edu>
Date: Mon, 11 Aug 2014 08:11:24 -0400
Message-ID: <CAJL_eQA7qJvCPFS50ReTfu-iBV3PBUCQTmufx_8Z4taP8x=p1Q@mail.gmail.com>
To: w3c-wai-ig@w3.org
I developed a tool to deal with issues like this. It's a Chrome
extension called Color Contrast Analyzer.

https://chrome.google.com/webstore/detail/color-contrast-analyzer/dagdlcijhfbmgkjokkjicnnfimlebcll?hl=en

It takes a screen shot and compares a pixel with every pixel around
it. You can set how wide of a radius you want to search around each
pixel in order to deal with issues like anti-aliasing. The resulting
image shows each pixel that has an adjacent pixel with enough contrast
with the original pixel. In the end, the tool creates outlines in the
page of what I call "contrast borders" that show where the contrast
exceeds the given WCAG conformance level.

It lets you choose between AA and AAA, and also for standard sized
text or medium-bold/larger text. The tool does require you to know
what size text you are analyzing because it is simply doing pixel
analysis. It has no idea what it is actually analyzing.

Another result of this is it will analyze contrast in images too.
While contrast in images is not a WCAG requirement, it comes in handy
when you need to analyze text in a picture, which is a WCAG
requirement.

Greg
--
Greg Kraus
University IT Accessibility Coordinator
NC State University
919.513.4087
gdkraus@ncsu.edu

On Mon, Aug 11, 2014 at 6:24 AM, Marc Haunschild <mh@zadi.de> wrote:
> Hi Jan,
>
> I can just describe my practice: when I measure contrast with cca I try to
> find a quite dark pixel (on light background) - normally this has less
> contrast than the colors defined in the CSS.
>
> If the contrast is not high enough, I recommend to change the colors.
>
> Of course this is not for official testing (like in BITV-Test), but for real
> life accessibility I think it is a good compromise.
>
> Reasons: On the one hand a user is able to change the Clear Type value
> himself or to use a bigger font, on the other hand the author of the web
> site improves the accessbility a little bit more than WCAG aks him to do.
>
> To me accessibilty is a matter of fairness and to me it seems to be fair,
> the way I measure contrast. So I do it this way. ;-)
>
> Marc
>
>
> Am 11.08.14 12:05, schrieb Joe Chidzik:
>
>> Whenever I've used the CCA with IE, fonts appear anti-aliased, meaning it
>> is not clear which pixel to pick for the actual text colour. Firefox does
>> not exhibit this problem for me, and so I've always used Firefox when
>> measuring contrast with the CCA just to be sure I'm selecting the colours
>> specified by the CSS.
>>
>> I don't know if it's possible to detect (via CSS\JavaScript) if a user has
>> clear type enabled or not, but in my view, measuring the contrast via the
>> values provided in the CSS should be all that it is required to check
>> adherence to the success criteria.
>>
>> Joe
>>
>>
>>> -----Original Message-----
>>> From: Jan Eric Hellbusch [mailto:hellbusch@2bweb.de]
>>> Sent: 11 August 2014 10:45
>>> To: w3c-wai-ig@w3.org
>>> Subject: measuring contrast ratio and Windows Clear Type
>>>
>>> Hi,
>>>
>>> I was giving a seminar the other day on Web accessibility testing and was
>>> asked
>>> by one of the participants how I measure contrast when clear type is
>>> activated. I
>>> was caught by surprise, because I had switched it off when setting my
>>> Windows 7
>>> laptop up a couple of years ago and I never gave it a second thought.
>>> Since then I
>>> have been measuring contrast ratios with clear type switched off.
>>>
>>> I have been trying to find more detailed information on the precise
>>> differences in
>>> measuring contrast ratios with and without clear type on Windows, but I
>>> obviously
>>> have the wrong search terms. Perhaps someone on this list can point me
>>> out in
>>> the right direction?
>>>
>>> * Using CCA there is the possibility of grabing several pixels at a time.
>>> Does that solve the problem of measuring a correct contrast ratio?
>>> * Or do I have to switch clear type off or  (in Firefox) set
>>> gfx.content.azure.enabled
>>> to false?
>>>
>>> I would greatly appreciate a hint or a resource.
>>>
>>> Thanks,
>>> Jan
>>>
>>> --
>>> Jan Eric Hellbusch
>>> Tel.: +49 (231) 33005825 oder +49 (163) 3369925
>>> Accessibility-Beratung: http://2bweb.de
>>> Blog: www.chemnitzer-14.de
>>> Bücher, Artikel: www.barrierefreies-webdesign.de
>>>
>>>
>>>
>>
>>
>
>
>
> --
> Mit freundlichen Grüßen,
>
> i. A. Marc Haunschild
> Zugängliche Anwendungsentwicklung und Qualitätskontrolle
> ________________________________________
> Referat 414 / Abteilung 4
> Bundesanstalt für Landwirtschaft und Ernährung
> Deichmanns Aue 29, 53179 Bonn
> Telefon: +49 (0)228 996845-7324
> Fax: +49 (0)228 6845-3101
> E-Mail: marc.haunschild@ble.de
> Internet: www.ble.de ( http://www.ble.de/ )
>
Received on Monday, 11 August 2014 12:11:48 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 13 October 2015 16:21:52 UTC