Legend
October 11, 2026
Question
Why can't the fill color and shadow effects be stored in the same variable?
- October 11, 2026
- 0 replies
- 6 views
I always mistakenly believed that appliedObjectStyle included fillColor.
For example, I want to achieve the effect of a pipette drawing a pattern.
There are two objects, A and B. I want to quickly copy the fillColor, stroke, and shadow of A to B, but I noticed that they overlap each other.
How to prevent the color filling and effects from overlapping?
var d = app.activeDocument;
var item = d.selection[0];
var sel = d.selection;
sel[1].fillColor = sel[0].fillColor;
sel[1].appliedObjectStyle = sel[0].appliedObjectStyle;This sentence doesn't seem to work either.
sel[1].appliedObjectStyle = sel[0].appliedObjectStyle;
