Apparently match_parent
is :
ConstraintLayout
ConstraintLayout
So if you need your views to function as match_parent
, then:
ConstraintLayout
should use 0dp
match_parent
Example:
<android.support.constraint.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingBottom="16dp">
<android.support.design.widget.TextInputLayout
android:id="@+id/phoneNumberInputLayout"
android:layout_width="0dp"
android:layout_height="wrap_content"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent">
<android.support.design.widget.TextInputEditText
android:id="@+id/phoneNumber"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
</android.support.design.widget.TextInputLayout>