Android State list generator


Inspired by a post from stackoverflow, I made a simple XML State List generator :), you simply need to fill the inputs with your corresponding drawable names and then press Generate button. For more details regarding android StateList XML please check the official documentation.
Android state list generator version 2 is here:

 New in android state list generator version 2:
* added all supported android states
* added checkboxes to choose custom states combination
* added description to all states and grouped the states by Android API level

States

For all API levels:
Pressed: Focused: Selected: Checkable:
This item should be used when the object is pressed (such as when a button is touched/clicked) This item should be used when the object has input focus (such as when the user selects a text input) This item should be used when the object is the current user selection when navigating with a directional control (such as when navigating through a list with a d-pad) This item should be used when the object is checkable; “false” if this item should be used when the object is not checkable. (Only useful if the object can transition between a checkable and non-checkable widget.)
Checked: Enabled: Window Focused:
This item should be used when the object is checked This item should be used when the object is enabled (capable of receiving touch/click events) This item should be used when the application window has focus (the application is in the foreground)
For API level 11+:
Activated:
This item should be used when the object is activated as the persistent selection (such as to “highlight” the previously selected list item in a persistent navigation view)
For API level 14+:
Hovered:
This item should be used when the object is being hovered by a cursor

 

Please input drawable names below (just the drawable names, without extension like .png):

Results:

sponsored
Exit mobile version