Created
July 1, 2018 22:16
-
-
Save root-ansh/a609d4ca4c541839f27171a958439bc3 to your computer and use it in GitHub Desktop.
Custom drawer 1.5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:app="http://schemas.android.com/apk/res-auto" | |
... | |
> | |
<com.google.android.material.appbar.AppBarLayout | |
... | |
> | |
<androidx.appcompat.widget.Toolbar | |
android:id="@+id/toolbar" | |
android:layout_width="match_parent" | |
android:layout_height="wrap_content" <-- Adding wrap content to our height and making --> | |
android:minHeight="90dp" <-- the min height set to a static value increases our app bar's height making it a beautiful status bar's background without being overlapping the icons --> | |
android:paddingTop="20dp" <-- However the toolbar icons and title seems to be at the centre of this expanded toolbar,therefor a simple padding top did the trick --> | |
... /> | |
... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment