Macaw icon indicating copy to clipboard operation
Macaw copied to clipboard

Color Gradient a node

Open TheBearF8 opened this issue 4 years ago • 1 comments

Found your package from the Medium article "Interactive SVG images in Swift with Macaw" I have a SVG with many paths each with their own id I can change the color of the path with node.nodeBy(tag: ) .fill But is there a way to color gradient fill the path?

Thanks

TheBearF8 avatar Jan 06 '21 13:01 TheBearF8

Hi Barry,

Yes, you can set up gradient using shape.fill = LinearGradient(...). There is more information about gradient: https://github.com/exyte/Macaw/wiki/Getting-started#coloring

ystrot avatar Jan 09 '21 08:01 ystrot