ColorObject Class

Definition

{

[Android.Runtime.Register("android/graphics/Color", DoNotGenerateAcw=true)]
public class ColorObject : Java.Lang.Object
[<Android.Runtime.Register("android/graphics/Color", DoNotGenerateAcw=true)>]
type ColorObject = class
    inherit Object
Inheritance
ColorObject
Attributes

Remarks

{

Java documentation for android.graphics.Color.

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.

Constructors

ColorObject()

Creates a new color instance set to opaque black in the ColorSpace.Named#SRGB sRGB color space.

ColorObject(IntPtr, JniHandleOwnership)

Fields

Black
Cyan
Dkgray
Gray
Ltgray
Magenta
Transparent
White
Yellow

Properties

Class

Returns the runtime class of this Object.

(Inherited from Object)
ColorSpace

Returns this color's color space.

ComponentCount

Returns the number of components that form a color value according to this color space's color model, plus one extra component for alpha.

Handle

The handle to the underlying Android instance.

(Inherited from Object)
IsSrgb

Indicates whether this color is in the ColorSpace.Named#SRGB sRGB color space.

IsWideGamut

Indicates whether this color color is in a wide-gamut color space.

JniIdentityHashCode (Inherited from Object)
JniPeerMembers
Model

Returns the color model of this color.

PeerReference (Inherited from Object)
ThresholdClass
ThresholdType

Methods

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.

Argb(Int32, Int32, Int32, Int32)

Return a color-int from alpha, red, green, blue components.

Argb(Single, Single, Single, Single)

Return a color-int from alpha, red, green, blue float components in the range ([0.

Blue()

Returns the value of the blue component in the range defined by this color's color space (see ColorSpace#getMinValue(int) and ColorSpace#getMaxValue(int)).

Blue(Color)

Return the blue component of a color int.

Blue(Int64)

Returns the blue component encoded in the specified color long.

Clone()

Creates and returns a copy of this object.

(Inherited from Object)
ColorToHSV(Color, Single[])

Convert the ARGB color to its HSV components.

Convert(Color, ColorSpace)

Converts the specified ARGB color int from the ColorSpace.Named#SRGB sRGB color space into the specified destination color space.

Convert(ColorSpace)

Converts this color from its color space to the specified color space.

Convert(Int64, ColorSpace)

Converts the specified color long from its color space into the specified destination color space.

Convert(Int64, ColorSpace+Connector)

Converts the specified 3 component color from the source color space to the destination color space.

Convert(Single, Single, Single, Single, ColorSpace, ColorSpace)

Converts the specified 3 component color from the source color space to the destination color space.

Convert(Single, Single, Single, Single, ColorSpace+Connector)

Converts the specified 3 component color from the source color space to the destination color space.

Dispose() (Inherited from Object)
Dispose(Boolean) (Inherited from Object)
Equals(Object)

Indicates whether some other object is "equal to" this one.

(Inherited from Object)
GetComponent(Int32)

Returns the value of the specified component in the range defined by this color's color space (see ColorSpace#getMinValue(int) and ColorSpace#getMaxValue(int)).

GetComponents()

Returns this color's components as a new array.

GetComponents(Single[])

Copies this color's components in the supplied array.

GetHashCode()

Returns a hash code value for the object.

(Inherited from Object)
Green()

Returns the value of the green component in the range defined by this color's color space (see ColorSpace#getMinValue(int) and ColorSpace#getMaxValue(int)).

Green(Color)

Return the green component of a color int.

Green(Int64)

Returns the green component encoded in the specified color long.

HSVToColor(Int32, Single[])

Convert HSV components to an ARGB color.

HSVToColor(Single[])

Convert HSV components to an ARGB color.

InvokeColorSpace(Int64)

Returns the color space encoded in the specified color long.

InvokeIsSrgb(Int64)

Indicates whether the specified color is in the ColorSpace.Named#SRGB sRGB color space.

InvokeIsWideGamut(Int64)

Indicates whether the specified color is in a wide-gamut color space.

IsInColorSpace(Int64, ColorSpace)

Indicates whether the specified color is in the specified color space.

JavaFinalize()

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.

(Inherited from Object)
Luminance()

Returns the relative luminance of this color.

Luminance(Color)

Returns the relative luminance of a color.

Luminance(Int64)

Returns the relative luminance of a color.

Notify()

Wakes up a single thread that is waiting on this object's monitor.

(Inherited from Object)
NotifyAll()

Wakes up all threads that are waiting on this object's monitor.

(Inherited from Object)
Pack()

Packs this color into a color long.

Pack(Color)

Converts the specified ARGB color int to an RGBA color long in the sRGB color space.

Pack(Single, Single, Single)

Packs the sRGB color defined by the specified red, green and blue component values into an RGBA color long in the sRGB color space.

Pack(Single, Single, Single, Single)

Packs the sRGB color defined by the specified red, green, blue and alpha component values into an RGBA color long in the sRGB color space.

Pack(Single, Single, Single, Single, ColorSpace)

Packs the 3 component color defined by the specified red, green, blue and alpha component values into a color long in the specified color space.

ParseColor(String)

</p>Parse the color string, and return the corresponding color-int.

Red()

Returns the value of the red component in the range defined by this color's color space (see ColorSpace#getMinValue(int) and ColorSpace#getMaxValue(int)).

Red(Color)

Return the red component of a color int.

Red(Int64)

Returns the red component encoded in the specified color long.

Rgb(Int32, Int32, Int32)

Return a color-int from red, green, blue components.

Rgb(Single, Single, Single)

Return a color-int from red, green, blue float components in the range ([0.

RGBToHSV(Int32, Int32, Int32, Single[])

Convert RGB components to HSV.

SetHandle(IntPtr, JniHandleOwnership)

Sets the Handle property.

(Inherited from Object)
ToArgb()

Converts this color to an ARGB color int.

ToArgb(Int64)

Converts the specified color long to an ARGB color int.

ToArray<T>() (Inherited from Object)
ToString()

Returns a string representation of the object.

(Inherited from Object)
UnregisterFromRuntime() (Inherited from Object)
ValueOf(Color)

Creates a new Color instance from an ARGB color int.

ValueOf(Int64)

Creates a new Color instance from a color long.

ValueOf(Single, Single, Single)

Creates a new opaque Color in the ColorSpace.Named#SRGB sRGB color space with the specified red, green and blue component values.

ValueOf(Single, Single, Single, Single)

Creates a new Color in the ColorSpace.Named#SRGB sRGB color space with the specified red, green, blue and alpha component values.

ValueOf(Single, Single, Single, Single, ColorSpace)

Creates a new Color in the specified color space with the specified red, green, blue and alpha component values.

ValueOf(Single[], ColorSpace)

Creates a new Color in the specified color space with the specified component values.

Wait()

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>.

(Inherited from Object)
Wait(Int64)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)
Wait(Int64, Int32)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)

Explicit Interface Implementations

IJavaPeerable.Disposed() (Inherited from Object)
IJavaPeerable.DisposeUnlessReferenced() (Inherited from Object)
IJavaPeerable.Finalized() (Inherited from Object)
IJavaPeerable.JniManagedPeerState (Inherited from Object)
IJavaPeerable.SetJniIdentityHashCode(Int32) (Inherited from Object)
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) (Inherited from Object)
IJavaPeerable.SetPeerReference(JniObjectReference) (Inherited from Object)

Extension Methods

JavaCast<TResult>(IJavaObject)

Performs an Android runtime-checked type conversion.

JavaCast<TResult>(IJavaObject)
GetJniTypeName(IJavaPeerable)

Applies to