我想使用 com.roughike.bottombar.BottomBar
但即使在底部设置重力后,它也会隐藏在操作栏后面。请解决我的错误。
谢谢。
activity_main.xml
<android.support.design.widget.CoordinatorLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent">
<FrameLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/frame"
android:layout_above="@+id/bottomBar"
/>
<com.roughike.bottombar.BottomBar
android:id="@+id/bottomBar"
android:layout_width="match_parent"
android:layout_height="56dp"
android:gravity="bottom"
app:bb_tabXmlResource="@xml/bottombar_tabs_color_changing"
app:bb_behavior="shifting|shy|underNavbar" />
</android.support.design.widget.CoordinatorLayout>
最佳答案
使用 android:layout_gravity="bottom"
它会起作用!
关于android - 底栏未在底部对齐,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42110751/