title: Android layout - alignment issue with ImageView
body: <p>I'm trying to put an image at the top left of a <code>LinearLayout</code>, but with the image border and padding taking up the whole of the width of the window.</p>
  
  <p>If I try the XML below, I get my image with its border and a white background across the whole width of the page, <em>except</em> that the image ends up <strong>centered</strong>, and doesn't move to the left.</p>
  
  <pre><code>&lt;ImageView
      android:layout_width="fill_parent"
      android:layout_height="wrap_content"
      android:layout_gravity="left"
      android:src="@drawable/banner"
      android:background="@android:color/white"
      android:padding="@dimen/d_8px"
  /&gt;
  </code></pre>
  
  <p>Is there some attribute that I've not yet discovered that forces the image to be left aligned within the <code>ImageView</code> when the <code>layout_width</code> is set to <code>fill_parent</code>?</p>
  
  <p>In the meantime, I've worked around this by dropping the <code>ImageView</code> inside another <code>LinearLayout</code> and dropping an empty <code>TextView</code> to its right that takes up the rest of the horizontal space.</p>