Transparency and drop-shadow
Robert Fisher
rfisher at tesis.de
Fri Mar 28 14:21:40 UTC 2014
Hi everyone,
I'm have some problems mixing transparency and drop-shadow together. Suppose I want to create a transparent white rectangle with a subtle drop-shadow effect. If I create a rectangle with a transparent white fill and a light grey drop-shadow, I get something like in the left picture (with a red rectangle added to show the transparency):
http://i.imgur.com/DSAPckE.png
What I want is something like in the right picture, i.e. the drop-shadow is just around the outside and doesn't colour the entire rectangle grey.
In the right picture I "fixed" things by splitting the rectangle into two rectangles in the same position, one with a null fill and drop-shadow, and one with a transparent white fill and no drop-shadow.
The problem is when I have a large group of shapes and other nodes that I want to apply a single drop-shadow to, this kind of "fix" becomes impossible or at least extremely inelegant.
Is there any nice way to apply a drop-shadow only to the edges of an object?
Thanks in advance,
Rob
More information about the openjfx-dev
mailing list