I have the following xml file:
<?xml version="1.0" encoding="UTF-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android">
<solid android:color="#FFFFFF"/>
<corners android:radius="10dp"/>
<padding android:left="0dp" android:top="0dp" android:right="0dp" android:bottom="0dp" />
</shape>
as you can see, all it is, is a shape with rounded corners. I use it for background in activity layouts as follows:
android:background="@drawable/rounded_corners"
The shape in the file is currently set to white. In different layouts I need different colors. Do I need to create a different shape xml file for each color? I need a way to just specify in the layout what color to send to the background, and that way I can use the same xml for any color I want.
Thanks.