Appbar Won't Overlap Statusbar, When Using Collapsingtoolbarlayout
I want AppBar to overlap StatusBar. AppBar has image as background and I want this image to overlap statusbar, but when I use CollapsingToolbarLayout StatusBar gets white and image
Solution 1:
Take a folder and set the theme..
Main theme In values/styles.xml
<resources><stylename="BaseTheme"parent="Theme.AppCompat.Light.NoActionBar"><itemname="colorPrimary">@color/primary</item><itemname="colorPrimaryDark">@color/primary_dark</item><itemname="colorControlHighlight">@color/accent_translucent</item><itemname="colorAccent">@color/accent</item></style></resources>
res/values-v21/styles.xml
<resources><stylename="AppTheme"parent="BaseTheme"><itemname="android:colorControlHighlight">@color/accent_translucent</item><itemname="android:windowSharedElementsUseOverlay">false</item><itemname="android:statusBarColor">@android:color/transparent</item></style></resources>
Note: If you are using android:windowTranslucentStatus ... Remove it From themeor set false
<item name="android:windowTranslucentStatus">true</item>
Example shown here By this I am Remove this part and get result
Follow the Example For your requirement fulfillment
https://github.com/antoniolg/MaterializeYourApp
Like that result
Post a Comment for "Appbar Won't Overlap Statusbar, When Using Collapsingtoolbarlayout"