0

I want to show some buttons in bottom of page, my Buttons are images and text then i use Button tag in XML. I have 4 picture for buttons(PNG pic). I write this XML but my buttons not show together and not stand in bottom of page, these show a little, higher the page and far apart.

xml File:

 <?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/linearLayout"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:background="@color/white">
<TextView
    android:id="@+id/logoText"
    android:layout_width="fill_parent"
    android:layout_height="wrap_content"

    android:background="@color/dark_blue"
    android:textColor="@color/blue_text"
    android:textSize="20sp"
    android:paddingRight="3dp"/>
<FrameLayout
    android:id="@+id/frameLayout"
    android:layout_width="fill_parent"
    android:layout_height="0dp"
    android:layout_weight="1.0"/>
<LinearLayout
    android:id="@+id/linearLayout2"
    android:layout_width="fill_parent"
    android:layout_height="wrap_content"
    android:orientation="horizontal"
    android:layout_weight="0">
    <Button
        android:id="@+id/btn1"
        android:layout_marginRight="-10dp"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"
        android:drawableTop="@drawable/image"
        android:soundEffectsEnabled="true"
        android:background="@null"/>
    <Button
        android:id="@+id/btn2"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"
        android:drawableTop="@drawable/b2"
        android:soundEffectsEnabled="true"
        android:background="@null"/>
    <Button 
        android:id="@+id/btn3"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"
        android:drawableTop="@drawable/b3"
        android:soundEffectsEnabled="true"
        android:background="@null"/>
    <Button 
        android:id="@+id/btn4"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"
        android:drawableTop="@drawable/b4"
        android:soundEffectsEnabled="true"
        android:background="@null"/>
    </LinearLayout>
    </LinearLayout>

sorry for my poor english and thanks for your advise.

Thanks.Cheers.

SensorS
  • 383
  • 3
  • 8
  • 20

1 Answers1

0

remove 'layout_weight="0"' below, and try again

<LinearLayout
android:id="@+id/linearLayout2"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_weight="0">
Denny
  • 149
  • 1
  • 1
  • 5