我有以下布局内容:
<com.g2pdev.sudoku.ui.widget.NumbersView
android:id="@+id/numbersView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="8dp"
app:layout_constraintTop_toBottomOf="@id/actionsLayout" />
<View
android:id="@+id/bannerContainerView"
android:layout_width="match_parent"
android:layout_height="@dimen/bannerAdContainerHeight"
android:background="#ff0000"
app:layout_constraintBottom_toBottomOf="parent" />
/>
红色视图是bannerContainerView,它有固定的高度。我担心它的'顶部会重叠'的情况numbersView,所以我想将它的'顶部边缘限制为numbersView'底部。可能吗?
PSconstraintTopToBottomOf在这里不起作用,因为如果有足够的空间,它将垂直居中视图。
