Android logic behind weightsum
<p>So I have this XML code:</p>

<pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;

&lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
android:id="@+id/linearLayoutOuter"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:weightSum="3.0"
&gt;

&lt;LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:layout_weight="1.0"
&gt;
&lt;Gallery
 android:id="@+id/galleryMain"
 android:layout_width="match_parent"
 android:layout_height="90dp"&gt;
&lt;/Gallery&gt;
&lt;LinearLayout
 android:id="@+id/linearLayoutInner"
 android:layout_width="match_parent"
 android:layout_height="match_parent"
 android:background="@layout/gallery_image_background"
/&gt;
&lt;/LinearLayout&gt;


&lt;TextView
android:id="@+id/galleryTextView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="2.0"
&gt;
&lt;/TextView&gt;

&lt;/LinearLayout&gt;
</code></pre>

<p>Currently it sizes correctly, but I don't think that can be right.</p>

<p>The LinearLayout that gets 1.0 out of 3.0 possible weight takes about 2/3 space.
The TextView that gets 2.0 out of 3.0 possible wight takes about 1/3 space.</p>

<p>Is above really how it is meant to work? It sizes like I want, but... Not sure I understand the logic behind it.</p>
