0 votes
83 views
in android by (0 points)
closed by

In the ConstraintLayout below, why wouldn't button expand to fill the width of parent?

    <androidx.constraintlayout.widget.ConstrantLayout

        ...>

    <Button

            android:layout_width="0dp"

            android:layout_height="wrap_content"

            android:text="Button"

            app:layout_constraintStart_toStartOf="parent"

            app:layout_constraintTop_toTopOf="parent"/>

    </androidx.constraintlayout.widget.ConstrantLayout>

  1.  The button does not have a size
  2.  The button is not constrained to the end of the parent container
  3.  Buttons cannot expand beyond their default size
  4.  The button should have its height set to 0dp as well
closed

1 Answer

0 votes
by (0 points)
 
Best answer
2

2.8k questions

2.8k answers

0 comments

76 users

Welcome to MCQ Village Q&A, where you can ask questions and receive answers from other members of the community.
...