I have defined the 2 EditTexts in a LinearLayout:
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:baselineAligned="false"
android:minHeight="120dp"
android:orientation="vertical">
<EditText
android:id="@+id/eT_eingabe"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginStart="20dp"
android:layout_marginTop="5sp"
android:width="100dp"
android:background="#00464646"
android:inputType="textNoSuggestions"
android:singleLine="true"
android:maxLines="1"
android:minHeight="55sp"
app:autoSizeMaxTextSize="100sp"
app:autoSizeMinTextSize="12sp"
app:autoSizeStepGranularity="1sp"
/>
<EditText
android:id="@+id/eT_ausgabe"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginStart="20dp"
android:layout_marginTop="5sp"
android:width="100dp"
android:background="#00464646"
android:inputType="textNoSuggestions"
android:singleLine="true"
android:maxLines="1"
android:minHeight="55sp"
app:autoSizeMaxTextSize="100sp"
app:autoSizeMinTextSize="12sp"
app:autoSizeStepGranularity="1sp" />
</LinearLayout>
</LinearLayout>
In code I only change their typeface and textcolor:
view.setTextColor(tc);
view.setTypeface(tf);
Both have the identical code (except the id) and should only have one line and scroll vertically. eT_eingabe does so. eT_ausgabe always has one line, but on a device with API 21 (Huawei Honor 7, real device) still does allow to scroll vertically (The user can move the text slightly up and down). On API 24 (Pixel 3, emulator) everything works fine.
My question is: how can I prevent the edittext eT_ausgabe from scrolling up and down?