When I put the tabs at bottom, the icons shows only the silhouette. I just used this command to put the guide down.
When I put the tabs at bottom, the icons shows only the silhouette. I just used this command to put the guide down.
If you want to use multicolored icon on the bottom navigation view, you have to create a custom renderer for tabbed page on Android and then change the configurations there:
[assembly: ExportRenderer(typeof(YourTabbedPage), typeof(MyTabbedPageRenderer))]
namespace TabbedDemo.Droid
{
public class MyTabbedPageRenderer : TabbedPageRenderer
{
public MyTabbedPageRenderer(Context context) : base(context)
{
}
protected override void OnElementChanged(ElementChangedEventArgs<TabbedPage> e)
{
base.OnElementChanged(e);
if (e.OldElement == null && e.NewElement != null)
{
for (int i = 0; i <= this.ViewGroup.ChildCount - 1; i++)
{
var childView = this.ViewGroup.GetChildAt(i);
if (childView is ViewGroup viewGroup)
{
for (int j = 0; j <= viewGroup.ChildCount - 1; j++)
{
var childRelativeLayoutView = viewGroup.GetChildAt(j);
if (childRelativeLayoutView is BottomNavigationView)
{
((BottomNavigationView)childRelativeLayoutView).ItemIconTintList = null;
}
}
}
}
}
}
}
}