I have a basic form with some Textviews
on the left and Edittexts
on the right.
When I try to type in portrait mode everything looks fine.
However, when trying to type in landscape mode, I can't see the Textview
beside the Edittext
.
Here is my xml code
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal">
<TextView
android:text="Name:"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="22dp"
android:layout_marginTop="20dp"
android:id="@+id/textView_name"
android:layout_below="@+id/editText_pass"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true" />
<EditText
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:inputType="textPersonName"
android:textSize="22dp"
android:ems="10"
android:layout_marginTop="10dp"
android:layout_alignTop="@+id/textView_name"
android:layout_alignLeft="@+id/editText_pass"
android:layout_alignStart="@+id/editText_pass"
android:id="@+id/editText_name" />
</LinearLayout>
</LinearLayout>
</ScrollView>
Edit: The question is indeed a duplicate of Disabling the fullscreen editing view for soft keyboard input in landscape?
The title could also be considered a bit vague.
However, both answers given produced the desired result (though with limitations to the view), so I leave up to a moderator to decide if the question is worth deleting or not.