Re: 3D fx on images

----- Original Message -----
From: Nicolas Lesbats <nlesbats@etu.utc.fr>
To: <www-style@w3.org>
Sent: Monday, May 31, 1999 2:41 PM
Subject: 3D fx on images


> I would like to create a dynamic relief effect on an image (you
> know, like the buttons of your browser, or like the menus in Windows).
>
> On a gray-background image :
>
>  * when 'hover', add a white border at the left and top sides, and a black
> border at the bottom and right sides.
>
>  * when 'active', toggle the color of the sides
>
> And why not move slightly the image, as if you push it.
>
> To create the borders, the 'border' property is not a good solution since
> it causes reflow (if I understand good the spec).

Reflow should only happen if you change the border width. Just don't change
the border width; if you don't want the border visible, use a border-style
of "solid" and a border-color of "transparent".

> So 'outline' is a better solution. First problem : outline-left,
> outline-top, etc. don't exist in CSS (why... ?).

Couldn't you still achieve what you want with an outline-style of outset?

> Second problem : would the borders appear in the place where I expect
> them, that's to say ON the image (and not around) ? Could this property
> even be applied to an image ?

Borders appear around things, outlines appear *on* them. Outline should do
what you want.

Braden N. McDaniel
braden@endoframe.com
<URI:http://www.endoframe.com>

Received on Monday, 31 May 1999 17:32:31 UTC