具有左上方空间问题的底部导航视图 [英] Bottom Navigation View With Left Righ Space Issue

查看:60
本文介绍了具有左上方空间问题的底部导航视图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是android的新手,我使用带有两个菜单的底部导航视图

I am newbie in android, i am use bottom navigation view with two menus

但是我得到了左右空间

这是我的导航视图,

<android.support.design.widget.BottomNavigationView
        android:id="@+id/bottom_navigation"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true"

        app:itemBackground="@color/colorRed"
        app:itemIconTint="@color/colorWhite"
        app:itemTextColor="@color/colorWhite"
        app:menu="@menu/bottom_bar_menu"/>

请检查图片

推荐答案

根据材料设计指南 您不能将两个菜单与底部导航一起使用,而不能将bottomNavigation视图与选项卡布局一起使用 检查此链接以获取指南 https://material.io/guidelines/components/bottom-navigation.html#bottom-navigation-usage

According to Material design guidelines You can't use two menus with bottom navigation use, instead of bottomNavigation view use tab layout Check this link for guidlines https://material.io/guidelines/components/bottom-navigation.html#bottom-navigation-usage

仍然,如果要使用底部导航视图

Still, if you want to use bottom navigation view

BottomNavigationView

android:background="@color/colorRed"

这篇关于具有左上方空间问题的底部导航视图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆