[android-developers] Re: gravity vs. layout_gravity? I'm lost.

2009-05-14 Thread Romain Guy
Hi, Well, first of all RelativeLayout ignores layout_gravity. Then you need to know that gravity means apply gravity to the content of this view whereas layout_gravity means apply gravity to this view within its parent. So on a TextView, gravity will align the text within the bounds of the

[android-developers] Re: gravity vs. layout_gravity? I'm lost.

2009-05-14 Thread Streets Of Boston
As a side-note: I think the TextView's (and EditText) 'gravity' should have been called 'alignment'. It's called that way in most UI's. :=) On May 14, 10:54 am, Romain Guy romain...@google.com wrote: Hi, Well, first of all RelativeLayout ignores layout_gravity. Then you need to know that

[android-developers] Re: gravity vs. layout_gravity? I'm lost.

2009-05-14 Thread Romain Guy
It used to be called something like that but we decided to unify the names across all widgets. On Thu, May 14, 2009 at 7:58 AM, Streets Of Boston flyingdutc...@gmail.com wrote: As a side-note: I think the TextView's (and EditText) 'gravity' should have been called 'alignment'. It's called

[android-developers] Re: gravity vs. layout_gravity? I'm lost.

2009-05-14 Thread matthias
Guys, thanks for clearing up! I'll file a bug against the documentation then, because there it says: public static final int gravity Specifies how to place an object, both its x and y axis, within a larger containing object. Which is true for layout_gravity, but not gravity. Apart from that,

[android-developers] Re: gravity vs. layout_gravity? I'm lost.

2009-05-14 Thread Dianne Hackborn
On Thu, May 14, 2009 at 9:15 AM, matthias m.kaepp...@googlemail.com wrote: It would be great though if things like these (i.e. that RelativeLayout ignores layout_gravity) would appear somewhere in the documentation. It's not immediately apparent to people why for some layouts the gravity is

[android-developers] Re: gravity vs. layout_gravity? I'm lost.

2009-05-14 Thread Romain Guy
It would be great though if things like these (i.e. that RelativeLayout ignores layout_gravity) would appear somewhere in the documentation. It's not immediately apparent to people why for some layouts the gravity is simply ignored, and for others it's not. Well no, it's an assumption you