I wanted to add to this a little bit as I am a new Android developer as well. The accepted answer is great, but I did run into some trouble. I wasn't sure how to add in the color to the colors.xml file. Here is how it should be done:
And so I did that for the color as well, but I didn't understand that the "@color/" reference meant look for the tag "color" in the XML. I thought that I should mention this as well to help anyone else out.
I wanted to add to this a little bit as I am a new Android developer as well. The accepted answer is great, but I did run into some trouble. I wasn't sure how to add in the color to the colors.xml file. Here is how it should be done:
colors.xml
In my original colors.xml file I had the tag "drawable":
And so I did that for the color as well, but I didn't understand that the "@color/" reference meant look for the tag "color" in the XML. I thought that I should mention this as well to help anyone else out.