更改操作栏设置图标颜色 [英] Change the action bar settings icon color
本文介绍了更改操作栏设置图标颜色的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何更改操作栏中溢出图标的颜色?
How can one change the color of the overflow icon in the action bar?
(最右边的图标)
推荐答案
你可以使用这样的东西
<style name="MyTheme" parent="android:style/Theme.Holo.Light">
<item name="android:actionOverflowButtonStyle">@style/MyActionButtonOverflow</item>
</style>
<style name="MyActionButtonOverflow" parent="android:style/Widget.Holo.ActionButton.Overflow">
<item name="android:src">@drawable/my_action_bTutton_overflow</item>
</style>
清单文件中的
in your manifestfile
<application
android:theme="@style/MyTheme" >
如果你想chane actionBar颜色
@ style / MyActionBar
If you want to chane actionBar color @style/MyActionBar
<!-- Support library compatibility -->
<item name="actionBarStyle">@style/MyActionBar</item>
</style>
<!-- ActionBar styles -->
<style name="MyActionBar" parent="@style/Widget.AppCompat.Light.ActionBar.Solid.Inverse">
<item name="android:background">@color/app_theme_color</item>
<!-- Support library compatibility -->
<item name="background">@color/app_theme_color</item>
<item name="android:alwaysDrawnWithCache">true</item>
<item name="android:displayOptions">showTitle|showHome|homeAsUp</item>
<item name="android:icon">@android:color/transparent</item>
</style>
然后在您的 AndroidManifest.xml
中,您需要在你的应用程序
标签中引用这个。
Then in your AndroidManifest.xml
you need to refer this one inside your application
tag.
android:theme="@style/CustomActionBarTheme"
这篇关于更改操作栏设置图标颜色的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文