Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android : status bar color change for API level below 21

I am trying change status bar color for API level lower than 21.By changing the color primary in Theme style we can change the color in status bar for the API level 21.

Playstore

I am looking for how to change the status bar color for lower version

Can any one please help me ?

like image 610
Binil Surendran Avatar asked Dec 04 '15 09:12

Binil Surendran


1 Answers

Changing the color of statusbar is available from Lollipop

but actually you could change the color of statusbar for Api >= 19

inside the style of value-v19 put

<?xml version="1.0" encoding="utf-8"?>
<resources>

        <style name="AppTheme" parent="MaterialDrawerTheme.Light">
                <!-- Customize your theme here. -->
                <item name="android:windowNoTitle">true</item>
                <item name="android:windowTranslucentStatus">true</item>
                .....
        </style>
</resources>

the background color of the status bar will became transparent color, and for coloring it you just put a background color in your to your app so the status bar will take that color

hope that was clear and helpful

like image 141
Netero Avatar answered Oct 22 '22 07:10

Netero