![](/img/trans.png)
[英]Change TextView color in Clicked and unClicked State using style.xml
[英]Can't change the Actionbar color when using the Style.XML (Holo Theme)
嗨,我很久以来一直在尝试使用Android Studio在一个非常简单的基本程序中更改操作栏颜色,但没有成功。 我正在使用我的Samsung Galaxy S4进行测试。 怎么了?
我的清单包含以下行:android:theme =“ @ style / AppTheme”
而Style.xml就是这样的:
**<!-- Base application theme. -->
<style name="AppTheme" parent="android:Theme.Holo.Light">
<!-- Customize your theme here. -->
</style>
<style name="MyActionBar" parent="android:style/Widget.Holo.Light.ActionBar">
<item name="android:background">#ff0000</item>
</style>**
像这样更改清单中的名称
@style/AppTheme to @style/MyActionBar
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.