title: Android - Layout not in uniform
body: <p>I have a horizontal list of images in my android application. But the problem is some of the images seems to not follow the layout I've defined in my xml. Like this: </p>
  
  <p><img src="https://i.stack.imgur.com/cQI0z.png" alt="suppose to be it should be in uniform distance"></p>
  
  <p>my layouts look like this:
  <strong>mainlayout.xml</strong></p>
  
  <pre><code>&lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:background="@drawable/back_shop_list"
      android:orientation="horizontal"&gt;
  
    &lt;com.devsmart.android.ui.HorizontalListView
        android:id="@+id/shop_hlist_view" 
        android:layout_width="match_parent" 
        android:layout_height="match_parent"
        android:paddingLeft="5dp"
        android:paddingRight="5dp"
        android:scrollX="1dp"
        android:scrollY="1dp"
        android:overScrollMode="always" &gt;  
    &lt;/com.devsmart.android.ui.HorizontalListView&gt;
  
  &lt;/LinearLayout&gt;
  </code></pre>
  
  <p>then my <strong>listlayout.xml</strong></p>
  
  <pre><code> &lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
  android:layout_width="match_parent"
  android:layout_height="match_parent"
  android:orientation="vertical"
  android:translationY="200dp" &gt;  
  
      &lt;FrameLayout 
          android:id="@+id/framelayout" 
          android:layout_height="wrap_content" 
          android:layout_width="wrap_content" 
          android:layout_gravity="center"
          android:orientation="vertical"
          android:paddingLeft="8dp"
          android:paddingRight="8dp" &gt;
  
          &lt;ImageView
              android:id="@+id/img"    
              android:clickable="true"
              android:adjustViewBounds="true"
              android:layout_width="360dp"
              android:layout_height="360dp" /&gt;  
  
          &lt;ProgressBar
              android:id="@+id/img_progress"
              style="?android:attr/progressBarStyleLarge"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:indeterminate="true"
              android:translationY="150dp"
              android:translationX="140dp" /&gt; 
  
      &lt;/FrameLayout&gt;
  
      &lt;TextView
          android:id="@+id/labelText"
          android:layout_width="fill_parent"
          android:layout_height="wrap_content"
          android:translationX="10dp"
          android:textColor="#dc6800"
          android:textSize="16sp"
          android:textStyle="bold" /&gt;
      &lt;!-- Description label --&gt;
      &lt;TextView
          android:id="@+id/desc"
          android:layout_width="fill_parent"
          android:layout_height="wrap_content"
          android:translationX="10dp"
          android:textColor="#acacac"
          android:paddingBottom="2dip"&gt;
      &lt;/TextView&gt;
  
  &lt;/LinearLayout&gt;
  </code></pre>
  
  <p>My guess is that the size of my image is lesser than what my ImageView layout_width and height. Or I dont really know what causes this problem.
  But any help will do, please. Thanks.</p>
  
  <p>EDIT: What I really wanted is that if the image is like image 4 and image 5, it should not have those spaces. I've tried getting the size of the image from my ImageLoader then set the layout parameters height and width in there while images are loaded. But it looked worse. 
  Are there other ways in which i can dynamically adjust my ImageView if ever the images are like image 4 and 5? </p>