Previous Message
Next Message

Positioned ALT Captions

Sent by The Moose on 29 November 2003 21:09


IAN:
> Just as a note, the correct attribute to use for image captions is the
> "title" attribute. The "alt" attribute is meant for an alternative
> rendering of the image in case images are unavailable.

Yes. My ALT serves exactly as alternative text, i.e. I have not abused it.

> For example,
>
>    <img src="../../image/photos/n-tiny.jpg" width="300" height="131"
>         title="Nevcyrsk&aacute; Valley"
>         alt="Jagged mountains framing a valley are obscured by heavy 
> fog.">
>
> (Note that it is not a description -- there is no reference to the fact
> that it is a photo -- it just conveys the same meaning as the photo, but
> in textual form.)

We have three ways to add a description to the image without resorting to 
adding text outside the image:
1. ALT
2. TITLE
3. LONGDESC

Ad 1. I have browsed my own site once with images off, and noticed that 
only that portion of ALT text is displayed which fits into the dimensions 
of the image placeholder. That means ALT must be short. In the technique I 
presented, ALT is a two-word sequence. It says exactly what is on the 
image in a succinct way. This is exactly why I used generated content to 
extract it and position it over the image. Usability and space constraint.

Ad 2. A title is a relatively short description of the image. What you 
propose above as a 10-word ALT text would fit better into a title. I could 
have left ALT as it is (Nevcyrska' Valley), and added "Jagged mountains 
framing a valley are obscured by heavy fog." as a title, and the extract 
it via generated content. This would never fit into a succinct caption to 
be positioned over the image, although it would be good enough for a 
title. I could have used: "Nevcyrska Valley" as a title, but then I would 
have foregone the descriptive possibilities of TITLE attribute.

Ad 3. A long description is the best place for a comprehensive 
description. I am not aware of support for longdesc. Once I went around 
this in my own moosely way [1] because I am fond of Pareto improvements - 
if I can't better a situation for everyone, I will settle for an 
improvement for a strict subset of the audience. Longdesc is not fit for a 
caption that is displayed concurrently with the image content.

In summary, although a title would be best theoretically for a caption, in 
the particular application I tackled, ALT is best suited for a two-word 
caption that wouldn't destroy the readability of the text and the beauty 
of images. Please note that the markup only contains a proper ALT.

CSS generated content adds functionality that doesn't mess with the markup.

Wojtek


[1] 
http://www.literarymoose.info/=/article/conquistadors3.html#long-description

-- 
-------------------------
Book Quote of the Day: "To some it is lonely and impossible not to be in 
"the right circles," and they scramble and crawl over each other in order 
to be included; humiliate themselves and lose their souls somewhere on the 
way toward a goal that does not exist. " ~ LIV ULLMANN

______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Previous Message
Next Message

Message thread: