![]() |
![]() |
EffectDropShadow.OffsetX
Property OffsetX As Double
Member of EffectDropShadow
The OffsetX property returns or sets the horizontal offset of a flat drop shadow.
See also the SetOffset method.
The following code example moves all flat drop shadows so that the offset distance is 0.5 inch while preserving the original offset angle.
Sub Test() Const Radius As Double = 0.5 Dim s As Shape, ds As EffectDropShadow Dim dx As Double, dy As Double, r As Double For Each s In ActivePage.Shapes If s.Type = cdrDropShadowGroupShape Then Set ds = s.Effect.DropShadow If ds.Type = cdrDropShadowFlat Then dx = ds.OffsetX dy = ds.OffsetY r = Sqr(dx * dx + dy * dy) If r = 0 Then dx = 1 r = 1 End If ds.OffsetX = dx * Radius / r ds.OffsetY = dy * Radius / r End If End If Next s End Sub
![]() |
![]() |
![]() |
Copyright 2007 Corel Corporation. All rights reserved.