public static Icon Combine(
this Icon icon,
Bitmap? image,
Color transparentColor
)<ExtensionAttribute>
Public Shared Function Combine (
icon As Icon,
image As Bitmap,
transparentColor As Color
) As Iconpublic:
[ExtensionAttribute]
static Icon^ Combine(
Icon^ icon,
Bitmap^ image,
Color transparentColor
)[<ExtensionAttribute>]
static member Combine :
icon : Icon *
image : Bitmap *
transparentColor : Color -> Icon Both icon and image may contain multiple icons.
This overload attempts to preserve the actual pixel format of the specified image, and just applies a transparency mask for the specified color. To allow reducing the color depth losslessly, use the Combine(Icon, Bitmap) overload instead.
If transparentColor is an opaque color and image already has transparent pixels, then both the originally transparent pixels, and the ones that equal to transparentColor will be transparent in the result.
The result Icon is compatible with Windows XP if the method is executed in a Windows XP environment.