This has been fixed in later versions of the SDK. On Mon, Jun 23, 2008 at 7:51 PM, Hsun-Cheng Hu <[EMAIL PROTECTED]> wrote: > > Hi all, > > I am new to Android SDK. When I apply the follow main.xml to android, > the children of linear layout don't occupy the whole space, it should > be 320. I had tried to dump the width of each children the width of > them are: 107, 106, and 106. The total width they consumed are 319 > instead of 320. This looks like a "round" problem while calculating > the layout. > > Is there any way to fix it?? > > <?xml version="1.0" encoding="utf-8"?> > <LinearLayout xmlns:android="http://schemas.android.com/apk/res/ > android" > android:orientation="vertical" android:layout_width="fill_parent" > android:layout_height="fill_parent"> > <LinearLayout > xmlns:android="http://schemas.android.com/apk/res/android" > android:orientation="horizontal" > android:layout_width="fill_parent" > android:layout_height="wrap_content"> > > <TextView > xmlns:android="http://schemas.android.com/apk/res/android" > android:layout_weight="0.34" > android:background="#3FFFFFFF" > android:text="Item 1" > android:layout_height="wrap_content" > android:layout_width="wrap_content"/> > <TextView > xmlns:android="http://schemas.android.com/apk/res/android" > android:layout_weight="0.33" > android:background="#3FFFFF00" > android:text="Item 1" > android:layout_height="wrap_content" > android:layout_width="wrap_content"/> > <TextView > xmlns:android="http://schemas.android.com/apk/res/android" > android:layout_weight="0.33" > android:background="#3FFF0000" > android:text="Item 1" > android:layout_height="wrap_content" > android:layout_width="wrap_content"/> > </LinearLayout> > </LinearLayout> > > > >
-- Romain Guy www.curious-creature.org --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~----------~----~----~----~------~----~------~--~---