Re: advice on alt text for image maps

2013-12-24 19:26, Steve Faulkner wrote:
> I have made some modifications to the example:
>
> http://www.w3.org/html/wg/drafts/html/master/embedded-content-0.html#image-maps-0

It's much better now, with a realistic example of a situation where one 
would meaningfully use a client side image map (a real map, though with 
two active areas only, for simplicity).

There's no general guideline for writing the alt attribute, though. Just 
saying "always provide a text alternative for the image" does not give 
guidance on what the alternative should be. And I'm not convinced of the 
adequacy of the example text either.

The content in the example would read as something like the following in 
a presentation that does use images (I'm denoting spacing or pauses 
between paragraphs with isolated hyphens "-" here):

"View houses for sale in North Katoomba or South Katoomba - Map of 
Katoomba (link) Houses in North Katoomba (link) Houses in South Katoomba"

How does the text "Map of Katoomba" help here? I would say that it is 
just disturbing. It does not help to know that there is a map that you 
do not see. In this case, alt="" would seem to be the appropriate attribute.

Looking now at an earlier suggestion of mine, I realize it was partly in 
error:

> If an img element has a usemap attribute and is thus associated with 
> an image map, the alt attribute value describes the image as a whole 
> in the context. This means that it acts as a caption for the 
> collection of the alt attributes of the area elements, so that all 
> these attributes together can be used as a captioned menu of choices, 
> in a situation where the image is not seen.

The word "description" is bad here. There is normally no point in 
describing a map to someone who does not see and who has an alternative 
presentation to use, namely something that is effectively a list of 
links (corresponding to areas in the map, but you don't usually need to 
know that).

So let me rephrase it:

If an img element has a usemap attribute and is thus associated with an 
image map, the alt attribute value should normally be empty. The reason 
is that the alt attributes of the area elements, together with adequate 
content before the img element, work as a suitable user interface when 
the image is not displayed.

[the example could go here]

However, sometimes the img element might not be preceded by content that 
fully indicates what kind of a choice is expected from the user. This 
could happen if the image is expected to be at least self-explanatory in 
that respect. In that case, the alt attribute of the img element should 
contain text that tells what the sequence of links to follow means and 
how it is to be used.

For example, if the image represents a map of Europe, with countries as 
active areas, and the image is preceded just by generic text like 
"Please select a country:", then the alt text should say e.g. alt="(The 
menu consists of the countries of Europe)". The reason is that although 
this European context is usually obvious when the image is seen, it need 
not be obvious at all to someone who only sees or hears a longish list 
of country names.

-- 
Yucca, http://www.cs.tut.fi/~jkorpela/

Received on Thursday, 26 December 2013 21:35:20 UTC