Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where are the drawables or clipart from android.R.drawable stored?

I am integrating ActionBarSherlock in my app and I want to have some menus with some items and its respective icons.

I have looked into samples and documentation, and everything seems to be clear, but when I Inflate the menu, I can see just the text because there are no icons related to each item yet.

I would like to use the icons you see when creating an android project:

Android New Project Clipart

But I can't find it, and I don't want to use direct reference to android.R.drawable in order to use those clipart icons, because I have read it is recommended to have the files in drawable folders.

like image 225
unmultimedio Avatar asked Jun 14 '13 03:06

unmultimedio


People also ask

Where is the drawable folder in Android Studio?

In Android Studio inside the res folder, one can find the drawable folder, layout folder, mipmap folder, values folder, etc. Among them, the drawable folder contains the different types of images used for the development of the application.

What does R drawable return?

drawable. image stores a resource id which will return an int. Save this answer.

What are Drawables in android?

A drawable resource is a general concept for a graphic that can be drawn to the screen and which you can retrieve with APIs such as getDrawable(int) or apply to another XML resource with attributes such as android:drawable and android:icon . There are several different types of drawables: Bitmap File.

Where can I find icons in Android Studio?

In Android Studio, right-click on the “drawable” folder and select “New” » “Vector Asset”. From there, for “Asset Type”, select “Local file (SVG, PSD)” Enter a name for the icon. Enter the path to your icon, or use the folder icon to choose the icon in your file explorer.


1 Answers

android-sdk/platforms/android-xx/data/res/drawable-yyyy

where xx is your target platform and yyyy is mdpi, hdpi, etc.

Copy the icons you want into the appropriate resource folder in your project.

like image 94
MarsAtomic Avatar answered Sep 18 '22 13:09

MarsAtomic