Android - 将视图中心与其他视图的左侧对齐

Android - Align view center to left of other view

我想用ConstraintLayout做这个,但是我不知道怎么做...

编辑: 谢谢您的回答。现在找到了解决方法,代码如下

app:layout_constraintLeft_toLeftOf="@id/textView"
app:layout_constraintRight_toLeftOf="@id/textView"

但是为什么这个问题关不掉

这个很简单。将左对齐和右对齐到引用视图的左侧,然后它成为对齐到引用视图左侧的中心。

    app:layout_constraintLeft_toLeftOf="@id/textView"
    app:layout_constraintRight_toLeftOf="@id/textView"