Yesterday I started with android programming. Now I want to create a simple layout. Here is an image:
How can I give the buttons a width of 100%? When I write
android:layout_width="0dp"
will the button no longer displayed. What is my mistake?
Here is the code again.
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="1" />
<Button
android:layout_width="0dp"
android:layout_height="wrap_content"
android:text="2" />
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="3" />
</LinearLayout>