title: Android layout_weight for overflowing linear layout height
body: <p>My scenario is like this:
  I have a linear layout in which I have one Image view and about 10 editTexts. I want the ImageView to be half of the size of the screen height and remaining edit texts to occupy rest of the space and scroll if required.</p>
  
  <p>I wrapped my linear layout inside a scroll view and assigned the weight sum of 10 to the linear layout. Then assigned layout_weight of 5 to the imageView and rest of all were left with layout_height of wrap_content. But this hides the imageview totally. How should I get the kind of layout I want?</p>
  
  <p><strong>My layout.xml:</strong>
      </p>
  
  <pre><code>&lt;ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
              android:layout_width="fill_parent"
              android:layout_height="fill_parent"
              android:fillViewport="true"
          &gt;
      &lt;LinearLayout
              android:orientation="vertical"
              android:layout_width="fill_parent"
              android:layout_height="wrap_content"
              &gt;
          &lt;ImageView
                  android:layout_width="fill_parent"
                  android:layout_height="10dp"
                  android:id="@+id/imageView" android:layout_gravity="center" android:background="#bcddff"
                  /&gt;
          &lt;Button
                  android:layout_width="wrap_content"
                  android:layout_height="wrap_content"
                  android:text="Launch Camera"
                  android:id="@+id/button" android:layout_gravity="center"/&gt;
          &lt;EditText
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:hint="Enter Name"
                  android:id="@+id/name" android:layout_gravity="center"/&gt;
          &lt;EditText
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:hint="Mobile No."
                  android:id="@+id/mobile" android:layout_gravity="center" android:inputType="phone"/&gt;
          &lt;EditText
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:hint="Whatsapp No."
                  android:id="@+id/whatsapp" android:layout_gravity="center" android:inputType="phone"/&gt;
          &lt;EditText
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:hint="Email"
                  android:id="@+id/email" android:layout_gravity="center"/&gt;
          &lt;EditText
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:hint="Age"
                  android:id="@+id/age" android:layout_gravity="center"/&gt;
          &lt;EditText
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:hint="Address"
                  android:id="@+id/address" android:layout_gravity="center"/&gt;
          &lt;EditText
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:hint="City"
                  android:id="@+id/city" android:layout_gravity="center"/&gt;
          &lt;EditText
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:hint="State"
                  android:id="@+id/state" android:layout_gravity="center"/&gt;
          &lt;EditText
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:hint="Gender(M/F)"
                  android:id="@+id/gender" android:layout_gravity="center"/&gt;
          &lt;EditText
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:hint="Remarks"
                  android:id="@+id/remarks" android:layout_gravity="center"/&gt;
      &lt;/LinearLayout&gt;
  &lt;/ScrollView&gt;
  </code></pre>