Home/ Reference/ Effects

shape.CreateDropShadow(Type, Opacity, Feather, OffsetX, OffsetY, Color)

Adds a drop shadow. Arguments: type (0 flat), opacity 0-100, feather 0-100, x offset, y offset, color. The most valuable effect in layout work.

Signature

shape.CreateDropShadow(Type, Opacity, Feather, OffsetX, OffsetY, Color)

Notes

Adds a drop shadow. Arguments: type (0 flat), opacity 0-100, feather 0-100, x offset, y offset, color. The most valuable effect in layout work.

Python example (runnable)

Requires pywin32. The example assumes app / doc / page / layer are already connected. See Connection & Init
Python
shape = app.ActiveSelectionRange(1)

eff = shape.CreateDropShadow(
    0,                                              # Type 0 = flat projection
    50,                                             # Opacity 50%
    15,                                             # Feather 15
    0.05,                                           # OffsetX, in document units
    -0.05,                                          # OffsetY; negative moves it down
    app.CreateRGBColor(0, 0, 0))                    # shadow colour

print("Drop shadow added, effect type: ", eff.Type)

About this section: Effects

Effects — drop shadow, blend, contour, extrude and lens.

Other entries in this section