Gradient stops positioning in clipped shape
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Inkscape |
Fix Released
|
Medium
|
Unassigned |
Bug Description
I am using this handcrafted SVG to test:
======
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg version="1.1"
width="100"
height="100"
viewBox="0 0 100 100">
<linearGradient id="grad">
<stop style="
<stop style="
<stop style="
</linearGradient>
<clipPath id="cp">
<path d="M 0,0 50,0 50,50 0,50 z" />
</clipPath>
<rect style="fill: url(#grad);"
width="100"
height="100"
x="0"
y="0"
clip-
</svg>
======
Basically there is a rectangle filled with a gradient that goes from left to right and from red to white to blue. Then I clip it to the left half.
I'd expect to see only the right half transparent, and the left half with a gradient from red to white (no blue). Eog shows it like that.
Inkscape shows the right half transparent (correct), but the gradient in the left part is re-positioned relative to the clipped region, so I see the whole gradient from red to white to blue.
I am not an expert on SVG spec, so it might be as well a problem in the library that eog uses, but eog's behavior seems more natural, so I tried reporting it here first.
I am using inkspace 0.48.5.
Changed in inkscape: | |
status: | Fix Committed → Fix Released |
Attaching pasted SVG source as file to ease testing …