The number on the icon in the Xamarin Android Application prompts that xamarinandroid
Recently, Xamarin is used as an Android app. When opening an app, if there is a new message, you need to display a number prompt on the Toolbar or homepage icon in the app. Here we will share with you the implementation methods. If you have any updated implementation methods, please share them.
New message reminders similar to those on the Twitter Client
Solution: place the icon and number text in RelativeLayout or FrameLayout, and put the text in the upper right corner.
Implementation Code:
Create an Xamain Android project and add the Toolbar to the Main. axml file,
<Android. support. v7.widget. Toolbar
Android: id = "@ + id/toolbar"
Android: layout_width = "match_parent"
Android: layout_height = "wrap_content"
Android: minHeight = "? Attr/actionBarSize"
Android: background = "? Attr/colorPrimary ">
</Android. support. v7.widget. Toolbar>
You must use Toolbar to replace the default ActionBar, so use the custom theme to hide the default ActionBar.
Read the full text