Re: Is there a formula for converting a linear gradient to a box-shadow?

Hi François (is it pronounced frans-va? :))

This is the kind of thing I want to use the drop shadow for:
https://docs.google.com/file/d/0ByWstmU-AS9GdlZVTjdyemFQRGM/edit

I have this page-wide nav-bar that should drop a shadow over everything
underneath it. As far as I can see, this can't be done elegantly with
linear-gradients, although I think it might be possible with an :after
element.

Cheers,
Behrang Saeedzadeh
http://www.behrang.org


On Thu, Jan 31, 2013 at 10:02 AM, François REMY <
francois.remy.dev@outlook.com> wrote:

>  Using box-shadows to render a linear gradient is not a very good idea
> from a performance point of view. I’ve no code to share with you but an
> advice to avoid doing this. What’s your use case?
>
>
>
>
>  *De :* Behrang Saeedzadeh
> *Envoyé :* 30 janvier 2013 23:55
> *À :* W3C CSS Mailing List
> *Objet :* Is there a formula for converting a linear gradient to a
> box-shadow?
>
> Hi,
>
> I want to define a box-shadow that renders something identical to a linear
> gradient. But box-shadow and linear gradient have different parameters.
>
> The question is, is there a formula for converting a linear gradient to a
> box shadow?
>
> Cheers,
> Behrang Saeedzadeh
> http://www.behrang.org
>

Received on Wednesday, 30 January 2013 23:13:26 UTC