我正在尝试给我的底部导航添加圆角,我已经尝试改变宽度和高度但是没有起作用。我使用的是相对布局,宽度设置为“fill_parent”,高度设置为“warp_content”。我有两个图标登录和注册,我希望整个导航都有圆角。我正在使用Material Design底部导航:
<com.google.android.material.bottomnavigation.BottomNavigationView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:id="@+id/botttom_navigation"
app:itemBackground="@android:color/darker_gray"
app:itemTextColor="@drawable/selector"
app:itemIconTint="@drawable/selector"
android:layout_alignParentBottom="true"
app:menu="@menu/menu_navigation"/>
这就是它的样子。
MaterialShapeDrawable
,这意味着在形状外观、暗模式下的高程叠加方面将被忽略。 - Gabriele Mariotti<corners
android:topLeftRadius="16dp"
android:topRightRadius="16dp"/>
- V Surya Kumar