That's an interesting point James - I missed that the first time by.

One minor point I would clarify: Alexey, you stated that <label for="XX"
type="title"> would replace the "title" attribute.  I assume you meant that
it should *supplement* it, since you wouldn't want to preclude its use or
mess with backward compatibility.

It sounds like <label for="XX" type="title"> would be a *terrific* addition
to HTML5, along with a new value for the "display" property, "tooltip".
(I'm thinking of all the JS that I wouldn't have to write anymore! :-)


On 11/22/06, Alexey Feldgendler <[EMAIL PROTECTED]> wrote:

On Wed, 22 Nov 2006 21:32:35 +0600, James Graham <[EMAIL PROTECTED]> wrote:

> In general I think that having <img> and <imgcaption> (or whatever they
> are called) enclosed by a single element is a better idea since the
> increased simplicity makes rendering easier. For example, how would you
> expect a browser to render this?:
>
> <p>Foo
> <img id="bar">
> <p>Foobar
> <p>Baz
> <imgcaption for="bar">Pictures are nice!</imgcaption>
>
> In all current UAs I guess it would render something like:
>
> Foo
> <img>
> Foobar
> Baz
> Pictures are nice

This is exactly how I expect the above markup to be rendered. Unless the
<imgcaption> is taken out of the flow by specifying display:tooltip, it
should show where it's written. In fact, the difference between
<imgcaption> and <div> is no more than between <address> and <div>:
<imgcaption> is technically the same as <div> but conveys semantical
meaning that its content is a title for image #bar.

> But I can't think of many situations where a figure's caption should be
> separate from the figure itself and, from the discussion above, it seems
> that some people would expect:
>
> Foo
> <img>
> Pictures are nice
> Foobar
> Baz

No, I don't expect this. If the author wanted this, he would have written
<imgcaption> right after <img>.

> Another issue to consider is the possibility of multiple images with a
> single caption (this is very common in scientific papers, print
> magazines, etc.). A construct like
> <figure>
> <img>
> <img>
> <img>
> <imgcaption>
> </figure>
> might be enough to support this (the details are, I think, non-trivial);
> something that requires the caption to point to exactly one image
cannot.

I'm thinking of <label type="title"> as of just a fancy replacement for
the "title" attribute. In your example, I would write:

<div id="fig1">
  <img>
  <img>
  <img>
</div>
<label for="fig1" type="title">...</label>

...probably using something more specific than <div> to group the <img>
elements.


--
Alexey Feldgendler <[EMAIL PROTECTED]>
[ICQ: 115226275] http://feldgendler.livejournal.com

Reply via email to