In my application there will be in-app notifications and I wish for the amount of notifications to be displayed adjacent to the hamburger icon which opens the navigation drawer which contains the button to actually view the notifications.
The image below shows what I have at the moment
Below is the code which carries this out
<android.support.v7.widget.Toolbar
android:id="@+id/toolbar"
android:minHeight="?attr/actionBarSize"
android:background="@color/colorPrimary"
android:layout_width="match_parent"
app:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
android:layout_height="wrap_content">
<TextView
android:id="@+id/notification"
android:text="99"
android:padding="1dp"
android:background="@drawable/circle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="start|top"
/>
<TextView
android:id="@+id/toolbarTitle"
android:text="test"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
/>
</android.support.v7.widget.Toolbar>
This is what I would like to achieve for now
As you can see the TextView is closer to the hamburger icon since the right padding of the icon has been reduced
This is my dream (if it can be possible)
What I have tried
I have tried to adjust the contentInsetStart and contentInsetEnd as stated in this answer but did not work as I intended Android API 21 Toolbar Padding
Please help. Thanks!
EDIT 1: Adding negative left padding to text view