[html4all] alt Survey/Commets
Leif Halvard Silli
lhs at malform.no
Sat Jan 24 16:24:08 PST 2009
Laura Carlson 2009-01-22 21.22:
> Should alt be required for the img element in HTML5? Why or why not?
> Gez Lemon is doing an alt twitter survey / taking comments for a
> position paper [...]
> Alternatively comment here.
PURPOSE OF @ALT:
* required architecture for caring for non-visual users.
* No @alt = technical invalidity.
* Incorrect @alt content = lacking care for non-visual users.
PURPOSE OF <IMG>
* Purpose is unaffected by @alt, lack of @alt or @alt content.
* Content of @src or @alt reveal - but do not express - purpose.
* Expressing purpose would require extra attribute. E.g. @role.
* "Signficant content" cannot be expressed by (lack of) @alt. Lack
of @alt would at best function as a content repair trigger.
* @alt content unvalidatable for a HTML validator.
* Exception: with @role="decoration", non-empty @alt = checkable.
* HTML 5 should focus on the need for separate WCAG validation.
* Warning: If e.g. role"photography" would make code invalid
unless alt="non-empty", authors could start to fake alt-content.
However, a warning which advices for correct @alt text, and
against fake @alt text, could perhaps work.
@DESCRIBEDBY and ALT TO ALT="CONTENT"?
* @aria-describedby, @longdesc and <figure> permit empty alt.
* When @alt is empty due to e.g @describedby, then it would be
handy if the UA could use the value of the @role attribute when it
talks to the user about what the <IMG> is. Example: For <IMG
role="photography" src="i" alt="" aria-describedby="#ID" >, UA
could talk about <IMG> as "photography" instead of as "the image".
* Content repair = different from display of @alt text.
* Value of @role could be used for content repair when @alt is
lacking *as well as* and when the @alt is empty.
* @role="decorative" = potential for repair of non-empty @alt.
* Even if @role="decorative", the @alt still should be empty.
* no @role + correct @alt = better than incorr. alt + OK @role.
* Minimum solution on photo sites: <img role="photography" alt=""
src="file" >. Valid HTML. Invalid according to WCAG.
* UAs and not semantics = reason for *always* requiring @alt.
LIMITATIONS OF IMG
* WCAG recommends the use of the right element for the task.
<OBJECT> should be recommened for some cases.
Summary: HTML 5 have sofar tried to put more functions into @alt
(lack of @alt included). That only makes it harder to use.
Instead, its purposes should be narrowed down.
Leif Halvard Silli
More information about the List_HTML4all.org