By Android Teacher on June 20th, 2013 in Appendix, Getting started tags: #AARRGGBB, #RRGGBB, alpha channel, argb, color resources, colors, colors.xml, getColor, getResources, hex colors, opacity, parseColor, predefined colors in Android, rgb, setTextColor, transparency
Android uses standard RGB (red, green and blue) color model. Each primary color value is usually represented by hexadecimal number. At the beginning of such a color definition you have to put a pound character (#).
The simplest is just #RGB format, where #000 is black and #FFF is white. But in this format we have only 16 values per color so it gives 4096 combinations. That’s why #RRGGBB format is mainly used. In this format we have 256 values per primary color, so 16 777 216 colors in total. Black is #000000 and white is #FFFFFF.
Read More