android - How to use SearchView from dark theme in Light Appcompat theme -


i using theme.appcompat.light theme , using searchview default shows dark texts , icons..

how can use searchview defined in theme.appcompat in light theme?

already tried below not working?

<style name="theme.app.light" parent="theme.appcompat.light">    <item name="searchviewstyle">@style/widget.appcompat.searchview</item> </style>  

even using theme.appcompat.light.darkactionbar base theme not show white texts , icons..

it can done overriding values,but need use defaults provided in dark theme..

per this pro-tip, theme.appcompat.light.darkactionbar applies if using appcompat provided action bar. if using toolbar, should using theme.appcompat.light.noactionbar theme. theme toolbar appropriate dark background, need add android:theme="@style/themeoverlay.appcompat.dark.actionbar":

<android.support.v7.widget.toolbar     android:background="?attr/colorprimary"     android:theme="@style/themeoverlay.appcompat.dark.actionbar"/> 

searchview pull correct resources needed work on dark background.


Comments

Popular posts from this blog

toolbar - How to add link to user registration inside toobar in admin joomla 3 custom component -

linux - disk space limitation when creating war file -