I am using a ListView inside a Fragment. The items of my ListView are dynamically loaded using a Custom Adapter.
I notice that when I try to set the Font size of my items something large ( like 28dp ) , the listview will still render but will get cut off at the end so the last item will not be visible.
Here is the ListView
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:id="@+id/layoutList"
>
<ListView
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:id="@+id/listView"
android:stackFromBottom="true"
/>
</LinearLayout>
and the item row
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="80dp"
android:orientation="horizontal" >
<TextView
android:id="@+id/textView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:text="TextView"
android:layout_alignParentTop="true"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="0"
android:id="@+id/txtHours"
android:layout_alignParentTop="true"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"
android:textSize="28dp" />
</RelativeLayout>
is there anything wrong with my implementation ?