Action
    Preparing search index...

    Represents a color with three bytes for the r,g,b components and a float for alpha.

    2.0

    Hierarchy (View Summary)

    Index

    Methods

    • Casts this object to the specified type. Throws error on failure.

      Type Parameters

      • T1

        The target type of the cast.

      • T2

        The type of the object to cast.

      Parameters

      Returns T1

    • Returns the hash code for this instance.

      Returns number

      A 32-bit signed integer that is the hash code for this instance.

    • Returns the fully qualified type name of this instance.

      Returns string

      The fully qualified type name.

    • Casts this object to the specified type. Returns null on failure.

      Type Parameters

      • T1

        The target type of the cast.

      • T2

        The type of the object to cast.

      Parameters

      Returns T1 | null

    • Determines whether the specified object instances are considered equal.

      Parameters

      • objA: any

        The first object to compare.

      • objB: any

        The second object to compare.

      Returns boolean

      true if the objects are considered equal; otherwise, false. If both objA and objB are null, the method returns true.

    Default capability

    Transparent color. Has all components set to zero (transparent black). Note that this is different from System.Drawing.Color.Transparent which is transparent white.

    2.0

    • get A(): number

      Gets the alpha value of this color.

      Returns number

      2.0

    • get B(): number

      Gets the blue value of this color.

      Returns number

      2.0

    • get G(): number

      Gets the green value of this color.

      Returns number

      2.0

    • get IsOpaque(): boolean

      Gets a value indicating whether this instance is completely opaque.

      Returns boolean

      2.0

    • get IsTransparent(): boolean

      Gets a value indicating whether this instance is completely transparent.

      Returns boolean

      2.0

    • get R(): number

      Gets the red value of this color.

      Returns number

      2.0

    • Determines whether the specified object is equal to the current object.

      Parameters

      • obj: any

        The object to compare with the current object.

      Returns boolean

      true if the specified object is equal to the current object; otherwise, false.

    • Indicates whether this instance and a specified object are equal.

      Parameters

      • obj: any

        The object to compare with the current instance.

      Returns boolean

      true if obj and this instance are the same type and represent the same value; otherwise, false.

    • Indicates whether the current object is equal to another object of the same type.

      Parameters

      Returns boolean

      true if the current object is equal to the other parameter; otherwise, false.

      2.0

    • Converts this color to an integer.

      Returns number

      Color as an integer made up from a, r, g, b values.

      2.0