Great, it worked! Thanks a lot!

On Feb 4, 12:54 am, Dianne Hackborn <[email protected]> wrote:
> You should be able to either connect the left and right edges of the text
> view to the right of its container and left of the inner linear layout, or
> put it all in a linear layout and give the text view a layout_width of 0px
> and layout_weight of 1.
>
>
>
> On Tue, Feb 3, 2009 at 1:11 PM, Al <[email protected]> wrote:
>
> > I have but with the LinearLayout, the images don't show up, the text
> > forces it out of the visible screen area.
>
> > On Feb 3, 7:44 pm, Mark Roberts <[email protected]> wrote:
> > > Have you tried changing the RelativeLayout to a LinearLayout?
>
> > > On Feb 3, 2:07 pm, Al <[email protected]> wrote:
>
> > > > In my listview, I'm trying to make the list row show 2 imageviews as
> > > > well as the textview which holds the data. The layout of a single row
> > > > is like this: [textview | img1| img2]. The problem is the text inside
> > > > the textview overlaps the imageviews. I've tried various layout
> > > > options but can't seem to get it right. This is my layout file:
>
> > > > <?xml version="1.0" encoding="utf-8"?>
> > > > <RelativeLayout
> > > >         android:layout_width="fill_parent"
> > > >         android:layout_height="wrap_content"
> > > >         android:padding="5px"
> > > >         xmlns:android="http://schemas.android.com/apk/res/android";
>
> > > >         <TextView
> > > >                 android:id="@+id/label"
> > > >                 android:layout_width="wrap_content"
> > > >                 android:layout_height="wrap_content"
> > > >             android:paddingLeft="2dip"
> > > >             android:textColor="#eee"
>
> > > >         />
>
> > > >         <LinearLayout
> > > >                         android:layout_width="wrap_content"
> > > >                         android:layout_height="wrap_content"
> > > >                         android:layout_alignParentRight="true"
>
> > > >                 <ImageView
> > > >                                 android:id="@+id/alert"
> > > >                                 android:layout_width="wrap_content"
> > > >                                 android:layout_height="wrap_content"
>
> > android:src="@drawable/stat_notify_alarm"
> > > >                                 android:tag="alarm"
> > > >                         />
>
> > > >                         <ImageView
> > > >                                 android:id="@+id/delete"
> > > >                                 android:layout_width="wrap_content"
> > > >                                 android:layout_height="wrap_content"
>
> > android:src="@android:drawable/ic_delete"
> > > >                                 android:layout_toRightOf="@id/alert"
> > > >                                 android:paddingLeft="10px"
> > > >                                 android:tag="del"
> > > >                         />
>
> > > >         </LinearLayout>
>
> > > > </RelativeLayout>
>
> > > > and this is the code I'm using for generating the list:
>
> > > > setListAdapter(new ArrayAdapter<String>(this, R.layout.favs,
> > > > R.id.label, shows);
>
> > > > Thanks.
>
> --
> Dianne Hackborn
> Android framework engineer
> [email protected]
>
> Note: please don't send private questions to me, as I don't have time to
> provide private support.  All such questions should be posted on public
> forums, where I and others can see and answer them.
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to