Android layout 如何从图像视图中心水平线查看图像右侧
我想要我的android布局 但我很难去布局形象 我被试着去画:Android layout 如何从图像视图中心水平线查看图像右侧,android-layout,Android Layout,我想要我的android布局 但我很难去布局形象 我被试着去画: <shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="line"> <stroke android:color="@color/colorwhite" android:dashWidth="60px" android:dashGap="30px" android:width=
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="line">
<stroke
android:color="@color/colorwhite"
android:dashWidth="60px"
android:dashGap="30px"
android:width="3dp"/>
</shape>
但当我在xml文本中布局时:
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageView
android:id="@+id/img1"
android:layout_width="100dp"
android:layout_height="100dp"
android:layout_marginBottom="@dimen/dimen20dp"
android:background="@drawable/verifikasiemail"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<ImageView
android:layout_width="wrap_content"
android:layout_height="4dp"
android:src="@drawable/stripstrip"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintStart_toEndOf="@+id/img1"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintBottom_toBottomOf="parent"/>
</androidx.constraintlayout.widget.ConstraintLayout>
只需更改第二张图像的android:layout\u width=“0dp”