You are missing the following property:
android:fitsSystemWindows="true"
in the root RelativeLayout
of the fragment .xml layout.
Update:
Last year there was an interesting talk by Chris Bane that explains in good detail how this works:
More Related Contents:
- Get real path from URI, Android KitKat new storage access framework [duplicate]
- How do I use DrawerLayout to display over the ActionBar/Toolbar and under the status bar?
- Android Completely transparent Status Bar?
- Prevent status bar for appearing android (modified)
- Preventing status bar expansion
- Host-based Card Emulation with Fixed Card ID
- Android: Resize only parts of view with soft keyboard on screen
- How to Print PDF using Android 4.4 Printing framework [closed]
- How does evaluateJavascript work?
- Android Material: Status bar color won’t change
- Android KitKat securityException when trying to read from MediaStore
- How do I maintain the Immersive Mode in Dialogs?
- Android: How to Programmatically set the size of a Layout
- How to fix android 4.4.2 error ClassNotFoundException: Didn’t find class “com.google.firebase.provider.FirebaseInitProvider” on path: DexPathList
- How to record screen and take screenshots, using Android API?
- Android ImageView adjusting parent’s height and fitting width
- Can Android’s WebView automatically resize huge images?
- Android KitKat 4.4 Hangouts cannot handle Sending SMS intent
- mylib.so has text relocations. This is wasting memory and is a security risk. Please fix
- Android pre-lollipop devices giving error “SSL handshake aborted: ssl=0x618d9c18: I/O error during system call, Connection reset by peer”
- Android detect usb storage for kitkat (4.4)
- isValidFragment Android API 19
- How to make the navigation bar transparent
- How to Record Android Screen Video programmatically in KitKat 4.4
- Autostart html5 video using android 4 browser
- Send SMS message using non default SMS app on Android 4.4
- How to show an icon in the status bar when application is running, including in the background?
- How to resize a bitmap eficiently and with out losing quality in android
- How to set status bar background as gradient color or a drawable in Android?
- Impossible to rotate the emulator with android 4.4 [duplicate]