I think android:layout_below is only for relative layout...but I may try
that instead. :-/

Nothing else seems to be working here...

Larry




On Wed, Mar 20, 2013 at 10:11 AM, John Masseria <[email protected]>wrote:

> Have you considered trying to explicitly force the order of the items in
> the LinearLayout by using android:layout_below to specify the order of the
> items?
>
> Please forgive the newbie answer my part if there's an obvious reason to
> not do this.
> John
>
>
> On Wednesday, March 20, 2013 11:53:03 AM UTC-4, Larry Meadors wrote:
>>
>> I'm making a grid of items that has an image and two text elements under
>> it.
>>
>> I want all three elements centered horizontally, and the image to be
>> right above the text.
>>
>> For some reason, the image is centered vertically and the text is at the
>> bottom.
>>
>> Here's a screen shot to make that clearer:
>>
>> https://www.evernote.com/**shard/s138/sh/6cdb585f-d523-**
>> 47a5-a3a3-184124719e01/**ed424d6929bdbf4abd9c36e2ce4a43**90<https://www.evernote.com/shard/s138/sh/6cdb585f-d523-47a5-a3a3-184124719e01/ed424d6929bdbf4abd9c36e2ce4a4390>
>>
>> I've tried everything I can think of...
>>
>> This is the grid view:
>>
>> <GridView
>>   android:id="@+id/content_list_**grid_view"
>>   android:columnWidth="90dp"
>>   android:numColumns="4"
>>   android:verticalSpacing="5dp"
>>   android:horizontalSpacing="**10dp"
>>   android:stretchMode="**columnWidth"
>>   android:layout_height="wrap_**content"
>>   android:layout_width="fill_**parent"
>>   android:padding="5dp"
>>   />
>>
>> This is my item:
>>
>> <?xml version="1.0" encoding="utf-8"?>
>> <LinearLayout 
>> xmlns:android="http://schemas.**android.com/apk/res/android<http://schemas.android.com/apk/res/android>
>> "
>>   android:layout_width="fill_**parent"
>>   android:layout_height="140dp"
>>   android:orientation="vertical"
>>   android:gravity="bottom|**center_horizontal">
>>
>>   <ImageView
>>     android:id="@+id/thumbnail_**image"
>>     android:background="#40ff8080"
>>     android:layout_width="wrap_**content"
>>     android:layout_height="110dp"
>>     android:layout_gravity="**center_horizontal|bottom"
>>     android:src="@drawable/image_**not_available_large"
>>     android:contentDescription="@**string/thumbnail_image" />
>>
>>   <TextView
>>     android:id="@+id/title_name"
>>     android:textColor="@color/**white_color"
>>     android:layout_width="wrap_**content"
>>      android:layout_height="wrap_**content"
>>     android:singleLine="true"
>>     android:gravity="center_**horizontal"
>>     style="@style/normal_label" />
>>
>>   <TextView
>>   android:id="@+id/title_author"
>>   android:textColor="@color/**light_gray_color"
>>   android:layout_width="wrap_**content"
>>    android:layout_height="wrap_**content"
>>   android:singleLine="true"
>>   android:gravity="center_**horizontal"
>>   style="@style/normal_label" />
>>
>> </LinearLayout>
>>
>>
>>

-- 
-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to