ActionBarDrawerToggle V7箭头的颜色 [英] ActionBarDrawerToggle v7 arrow color
本文介绍了ActionBarDrawerToggle V7箭头的颜色的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
当我试图改变抽屉式导航切换颜色,只有汉堡包改变它,箭头保持她原有颜色。在这里你可以看到它 -
When I try to change navigation drawer toggle color, only hamburger changes it, arrow keeps her native color. You can see it here -
<style name="AppTheme" parent="Theme.AppCompat.NoActionBar">
<item name="android:windowBackground">@drawable/app_background</item>
<item name="android:dropDownListViewStyle">@style/DropDownListViewStyle</item>
<item name="colorPrimary">@color/primary</item>
<item name="colorPrimaryDark">@color/primary_dark</item>
<item name="colorAccent">@color/accent</item>
<item name="android:textColor">@color/primary_text</item>
<item name="android:windowNoTitle">true</item>
<item name="windowActionBar">false</item>
<item name="drawerArrowStyle">@style/DrawerArrowStyle</item>
</style>
<style name="DrawerArrowStyle" parent="@style/Widget.AppCompat.DrawerArrowToggle">
<item name="spinBars">true</item>
<item name="color">@android:color/holo_red_dark</item>
</style>
如果我更改父主题Theme.AppCompat.Light箭头改变了她的颜色为黑色。 下面的小部件均采用: android.support.v7.app.ActionBarDrawerToggle; android.support.v7.widget.Toolbar;
If I change parent theme to Theme.AppCompat.Light arrow changes her color to black. The following widget are used: android.support.v7.app.ActionBarDrawerToggle; android.support.v7.widget.Toolbar;
我是什么做错了吗?
推荐答案
尝试使用
<item name="colorControlNormal">@color/your_color</item>
<item name="android:colorControlNormal">@color/your_color</item>
,而不是你的抽屉箭头样式。
instead of your drawer arrow style.
要清除我的意见,也尝试:
To clear out my comment, try also:
<item name="actionBarStyle">@style/My.ActionBar.Style</item>
然后:
<style name="My.ActionBar.Style" parent="Widget.AppCompat.ActionBar">
<item name="colorControlNormal">@color/your_color</item>
<item name="android:colorControlNormal">@color/your_color</item>
</style>
这篇关于ActionBarDrawerToggle V7箭头的颜色的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文