UIColor.FromRGBA 方法

定义

重载

FromRGBA(nfloat, nfloat, nfloat, nfloat)

使用指定的红色、绿色和蓝色分量创建具有指定 alpha 透明度的颜色。

FromRGBA(Byte, Byte, Byte, Byte)

使用指定的红色、绿色和蓝色分量创建具有指定 alpha 透明度的颜色。

FromRGBA(Int32, Int32, Int32, Int32)

使用指定的透明度从红色、绿色和蓝色元素的指定组合创建颜色。

FromRGBA(nfloat, nfloat, nfloat, nfloat)

使用指定的红色、绿色和蓝色分量创建具有指定 alpha 透明度的颜色。

[Foundation.Export("colorWithRed:green:blue:alpha:")]
public static UIKit.UIColor FromRGBA (nfloat red, nfloat green, nfloat blue, nfloat alpha);
static member FromRGBA : nfloat * nfloat * nfloat * nfloat -> UIKit.UIColor

参数

red
nfloat

红色分量,0.0 到 1.0f。

green
nfloat

绿色组件 0.0 到 1.0f。

blue
nfloat

蓝色分量值 0.0 到 1.0f。

alpha
nfloat

Alpha (透明度) 值从 0.0 到 1.0f。

返回

属性

注解

这可以从后台线程使用。

适用于

FromRGBA(Byte, Byte, Byte, Byte)

使用指定的红色、绿色和蓝色分量创建具有指定 alpha 透明度的颜色。

public static UIKit.UIColor FromRGBA (byte red, byte green, byte blue, byte alpha);
static member FromRGBA : byte * byte * byte * byte -> UIKit.UIColor

参数

red
Byte

红色分量,0 到 255。

green
Byte

绿色组件 0 到 255。

blue
Byte

蓝色分量值 0 到 255。

alpha
Byte

Alpha (透明度) 值 0 到 255。

返回

注解

这可以从后台线程使用。

适用于

FromRGBA(Int32, Int32, Int32, Int32)

使用指定的透明度从红色、绿色和蓝色元素的指定组合创建颜色。

public static UIKit.UIColor FromRGBA (int red, int green, int blue, int alpha);
static member FromRGBA : int * int * int * int -> UIKit.UIColor

参数

red
Int32
green
Int32
blue
Int32
alpha
Int32

返回

注解

这可以从后台线程使用。

适用于