你讓我用你的繪圖感謝笑:)順便說一句,你可以做到這一點與的TextView和一個按鈕如下圖所示:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<TextView
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:drawableLeft="@drawable/ic_launcher"
android:text="dummy text 1 \n dummy text 2"
android:gravity="center"/>
<Button
android:id="@+id/dummyButton"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="dummy" />
</LinearLayout>
或者更復雜的東西:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<LinearLayout
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:orientation="horizontal" >
<ImageView
android:id="@+id/dummyImageView"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:background="#58FA58"/>
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:orientation="vertical" >
<TextView
android:id="@+id/myDummyTextView1"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:background="#DF013A" />
<TextView
android:id="@+id/myDummyTextView2"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:background="#2EFEF7" />
</LinearLayout>
</LinearLayout>
<Button
android:id="@+id/dummyButton"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="dummy"/>
</LinearLayout>
或者與relativeLayout更高效。這將是另一個問題,read more about it。但是如果它足夠適合你,我更喜歡第一個。
幫我請怎麼樣chnage佈局像圖像? –