title: Layout pushing views down the screen
body: <p>So, I have a ImageView inside a FrameLayout. I need it this way. I feel like the issue here is the image and it's size itself. The layout the image is pushes further down all the other views on my screen leaving considerable empty space that's supposed to be from the layout.</p>
  
  <p>I found that hard coding the height value let's me minimize this issue. If the height was wrap_content the image would reach up to the same point but the blank space that is supposed to be from the layout extends to extreme lengths.</p>
  
  <p>So I want to know if this is a image size (or resolution?) problem (which seems to be) or anything else, and if there is a better solution than hardcoding the layout height. Thanks in advance.</p>
  
  <p>Here is the code:</p>
  
  <pre><code>&lt;LinearLayout
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:orientation="vertical"&gt;
  
      &lt;FrameLayout
          android:layout_width="match_parent"
          android:layout_height="700dp"&gt;
  
          &lt;ImageView
              android:id="@+id/image_header"
              android:layout_width="match_parent"
              android:layout_height="wrap_content"
              android:scaleType="fitStart"
              android:src="@drawable/me_and_gundam" /&gt;
  
          &lt;View
              android:layout_width="match_parent"
              android:layout_height="wrap_content"
              android:background="@drawable/gradient" /&gt;
      &lt;/FrameLayout&gt;
  
  
      &lt;TextView
          android:fitsSystemWindows="true"
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:layout_marginBottom="16dp"
          android:text="My Nanodegree Apps!"
          android:textAlignment="center"
          android:textSize="24sp" /&gt;
  </code></pre>
  
  <p>And here is what it looks like:</p>
  
  <p><a href="https://i.stack.imgur.com/zTbzD.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zTbzD.png" alt="enter image description here"></a></p>