Stroke fill color changes stroke path
Summary:
I wished to have a drop shadow on text, separated from the text by a gap. To achieve this, I gave the text a stroke with a width equal to the gap I wanted. I want the background image to appear in the gap between the character outline, and the drop shadow effect. It seems the simplest, natural way to do this - setting 'no color' for the stroke's fill, or 100% transparency for the stroke's fill, instead reduces the outline of the stroke.
Steps to reproduce:
- open Inkscape
- Import an image
- Over the image, add some text with a large size, like 96 point
- Fill the text with some color
- Give the text a stroke with an easily visible width, e.g. 5% of the font size
- Try to make the stroke fill color so that the background shows through.
- The best method I can find is to define a complex blend across the text with many stop colors that sample the background image so that the blend makes the stroke hard to distinguish from the background image
- Apply a drop shadow effect(e.g. white), with a similar radius as the size of the stroke width.
What happened?
- Try to make the stroke outline remain, to achieve the gap between the text and its drop shadow, but have the stroke become 'see through'.
- If you try to make the gap between the text fill and the drop shadow invisible by setting the stroke's fill color to Undefined, the stroke width instead drops to zero and the drop shadow's position changes, so it abuts the text characters
- If you try to use transparency to make the background visible through the stroke, the width of the stroke reduces in proportion to the transparency, until at 100% transparency the stroke width appears to be zero.
I suppose it's possible that Inkscape ignores the stroke when applying the drop shadow, but that seems counter-intuitive.
I can well believe though that I'm trying to achieve the effect the wrong way; what I'm doing seems straightforward and intuitive to me, but then I suppose it would! :-)
What should have happened?
- The outline of the stroke should not have changed, and the drop shadow effect should apply to the stroked text outline. Instead, the stroke is effectively removed, and the gap between the text and its drop shadow disappears!
Sample attachments:
Inkscape 1.1.1 (3bf5ae0d25, 2021-09-20)