简体   繁体   中英

How to create drawable folder in res?

I am trying to create drawable-hdpi drawable-xxhdpi drawable-ldpi folders for different screens but unable to create as it says the folders already exist but i can't see them also when trying to create drawable-xxhdpi folder on click nothing happens no folder's are create

Screenshots below

Can't see any drawable-xhdpi folder although it says it exist

在此处输入图片说明

Here on clicking OK nothing happens no folder is created

在此处输入图片说明

Yes it already exist.

you have to change the project structure

Click on top left dropdown where Android Appears.

Select project from this dropdown and you will be able to see all drawbale folders.

屏幕截图

Its because you might not have any files inside your res/drawable-xxx folders

To access them, change your project navigation:

To do so, check the top left pane for some written as 1 Project click on that or alternatively press Alt+1 here, if you see the default selection will be Android with an android bot click on the two left-right arrow icons select Project Files and then navigate!

You do not need to explicitly create the drawable folders for different resolutions. Whenever you will add any image to the project's drawable folder, by clicking right on the drawable folder and pasting the image there, a dialog will open up, that will ask you to select from drawable-hdpi, drawable-mdpi, drawable-xhdpi, and drawable-xxhdpi. You can then select the suitable one from the drop down, and you will be able to see the distinctions within the drawable folder itself.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM