Моя проблема в том, что я хочу повернуть TextView
внутри FrameLayout
, но я не могу повернуть FrameLayout
.
Когда я поворачиваю на 90 градусов TextView
, это не соответствует родителю!
Но мне нужно, чтобы текст заполнил весь родитель!
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/FLback"
android:layout_width="match_parent"
android:layout_height="match_parent">
<FrameLayout
android:id="@+id/FLitem"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_margin="1dp">
<TextView
android:id="@+id/TVitem"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_margin="4dp"
android:background="@color/colorPrimaryDark"
android:gravity="center"
android:rotation="90"
android:text="TEXT"
android:textColor="@android:color/black"
android:textSize="10sp" />
</FrameLayout>
</FrameLayout>
Вот пример проблемы:
https://imgur.com/mQSvANK
Проблема в одном кадре!
Спасибо!