Context.GetColorStateList(Int32) Method

Definition

Returns a color state list associated with a particular resource ID and styled for the current theme.

[Android.Runtime.Register("getColorStateList", "(I)Landroid/content/res/ColorStateList;", "", ApiSince=23)]
public Android.Content.Res.ColorStateList GetColorStateList (int id);
[<Android.Runtime.Register("getColorStateList", "(I)Landroid/content/res/ColorStateList;", "", ApiSince=23)>]
member this.GetColorStateList : int -> Android.Content.Res.ColorStateList

Parameters

id
Int32

The desired resource identifier, as generated by the aapt tool. This integer encodes the package, type, and resource entry. The value 0 is an invalid identifier.

Returns

A color state list.

Attributes

Remarks

Returns a color state list associated with a particular resource ID and styled for the current theme.

Java documentation for android.content.Context.getColorStateList(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