I am having trouble getting a RelativeLayout to work within a ListView. If I change the layout to linear etc. I see it behave as I would expect but the RelativeLayout is scrunching everything up into overlapping space. Now my uneducated guess is that it is trying to cram everything into on row. I thought it would expand that row but perhaps not or that is not the problem.
Note my code has been abbreviated for space.
Anyway in my Parent XML:
<LinearLayout ..._width="fill_parent" ..._height="fill_parent" ...orientation="vertical" >
<ListView ...layout_width="fill_parent" ...layout_height="fill_parent" />
</LinearLayout>
So my thought was that this would fill the device screen and in the GraphicalLayout view in Eclipse it appears that it does.
My "row" definition for the ListView is this:
<RelativeLayout width="fill_parent" height="fill_parent" >
<ImageView
android:layout_width="60dp"
android:layout_height="30dp"
android:layout_alignParentLeft="true"
android:layout_marginTop="15dp"
android:layout_marginLeft="5dp" />
.....
</RelativeLayout>
As mentioned I thought this would fill all available space but it seems to only fill some sort of "default" row height?
What am I missing?
I ended up overriding the getView of the ArrayAdapter and then setting the height and width to the dynamically determined screen size
…snip….
….snip….