我厭倦了試圖解決這個問題,但沒有運氣。MapView正在佈局整個空間
我有佈局組成的地圖視圖,搜索欄和EditText。
問題mapview正在佔用整個空間,所以EditText文本沒有出現。
我試圖玩重量值,但沒有運氣。
感謝您的幫助。
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:a="http://schemas.android.com/apk/res/android"
a:layout_width="fill_parent"
a:layout_height="fill_parent" >
<com.google.android.maps.MapView
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/mapview"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:apiKey="somekey"
android:clickable="true"
android:layout_weight="0"
a:layout_alignParentTop="true"
/>
<SeekBar
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/seekBar1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_marginTop="26dp"
a:paddingLeft="10dip"
a:paddingRight="10dip"
a:paddingTop="30dip"
android:max="100" >
</SeekBar>
<EditText
a:id="@+id/smsBody"
a:layout_width="0dip"
a:layout_height="wrap_content"
a:layout_weight="1.0"
a:autoText="true"
a:capitalize="sentences"
a:hint="@string/sms_enter_message"
a:imeOptions="actionSend|flagNoEnterAction"
a:inputType="textShortMessage|textAutoCorrect|textCapSentences|textMultiLine"
a:maxLines="10"
a:nextFocusRight="@+id/send_button"
a:layout_alignParentBottom="true" />
</RelativeLayout>
只是好奇 - 'a:something =「something_else」'真的適合你嗎?不應該是'android:...' – cyborg86pl 2012-07-22 22:16:40
你也指向不存在的元素:'「@ + id/send_button」 – cyborg86pl 2012-07-22 22:18:44
@ cyborg86pl:是的,實際上,當我嘗試使用android: soemthing =「somethingelse」它不起作用。我不知道爲什麼 – user836026 2012-07-22 23:23:19