I tried all afternoon to get the minHeight attribute to work.

What I want is the linearMe layout to:

  • Stretch from the bottom of the screen to the bottom of the ListView when the ListView has just a few elements.
  • I need to be able to fill the linearMe layout with a picture for example.

As the ListView gets bigger I want the linearMe layout to:

  • Have a fixed height (while being at the bottom of the screen) and the ListView to allow scrolling.

My problem is that the the linearMe layout is smaller and smaller as there is more elements in the ListView. And when there is enough element for the listView to fill the screen, the linearMe layout is just gone. It looks like the minHeight is useless in this case.

<LinearLayout
    android:layout_width="match_parent"
    android:orientation="vertical"
    android:layout_height="match_parent" >

<ListView
    android:id="@+id/list"
    android:layout_width="match_parent"
    android:layout_height="wrap_content" />

<LinearLayout
    android:id="@+id/linearMe"
    android:layout_width="match_parent"
    android:layout_height="0dp"
    android:layout_weight="1"
    android:background="#FF0000"
    android:minHeight="200dp" />

</LinearLayout>

enter image description hereenter image description here

I hope you can help me out ! :)

Edit
Report