DieGoldeneMitte
Dauergast
- 262
Hallo,
ich möchte gerne das folgende Layout generieren: Unten soll ein einzeiliges Textfeld sein, darüber ein Label und darüber ein TextView (in einem ScrollView), der den gesamten Platz einnimmt:
Leider klappt das nicht, das Label und das Textfeld werden nicht dargestellt. Wenn ich den Scrollview mit der Höhe wrap_content belege. Wird der EditText aufgeblasen.
Was mache ich falsch?
ich möchte gerne das folgende Layout generieren: Unten soll ein einzeiliges Textfeld sein, darüber ein Label und darüber ein TextView (in einem ScrollView), der den gesamten Platz einnimmt:
Code:
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<ScrollView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:id="@+id/scroll"
android:layout_alignParentTop="true"
>
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content" <-- fill_parent ändert nix
android:id="@+id/info"
/>
</ScrollView>
<TextView
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:text="Datum:"
android:id="@+id/lbl"
android:layout_below="@+id/scroll"
/>
<EditText
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:id="@+id/datum"
android:layout_below="@+id/lbl"
android:layout_alignParentBottom="true"
android:text="yyyy.mm.dd"
android:lines="1"
/>
</RelativeLayout>
Was mache ich falsch?