[英]How to change the bottom on screen soft navigation background and icon color in android?
I want to change the background color of this soft on screen navigation from black to blue. 我想将此软屏幕导航的背景颜色从黑色更改为蓝色。 Twitter android app has done it.
Twitter android应用程序已经做到了。 I did this,
我做到了
@color/colorPrimaryDark @ color / colorPrimaryDark
Before adding the navigationBarColor tag in styles.xml 在styles.xml中添加navigationBarColor标记之前
After adding the navigationBarColor tag in styles.xml 在styles.xml中添加navigationBarColor标记之后
I cannot find a way to change the icon colors to dark. 我找不到将图标颜色更改为深色的方法。
Here is my styles.xml 这是我的styles.xml
<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
<!-- Customize your theme here. -->
<item name="android:windowContentTransitions">true</item>
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
<item name="android:statusBarColor">@color/colorPrimaryDark</item>
<item name="android:windowLightStatusBar">true</item>
<item name="android:colorEdgeEffect">@color/subtleGrey</item>
<item name="actionButtonStyle">@style/myActionButtonStyle</item>
<item name="android:splitMotionEvents">false</item>
<item name="android:windowEnableSplitTouch">false</item>
<item name="android:navigationBarColor">@color/colorPrimaryDark</item>
</style>
<item name="android:navigationBarColor" tools:targetApi="lollipop">@color/colorPrimary
</item>
try it 试试吧
After a while, I got this. 过了一会儿,我明白了。
<item name="android:windowLightNavigationBar">true</item>
Adding this solved my problem! 添加这个解决了我的问题!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.