I'm not UI designer so I can't feel xml colors enough, I want to make gradient like this:
http://t1.uccdn.com/en/images/6/5/2/img_2256_ins_45517_600.jpg
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item>
<shape>
<gradient
android:startColor="#1f313d"
android:endColor="#2c3942"
android:angle="135"/>
</shape>
</item>
but... I think that 2 colors are not enough, how to make it similar gradieñt to this image then? *last screen
How to create Gradient ??
Create Gradient is very easy
Right click on drawable
folder and create xml
file.
Create shape Tag
Inside shape tag create gradient tag
Gradient Properties........
android:startColor="put here your color"
android:endColor="put here your color"
android:centerColor="put your color here"
android:angle="45"
if you need gradient in
horizontal way put angle = "0"
vertical way put angle = "90"
corner horizontal way put angle = "45"
and opposite of corner horizontal way put angle = "135"
use this .......
<shape xmlns:android="http://schemas.android.com/apk/res/android">
<gradient android:startColor="#915d5b"
android:endColor="#418c47"
android:angle="45"></gradient>
</shape>
enjoy coding.......
Or you could simply use Gradient Generator tools at AngryTools, which is much easier and fun to use.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With