android-drawable

Drawable V21 vs V24 vs custom folders for hdpi,mdpi,xhdpi etc.. ? In which folder should I put my images for multi-device support?

99封情书 提交于 2020-12-16 02:51:10
问题 I have an android application, In which home page comprises of 8 ImageViews, they act as menu options for users, So where should I put the multi-density images for these ImageViews in custom drawable folders(ldpi,mdpi,hdpi,xhdpi,xxhdpi,xxxhpi) or drawableV21 or drawableV24 ? 回答1: It changes due to your need. For images you can design it for the highest resolution and put it in xxxhpi folder. Android will automatically downscale of resolution for other devices. Also you can put different

Android Background Drawable Not Working in Button Since Android Studio 4.1

狂风中的少年 提交于 2020-11-25 03:32:52
问题 I find out that since Android Studio 4.1 I cannot change the background color of a Button by setting color on its android:background , just no effect. And custom Drawable is not working as well. My background Drawable : <shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle"> <stroke android:width="1.5dp" android:color="@android:color/black" /> <solid android:color="@android:color/white" /> <corners android:radius="8dp" /> </shape> My Button : <Button

Android Background Drawable Not Working in Button Since Android Studio 4.1

北战南征 提交于 2020-11-25 03:30:19
问题 I find out that since Android Studio 4.1 I cannot change the background color of a Button by setting color on its android:background , just no effect. And custom Drawable is not working as well. My background Drawable : <shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle"> <stroke android:width="1.5dp" android:color="@android:color/black" /> <solid android:color="@android:color/white" /> <corners android:radius="8dp" /> </shape> My Button : <Button

Android Background Drawable Not Working in Button Since Android Studio 4.1

雨燕双飞 提交于 2020-11-25 03:29:38
问题 I find out that since Android Studio 4.1 I cannot change the background color of a Button by setting color on its android:background , just no effect. And custom Drawable is not working as well. My background Drawable : <shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle"> <stroke android:width="1.5dp" android:color="@android:color/black" /> <solid android:color="@android:color/white" /> <corners android:radius="8dp" /> </shape> My Button : <Button

How to create drawable folder in res?

故事扮演 提交于 2020-07-10 12:17:09
问题 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 回答1: Yes it already exist. you have to change the project structure Click on top left