I want to hide status bar / notification bar in splash screen I am using
style:<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
this dose not hide the status bar, how should i do this?
To customize it, first pull down the slider bar from the top of the screen. Next, tap on the three vertical dots in the top right corner. Now click on Status bar. You're in.
If you want to remove status bar then use this before setContentView(layout) in onCreateView method
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,
WindowManager.LayoutParams.FLAG_FULLSCREEN);
credits
You can do something like below for appropriately setting theme on your particular activity -
<style name="SplashTheme" parent="Theme.AppCompat.NoActionBar">
<item name="android:windowBackground">@drawable/launch_theme</item>
<item name="android:windowTranslucentNavigation">false</item>
<item name="android:windowNoTitle">true</item>
<item name="android:windowActionBar">true</item>
<item name="android:windowFullscreen">true</item>
<item name="android:windowContentOverlay">@null</item>
<item name="android:windowDrawsSystemBarBackgrounds">false</item>
</style>
Try this:
<style name="SplashTheme" parent="Theme.AppCompat.NoActionBar">
<item name="android:windowFullscreen">true</item>
</style>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With