【发布时间】:2015-07-06 08:11:19
【问题描述】:
此处操作栏中文本的默认颜色为黑色。我需要文本颜色为白色。如何将颜色更改为我在 actionbar 中标题的默认颜色黑色到白色。
<!--
Base application theme, dependent on API level. This theme is replaced
by AppBaseTheme from res/values-vXX/styles.xml on newer devices.
-->
<style name="AppBaseTheme" parent="android:Theme.Light">
<!--
Theme customizations available in newer API levels can go in
res/values-vXX/styles.xml, while customizations related to
backward-compatibility can go here.
-->
</style>
<!-- Application theme. -->
<style name="AppTheme" parent="AppBaseTheme">
<!-- All customizations that are NOT specific to a particular API-level can go here. -->
</style>
<style name="MyActionBar" parent="@style/Widget.AppCompat.Light.ActionBar.Solid.Inverse">
<item name="android:background">@color/MyColor</item>
<item name="background">@color/MyColor</item>
</style>
<style name="CustomActionBarTheme" parent="@style/Theme.AppCompat.Light">
<item name="android:actionBarStyle">@style/MyActionBar</item>
<item name="actionBarStyle">@style/MyActionBar</item>
</style>
【问题讨论】:
-
发布的 style.xml 是你创建的?
标签: android android-layout android-actionbar android-styles android-titlebar