Advertisement
Guest User

Untitled

a guest
Sep 17th, 2010
260
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 2.10 KB | None | 0 0
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3.    android:orientation="vertical"
  4.    android:layout_width="fill_parent"
  5.    android:layout_height="fill_parent" >
  6.     <LinearLayout
  7.         <!--Giving the Header a reference ID-->
  8.         android:id="@+id/header"
  9.         android:layout_width="fill_parent"
  10.         android:layout_height="20dp"
  11.         android:layout_alignParentTop="true"
  12.         android:background="#000000" >
  13.         <TextView
  14.             android:layout_width="fill_parent"
  15.             android:layout_height="wrap_content"
  16.             android:textSize="15sp"
  17.             android:textColor="#ffffff"
  18.             android:text="My header" />
  19.     </LinearLayout>
  20.  
  21.     <ScrollView
  22.         android:layout_width="fill_parent"
  23.         android:layout_height="fill_parent"
  24.         <!--Here, we tell it to place the top edge of the ScrollView
  25.         below the bottom edge of the header-->
  26.         android:layout_below="@id/header"
  27.         <!--Here, we tell it to place the bottom edge of the ScrollView
  28.         above the top edge of the footer-->
  29.         android:layout_above="@id/footer"
  30.         android:layout_weight="1"
  31.         android:gravity="bottom"
  32.         android:background="#894545">
  33.         <LinearLayout
  34.             android:orientation="vertical"
  35.             android:layout_width="fill_parent"
  36.             android:layout_height="wrap_content" />
  37.     </ScrollView>
  38.    
  39.     <LinearLayout
  40.         <!--Here, we give the footer a reference ID-->
  41.         android:id="@+id/footer"
  42.         android:layout_width="fill_parent"
  43.         android:layout_height="wrap_content"
  44.         android:padding="2dp"
  45.         android:layout_alignParentBottom="true"
  46.         android:isScrollContainer="true"
  47.         android:background="@drawable/steel" >
  48.         <EditText
  49.             android:layout_width="fill_parent"
  50.             android:layout_height="wrap_content"
  51.             android:layout_weight="0.2"
  52.             android:scrollbars="vertical"
  53.             android:fadingEdge="vertical"
  54.             android:maxHeight="40dp"
  55.             android:textSize="15sp" />
  56.         <Button
  57.             android:layout_width="fill_parent"
  58.             android:layout_height="wrap_content"
  59.             android:layout_weight="0.8"
  60.             android:layout_gravity="right"
  61.             android:text="Send"
  62.             android:textStyle="bold"
  63.             android:textSize="15sp" />
  64.     </LinearLayout>
  65. </RelativeLayout>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement