语言

ImageAttributes.ClearColorKey 方法

定义

清除颜色键(透明度范围)。

重载

名称 说明
ClearColorKey()

清除默认类别的颜色键(透明度范围)。

ClearColorKey(ColorAdjustType)

清除指定类别的颜色键(透明度范围)。

ClearColorKey()

Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs

清除默认类别的颜色键(透明度范围)。

public:
 void ClearColorKey();
public void ClearColorKey();
member this.ClearColorKey : unit -> unit
Public Sub ClearColorKey ()

注解

对象维护五个 ImageAttributes 调整类别的颜色和灰度设置:默认、位图、画笔、笔和文本。 例如,可以为默认类别指定一个颜色键、位图类别的不同颜色键,以及笔类别的颜色键不同。

默认颜色调整和灰度调整设置适用于没有自己调整设置的所有类别。 例如,如果从未为笔类别指定任何调整设置,则默认设置将应用于笔类别。

适用于

ClearColorKey(ColorAdjustType)

Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs
Source:
ImageAttributes.cs

清除指定类别的颜色键(透明度范围)。

public:
 void ClearColorKey(System::Drawing::Imaging::ColorAdjustType type);
public void ClearColorKey(System.Drawing.Imaging.ColorAdjustType type);
member this.ClearColorKey : System.Drawing.Imaging.ColorAdjustType -> unit
Public Sub ClearColorKey (type As ColorAdjustType)

参数

type
ColorAdjustType

该元素 ColorAdjustType 指定颜色键被清除的类别。

注解

对象维护五个 ImageAttributes 调整类别的颜色和灰度设置:默认、位图、画笔、笔和文本。 例如,可以为默认类别指定一个颜色键、位图类别的不同颜色键,以及笔类别的颜色键不同。

默认颜色调整和灰度调整设置适用于没有自己调整设置的所有类别。 例如,如果从未为笔类别指定任何调整设置,则默认设置将应用于笔类别。

指定特定类别的颜色调整或灰度调整设置后,默认调整设置将不再应用于该类别。 例如,假设你指定一个默认颜色键,该键使任何颜色的红色分量从 200 到 255 透明,并指定默认伽玛值 1.8。 如果通过调用 SetColorKey 方法设置笔类别的颜色键,则默认颜色键和默认伽玛值将不适用于笔。 如果稍后通过调用 ClearColorKey 方法清除笔颜色键,笔类别将不会还原为默认颜色键;相反,笔类别将没有颜色键。 同样,笔类别不会还原为默认伽马值;相反,笔类别将没有伽玛值。

适用于