I applied a gradient drawable resource as a background for a view.
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<corners android:radius="10dp" />
<gradient
android:startColor="#cf2aff"
android:endColor="#5409ff"
android:type="linear" />
</shape>
In devices with Android version < 10 it is shown as expected:
But in devices with Android 10 it is rotated 90 degrees:
Did anyone have the same problem and know how to fix it?

