I have this EditText
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical" >
    <EditText
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:inputType="textMultiLine"
        android:lines="5"
        android:singleLine="false"
        android:text="@string/app_name" />
</LinearLayout>
My problem is that typing starts at the middle of the EditText.
My question is how to start typing at the top left of the EditText?
Try android:gravity="top"
so your code will be :
<EditText
     android:layout_width="fill_parent"
     android:layout_height="wrap_content"
     android:gravity="top"
     android:inputType="textMultiLine"
     android:lines="5"
     android:singleLine="false"
     android:text="@string/app_name" />
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With