/ / Wie man einen Knopf zwischen zwei Layoutanschlusspunkten zeigt? [Duplikat] - Android, Layout

Wie zeige ich einen Button zwischen zwei Layout-Verbindungspunkten an? [Duplikat] - Android, Layout

Ich habe dieselbe Frage gestellt und der Frage-Link lautet: Wie man eine Knopfhälfte auf einem Layout und die Hälfte auf einem anderen Layout in Android zeigt? Ich habe keine Lösung für dieses Problem gefunden. Ich möchte dieses Layout für alle Geräte ansprechen. Jeder kann mir helfen, dieses Problem loszuwerden.

Antworten:

2 für die Antwort № 1

Probieren Sie das ..! Lassen Sie mich wissen, wenn es hilft.

 <?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent" >

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
>

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:background="#d67070">

<RelativeLayout
android:id="@+id/relative_layout_top"
android:layout_width="match_parent"
android:layout_height="wrap_content"
>

</RelativeLayout>
</LinearLayout>


<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:background="#70a7d6">

<RelativeLayout
android:id="@+id/relative_layout_bottom"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/relative_layout_top"
>
</RelativeLayout>

</LinearLayout>

</LinearLayout>

<Button
android:id="@+id/bt_atoz"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
android:text="Button"
android:textColor="#000000"
android:layout_marginRight="10dp"
android:background="#ffffff"
/>

</RelativeLayout>