xml 样式 --底部两个按钮,设置不同内容
2020-03-10 本文已影响0人
勤劳的蚂蚁
image.png
<android.support.constraint.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="@dimen/dimen_48dp"
android:background="#ffffff">
<View
android:id="@+id/view_bg1"
android:layout_width="1dp"
android:layout_height="5dp"
android:background="@color/colorf4f4f4"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"></View>
<View
android:id="@+id/view_bg2"
android:layout_width="1dp"
android:layout_height="0dp"
android:background="@color/colorf4f4f4"
android:gravity="center_horizontal"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
android:layout_marginTop="@dimen/margin5"
android:layout_marginBottom="@dimen/margin5"
app:layout_constraintTop_toTopOf="parent"></View>
<TextView
android:id="@+id/tv_left"
android:layout_width="0dp"
android:layout_height="0dp"
android:background="@color/color_FFFFFF"
android:gravity="center"
android:textColor="@color/color999999"
android:textSize="@dimen/text14"
android:text="不是以上问题"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintTop_toBottomOf="@+id/view_bg1"
app:layout_constraintRight_toLeftOf="@+id/view_bg2"
android:clickable="true"
android:visibility="visible"
tools:text="不是以上问题" />
<TextView
android:id="@+id/tv_right"
android:layout_width="0dp"
android:layout_height="0dp"
android:background="@color/color_FFFFFF"
android:gravity="center"
android:textColor="@color/colorff5722"
android:textSize="@dimen/text14"
android:text="向提问吧"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="@+id/view_bg2"
app:layout_constraintTop_toBottomOf="@+id/view_bg1"
android:clickable="true"
tools:text="向提问吧" />
</android.support.constraint.ConstraintLayout>