contact: 
Uki D. Lucas

Recent site activity

106c. UI layout XML for each Activity

  • define layout XML for each Activity class you will use in the application


<?xml version="1.0" encoding="utf-8"?>

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"

android:orientation="vertical" android:layout_width="fill_parent"

android:layout_height="fill_parent" android:background="#FFFFFF">


<EditText

android:text="Hi, my contact info is not set yet, someone@ChicagoAndroid.com"

android:id="@+id/contact_info" android:layout_width="fill_parent"

android:layout_height="120dip" android:layout_marginTop="15dip"

android:layout_marginLeft="10dip" android:layout_marginRight="10dip" />


<TextView

android:text="Write a short message to your friends (or audience), for example:"

android:textSize="14sp" android:layout_width="wrap_content"

android:layout_height="wrap_content" android:layout_marginTop="10dip"

android:layout_marginLeft="20dip" android:layout_marginRight="20dip"

android:textColor="#AAAAAA" />


<TextView

android:text="'Party tonight at Soundbar 226 W. Ontario St. Chicago at 8PM, see you there!'"

android:textSize="14sp" android:layout_width="wrap_content"

android:layout_height="wrap_content" android:layout_marginLeft="20dip"

android:layout_marginRight="20dip" android:textColor="#FF0000" />


<TextView android:text="and ask them to SMS word 'Info?' to your phone."

android:textSize="14sp" android:layout_width="wrap_content"

android:layout_height="wrap_content" android:layout_marginLeft="20dip"

android:layout_marginRight="20dip" android:textColor="#AAAAAA"

android:layout_marginBottom="10dip" />


<Button android:text="save" android:id="@+id/save_button"

android:textSize="18sp" android:layout_width="fill_parent"

android:layout_height="wrap_content" android:layout_marginLeft="25dip"

android:layout_marginRight="25dip" android:shadowDx="3.5" />


<TextView

android:text="Sends SMS with above info to this application's author. Your info will not be shared or sold."

android:layout_width="wrap_content" android:layout_height="wrap_content"

android:textColor="#AAAAAA" android:layout_marginTop="30dip"

android:layout_marginLeft="20dip" android:layout_marginRight="20dip"

android:textSize="14sp" android:layout_marginBottom="10dip" />


<Button android:text="test SMS" android:id="@+id/sms_test_button"

android:layout_width="fill_parent" android:layout_height="wrap_content"

android:textSize="18sp" android:layout_marginLeft="25dip"

android:layout_marginRight="25dip" />


</LinearLayout>