Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Gradient along a curve in SVG

714 views
Skip to first unread message

Tom

unread,
Apr 13, 2007, 9:54:46 AM4/13/07
to
I'm trying to produce a color gradient along a path in SVG. I'm using
a curved path, and then linking to a linear gradient defined elsewhere
in the svg for the stroke.

The problem is the gradient is over the curve's bouding box, rather
than being along the path of the curve. Is there any way to create a
gradient that follows along the vector of the curve rather than its
bounding box?

I'm hoping that since you can make text flow along a curve it should
be possible to do the same with a gradient?

I'm not sure if this is the best place to post this but it was the
only SVG newsgroup I could find.

Jonathan Watt

unread,
Apr 13, 2007, 12:36:00 PM4/13/07
to
Tom wrote:
> I'm trying to produce a color gradient along a path in SVG. I'm using
> a curved path, and then linking to a linear gradient defined elsewhere
> in the svg for the stroke.
>
> The problem is the gradient is over the curve's bouding box, rather
> than being along the path of the curve. Is there any way to create a
> gradient that follows along the vector of the curve rather than its
> bounding box?
>
> I'm hoping that since you can make text flow along a curve it should
> be possible to do the same with a gradient?

I'm afraid it's not. The SVG specification does not provide for such gradients.

> I'm not sure if this is the best place to post this but it was the
> only SVG newsgroup I could find.

You may want to make a feature request to the W3C SVG mailing list at
www...@w3.org.

-Jonathan

0 new messages