Re: feedback requested on WAI CG Consensus Resolutions on Text alternatives in HTML 5 document

On Aug 17, 2009, at 2:40 AM, Benjamin Hawkes-Lewis wrote:

> On 17/08/2009 10:05, Maciej Stachowiak wrote:
>>> In situations like:
>>>
>>> <a href="#"><img src="delete.png" alt=""></a>
>>>
>>> It's useful to AT for the "img" to be exposed and to be able to  
>>> access
>>> "src" attributes for the purpose of providing a substitute for  
>>> proper
>>> alternative text.
>>
>> If that's so, then wouldn't it be better for authors to use alt=""
>> instead of role="presentation", so that AT can decide whether it  
>> needs
>> to expose the image anyway?
>
> I don't think role="presentation" is appropriate in that case. It's  
> not a presentational image.

I don't think alt="" is appropriate either, for the same reason. But  
you are right that such usage is common nonetheless.

>> In particular, if your example was marked up
>> like this:
>>
>> <a href="#"><img src="delete.png" role="presentation"></a>
>>
>> Then isn't it equally necessary and appropriate for AT to expose that
>> image?
>
> I think it's important that W3C specs do not produce a situation  
> where "role='presentation'" is likely to be widely misused in that  
> way.

The specific proposal on the table was as follows:

- Every time the validator sees alt="" without role="presentation", it  
should issue a warning advising the author to add role="presentation".

I believe this would lead to the kind of misuse that you are concerned  
about. Do you think this kind of warning is a good idea?

> I don't think authors should add "role='presentation'" in such cases  
> (they should write "alt" text for the control), or that authoring  
> tools should add "role='presentation'" if authors fail to write  
> "alt" text for controls, or that checkers should suggest  
> "role='presentation'" for images that are the only content for  
> controls (they should suggest supplying "alt" text).
>
> There may well be a case for assuming authors will get this wrong,  
> and saying that UAs should ignore "role='presentation'" for the  
> purpose of calculating control text, but that should be fixed at the  
> ARIA spec layer, as it's not a problem specific to HTML.



>
>>> http://www.w3.org/TR/WAI-USERAGENT/guidelines.html#tech-missing-alt
>>>
>>> More tendentiously, perhaps, in situations like:
>>>
>>> <p>As you can see from the chart below, sales increased in 2008:</p>
>>> <img alt="" src="chart.png">
>>>
>>> Even if users can't consume the chart themselves, it's useful to  
>>> users
>>> to be able to download or hotlink that referenced chart in a
>>> collaborative environment (e.g. a corporate wiki).
>>>
>>> By contrast:
>>>
>>> <img alt="" src="bullet.png">
>>>
>>> really is purely decorative; in a collaborative environment that  
>>> seems
>>> likely to be generated by authoring software.
>>
>> And likewise for these examples - it seems like AT should be left  
>> free
>> to apply heuristics.
>
> In the first case, I don't think "role='presentation'" should be  
> added (it a data chart not a presentational image); in the second  
> case I think it should (it's a bullet).
>
> Assuming correct use of the marker (I know, big assumption), the  
> advantage for AT is being able to /totally/ ignore the second  
> (purely decorative) image, while still providing some sort of access  
> to the first. Isn't that an improvement on heuristics?

That depends on whether role="presentation" is likely to be used more  
correctly than alt="". I think just the existence of  
role="presentation" is not necessarily problematic, if alt="" is still  
allowed. After all, empty alt is shorter, so only thoughtful authors  
will go for the wordier option. But if the validator warns about empty  
alt and suggests adding role="presentation", then it seems like it  
would start to get used wrong with similar frequency to alt="".

>
> Furniture photo for a news article about sidewalk disrepair:
>
> <img alt="" src="walking-man.jpg" role="presentation">
>
> Tangentially, I would prefer a way to demark decorative media that  
> was native to HTML, and that was mapped to but did not rely on the  
> ARIA layer, so that all UAs could make use of it. For example, "User  
> Style"-type views in Firefox and Opera, the mobile layout view in  
> Opera Mini and so on could omit images, videos, and audio marked as  
> decorative. The current ARIA draft seems to block this sort of use:
>
> http://www.w3.org/TR/wai-aria/#ua_noninterference (public)
>
> http://www.w3.org/WAI/PF/aria/#ua_noninterference (editor's)
>
> e.g. <img alt="" src="walking-man.jpg" presentational>
>
>     <object data="walking-man.jpg" presentational>
>
>     <video presentational>
>
>     <audio presentational>
>
> (Yes, this might involve specifying error handling at the HTML layer  
> too. :( )
>
> --
> Benjamin Hawkes-Lewis
>

Received on Monday, 17 August 2009 09:57:01 UTC