Udostępnij za pośrednictwem


ColorExtensions.WithAlpha(Color, Int32) Method

Definition

Creates a new color based on this color, but with a new alpha (0-255).

public static System.Drawing.Color WithAlpha (this System.Drawing.Color color, int alpha);

Parameters

color
System.Drawing.Color

The color to use as a base.

alpha
System.Int32

The alpha to set 0-255.

Returns

System.Drawing.Color

The new color.

Applies to