How do I change the actionbar\'s up arrow. I am using the action bar in android not ABS or actionbarcompat. Is there a way to change the color /image of the action bar\'s up
If you are using Toolbar, you can change the color by just changing the theme. You only have to change the style of the toolbar
app:theme="@style/ThemeOverlay.AppCompat.Light"
app:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
If you are using a dark.actionBar your back button is going to be white else if you are using light actionbar theme it is going to be black.
Update: If you want to modify the color as you wish (other then black or white) you can define a new style, parent one of the above themes and set colorControlNormal or android:textColorSecondary values to your desired color.
The answer is provided by Jake Wharton in How to customize the back button on ActionBar
<style name="Theme.MyTheme" parent="android:Theme.Holo">
<item name="android:homeAsUpIndicator">@drawable/my_up_indicator</item>
</style>
the actionbar's up arrow is an image. you can change it by download a new one and replace it:
download new image,best is to download it from google material design icon page.download it in black or white in png format.save it somewhere you can find it easily.a good choice for download is the "navigate_before" icon .
insert the image to the studio: file->new->image asset. rename the image to your preffered name ( ic_back for example).
connect the up arrow button to the new image: inside the values/styles.xml file add the item tag like that:
<style name="Theme.MyTheme" parent="android:Theme.Holo">
<item name="android:homeAsUpIndicator">@mipmap/ic_navigate_before</item>
</style>
I put the image asset inside the mipmap folder so I wrote "@mipmap" plus "/" and then the image name (mine was ic_navigate_before). hope it helped!