Mam 1 układ liniowy, w środku mam 1 układ tabeli, a wewnątrz mam 2 wiersze tabeli i wewnątrz każdego wiersza mam 2 textviews. Każdy textwiev ma tło w pliku 9.png.format, aby wyglądać jak przycisk.Jak zrobić TextView w tym samym rozmiarze, niezależnie od tekstów wewnątrz
W jaki sposób sprawić, że te odsłonówki będą miały taki sam rozmiar, jak w przypadku tekstów, dzięki czemu obrazy tła będą takie same?
To właśnie allready wykonany:
<LinearLayout android:layout_height="fill_parent"
android:gravity="bottom"
android:layout_width="fill_parent"
android:layout_weight="2">
<TableLayout android:layout_height="wrap_content"
android:layout_width="fill_parent"
android:stretchColumns="0 1">
<TableRow android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:padding="2dp">
<TextView android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@drawable/answer_small_off"
android:layout_weight="1"
android:text="@string/hello"
android:gravity="center"
android:id="@+id/main_text_answer1"
android:lines="3"
android:maxLines="3"
android:textSize="10dp" android:minLines="3" android:minEms="20" android:maxEms="20" android:ems="20">
</TextView>
<TextView android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@drawable/answer_small_off"
android:layout_weight="1"
android:text="@string/hello"
android:gravity="center"
android:id="@+id/main_text_answer2"
android:lines="3"
android:maxLines="3"
android:textSize="10dp">
</TextView>
</TableRow>
<TableRow android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:padding="2dp">
<TextView android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@drawable/answer_small_off"
android:layout_weight="1"
android:text="@string/hello"
android:gravity="center"
android:id="@+id/main_text_answer3"
android:lines="3"
android:maxLines="3"
android:textSize="10dp">
</TextView>
<TextView android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@drawable/answer_small_off"
android:layout_weight="1"
android:text="@string/hello"
android:gravity="center"
android:id="@+id/main_text_answer4"
android:lines="3"
android:maxLines="3"
android:textSize="10dp">
</TextView>
</TableRow>
</TableLayout>
</LinearLayout>
btw. to tylko część ekranu, ale reszta nie jest ważna myślę
CRO, wydaje mi się, że miał podobny przypadek i rozwiązany w moim [Odpowiedź] (http://stackoverflow.com/questions/7698397/textview-height-increase-when-decreasing-font-size/7707447#7707447) –