Düzenle

Aracılığıyla paylaş


DropShadowBitmapEffect.Opacity Property

Definition

Note: This API is now obsolete. The non-obsolete alternative is DropShadowEffect. Gets or sets the degree of opacity of the shadow.

public:
 property double Opacity { double get(); void set(double value); };
public double Opacity { get; set; }
member this.Opacity : double with get, set
Public Property Opacity As Double

Property Value

The degree of opacity. The valid range of values is from 0 through 1. A value of 0 indicates that the shadow is completely transparent, and a value of 1 indicates that the shadow is completely opaque. A value of 0.5 indicates the shadow is 50 percent opaque, a value of 0.725 indicates the shadow is 72.5 percent opaque, and so on. Values less than 0 are treated as 0, while values greater than 1 are treated as 1. The default is 1.

Remarks

This property must be used to set the opacity of the DropShadowBitmapEffect because the alpha level component of the DropShadowBitmapEffect.Color property is ignored.

The following illustration demonstrates the effect of this property.

Screenshot with callouts: DropShadowBitmapEffect

Dependency Property Information

Identifier field OpacityProperty
Metadata properties set to true None

Applies to