Menu
  • HOME
  • TAGS

How do you put 4 buttons side by side (2 on top, 2 on bottom) for Android?

android,xml,button,imagebutton,side-to-side

Just copy this xml into your layout and you'll see all the buttons aligned in 4 different corners. <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" > <Button android:id="@+id/button1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Button1" /> <Button android:id="@+id/button2" android:layout_width="wrap_content"...