Styling ActionMode ActionBar in Android 5.0 Lollipop (with AppCompat)

后端 未结 2 1313
自闭症患者
自闭症患者 2020-12-04 10:35

I used this tutorial to facelift my Holo app for Lollipop: http://android-developers.blogspot.ru/2014/10/appcompat-v21-material-design-for-pre.html

What I have:

相关标签:
2条回答
  • 2020-12-04 11:11

    Just add these two lines to the theme:

    <item name="actionModeBackground">@color/theme_primary_dark</item>
    <item name="actionBarPopupTheme">@style/ThemeOverlay.AppCompat.Light</item>
    
    0 讨论(0)
  • 2020-12-04 11:32

    This might also be helpful in addition to @Andrey Shcherbakov's answer if you want to have more control of each individual color.

    <!-- action bar title text color, icon color (ie: back icon, icons when editing text)-->
    <item name="android:textColorPrimary">#FFFF00</item>
    
    <!-- action bar background color-->
    <item name="android:colorBackground">#444400</item>
    
    <!-- color of line under contextual action bar-->
    <item name="colorControlActivated">#00CC00</item>
    
    0 讨论(0)
提交回复
热议问题