Отрегулируйте размер TableLayout по размеру экрана - PullRequest
0 голосов
/ 26 сентября 2019

Я ищу, как настроить размер моего TableLayout на экран

enter image description here

Последнее текстовое представление не отображается на экране,как я хотел бы Вот код:

<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_column="2"
    android:shrinkColumns="*">
    <TableRow
        android:layout_width="wrap_content"
        android:layout_height="wrap_content">
        <LinearLayout
            android:orientation="vertical"
            android:padding="5dp"
            android:layout_margin="5dp"
            android:background="@drawable/shadow">
            <ImageView
                android:id="@+id/accueil_first_placeholder"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:layout_gravity="center"
                android:adjustViewBounds="true"
                android:scaleType="fitCenter"
                android:src="@drawable/placeholder" />

            <TextView
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:gravity="center"
                android:text="placeholder"
                android:textSize="28sp"
                app:autoSizeTextType="uniform"
                app:autoSizeMinTextSize="12sp"
                app:autoSizeMaxTextSize="36sp"/>
        </LinearLayout>
        <!--Other Linear Layout(Same)-->
    </TableRow>
    <!--Other TableRow(same)-->
</TableLayout>

Спасибо: D

PS: он отображается во фрагменте

1 Ответ

0 голосов
/ 28 сентября 2019

Попробуйте добавить отступы 0 к макету таблицы

...