ColorObject.Alpha Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
Alpha() |
Returns the value of the alpha component in the range ([0. |
Alpha(Color) |
Return the alpha component of a color int. |
Alpha(Int64) |
Returns the alpha component encoded in the specified color long. |
Alpha()
Returns the value of the alpha component in the range ([0.
[Android.Runtime.Register("alpha", "()F", "GetAlphaHandler", ApiSince=26)]
public virtual float Alpha ();
[<Android.Runtime.Register("alpha", "()F", "GetAlphaHandler", ApiSince=26)>]
abstract member Alpha : unit -> single
override this.Alpha : unit -> single
Returns
- Attributes
Remarks
Returns the value of the alpha component in the range \([0..1]\). Calling this method is equivalent to getComponent(getComponentCount() - 1)
.
Java documentation for android.graphics.Color.alpha()
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Applies to
Alpha(Color)
Return the alpha component of a color int.
[Android.Runtime.Register("alpha", "(I)I", "")]
public static int Alpha (Android.Graphics.Color color);
[<Android.Runtime.Register("alpha", "(I)I", "")>]
static member Alpha : Android.Graphics.Color -> int
Parameters
- color
- Color
Returns
- Attributes
Remarks
Return the alpha component of a color int. This is the same as saying color >>> 24
Java documentation for android.graphics.Color.alpha(int)
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Applies to
Alpha(Int64)
Returns the alpha component encoded in the specified color long.
[Android.Runtime.Register("alpha", "(J)F", "", ApiSince=26)]
public static float Alpha (long color);
[<Android.Runtime.Register("alpha", "(J)F", "", ApiSince=26)>]
static member Alpha : int64 -> single
Parameters
- color
- Int64
The color long whose alpha channel to extract
Returns
A float value in the range ([0..1])
- Attributes
Remarks
Returns the alpha component encoded in the specified color long. The returned value is always in the range \([0..1]\).
Java documentation for android.graphics.Color.alpha(long)
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.