Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Complete list of all Android resource folders?

First I thought that I could find this list on the net, but I'm either looking for the wrong term or such list doesn't exist.

What I need is basically a cheat sheet of all predefined resource folders in an Android project. For example, a list could say something like this

  • res/drawable - all graphics go here
  • res/drawable-hdpi - all graphics of higher resolution go here
  • res/layout - some-meaningful-description
  • res/values - some-meaningful-description
  • res/layout-land - some-meaningful-description
  • etc.

I am really surprised that such list isn't easily found on the net. Whenever I need to add some resource I haven't used before, I have to look on the net for the correct naming (and I would rather look at the list of res folders).

like image 358
sandalone Avatar asked Jan 21 '11 16:01

sandalone


1 Answers

Taken from here:

In the /res folder you can have:

  • animator/ -XML files that define property animations.

  • anim/ - XML files that define tween animations

  • color/ - XML files that define a state list of colors.

  • drawable/ - Bitmap files / Nine-Patches (re-sizable bitmaps) / State lists / Shapes / Animation drawables / Other drawables

  • layout/ - XML files that define a user interface layout.

  • menu/ - XML files that define application menus, such as an Options Menu, Context Menu, or Sub Menu.

  • raw/ - Arbitrary files to save in their raw form.

  • values/ - XML files that contain simple values, such as strings, integers, and colors.

    • arrays.xml for resource arrays (typed arrays).
    • colors.xml for color values
    • dimens.xml for dimension values.
    • strings.xml for string values.
    • styles.xml for styles.
  • xml/ - Arbitrary XML files

Also see Accessing Alternative Resources for more specific device configurations (locale, dpi, size, aspect, orientation, etc)

like image 64
f20k Avatar answered Oct 06 '22 17:10

f20k