Re: shrink-wrap

On Wed, 5 Apr 2000 15:39:39 -0400, "Joe Hewitt" <joe@joehewitt.com>
wrote:

>Perhaps I should have clarified that the lack of an ability
>to "shrink-wrap" is a problem only on elements with
>"position: absolute".

Aha, that sheds a different light on the problem :)

[...]

>Here is a very common application...
>...tool-tip...
>Obviously, the designer would not know the exact
>dimensions of this box at design-time; it would be
>dependent on the size of the caption text.

If it's really a requirement to avoid line wrapping on that caption, we
are out of luck here.

>Currently, it is impossible to achieve the desired effect within the
>constraints of the CSS2 box model.  If the designer set width and height to
>"auto", the tool-tip's dimensions would extend to the edges of  the
>containing block, which is obviously not going to result in the desired
>dimensions.

There's more than that to be taken into consideration here.

Creating "tool-tips" through CSS might look attractive at first, but
using this method for a tool-tip may also at times require that one must
specify  ALT="" (for IMG's) and  TITLE="" in the markup of the element
that the CSS tool-tip is set up for.

IE4/5 renders it's own tool-tips (for any element I think) if there's a
TITLE attribute set for it. For IMG's it does the same, or renders the
ALT attribute content as tool-tip if there's no TITLE attribute given.

NS4x renders tool-tips from ALT attributes on IMG's and does not care
about the TITLE at all. (against the HTML specs of course :)

So there's a possibility to end up with two "tool-tips" in some
situations, because stating  ALT="" for an IMG that is informative in
its nature, defeats that IMG's information content in browsing
situations where IMG's can not be rendered.

So even if I think that just this "CSS tool-tip" idea was interesting,
maybe we need to move ahead one step and ask for some CSS possibilities
to style the tool-tip rendering, that is suggested to come out of the
TITLE attribute value, instead?

>Any thoughts?

Not on 'absolute position' sorry to say. I don't use it my self since it
does not "fit" into my personal design habits. There's only a less than
handful browsers that manages CSS1 at a close to correct level today,
and I want things that "works" on a little bit wider spectrum than just
Mozilla. (but it's a damned good rendering agent though already now :)

-- 
Jan Roland Eriksson <jrexon@newsguy.com>
<URL:http://member.newsguy.com/%7Ejrexon/>

Received on Thursday, 6 April 2000 15:39:39 UTC