用户界面 View(一)
<?xml version=”1.0″ encoding=”utf-8″?><FrameLayout android:id=”@+id/FrameLayout01″
android:layout_width=”fill_parent” android:layout_height=”fill_parent”
xmlns:android=”http://schemas.android.com/apk/res/android”><ImageView android:id=”@+id/ImageView01″ android:src=”@drawable/p1″
android:layout_width=”wrap_content” android:layout_height=”wrap_content”></ImageView><ImageView android:id=”@+id/ImageView02″ android:src=”@drawable/p2″
android:layout_width=”wrap_content” android:layout_height=”wrap_content”></ImageView><ImageView android:id=”@+id/ImageView03″ android:src=”@drawable/p3″
android:layout_width=”wrap_content” android:layout_height=”wrap_content”></ImageView></FrameLayout>
<?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:gravity=”center_horizontal”
>
<TextView
android:layout_width=”fill_parent”
android:layout_height=”wrap_content”
android:text=”给小宝宝起个名字:”
android:textSize=”20px”
android:textColor=”#0ff”
android:background=”#333″/>
<TextView
android:layout_width=”wrap_content”
android:layout_height=”wrap_content”
android:text=”遥遥是男孩的小名”
android:textSize=”20px”
android:textColor=”#0f0″
android:background=”#eee”
android:layout_weight=”3″
/>
<TextView
android:layout_width=”wrap_content”
android:layout_height=”wrap_content”
android:text=”瑶瑶是女孩的小名”
android:textColor=”#00f”
android:textSize=”20px”
android:background=”#ccc”
android:layout_weight=”1″
/><TextView
android:layout_width=”fill_parent”
android:layout_height=”wrap_content”
android:text=”海因是男孩的大名”
android:textColor=”#f33″
android:textSize=”20px”
android:background=”#888″
android:layout_weight=”1″
/>
<TextView
android:layout_width=”fill_parent”
android:layout_height=”wrap_content”
android:text=”海音是女孩的大名”
android:textColor=”#ff3″
android:textSize=”20px”
android:background=”#333″
android:layout_weight=”1″
/>
</LinearLayout>