title: listview recycling strange empty space
body: <p>I have a similar problem to the one in this question: <a href="https://stackoverflow.com/questions/5766907/listview-and-rows-recycling-problem">ListView and rows recycling problem</a></p>
  
  <p>Above is solved. but same solution does not work for me.</p>
  
  <p>I have a listview consisting of textviews. Each textview can contain variable number of images. I am getting images with html.imagegetter and I am using recycling in getview method of list adapter.</p>
  
  <p>If there is one or more images in a textview, it will have a height to be able to fit its content. When this textview is recycled and new content does not fill the height defined before, then empty space will appear. </p>
  
  <p>The problem is that I can't restore the textview height in getview because I dont know what height the next list item will have.</p>
  
  <p>this is my getview:</p>
  
  <pre><code>public View getView(int position, View convertView, ViewGroup parent) {
      final ViewHolder holder;
  
      View rowView = convertView;
      if (rowView == null) {
          LayoutInflater inflater = context.getLayoutInflater();
          rowView = inflater.inflate(resource, parent, false);
          holder = new ViewHolder();
          holder.imgAvatar = (ImageView) rowView.findViewById(R.id.imgAvatar);
          holder.textDetails = (TextView) rowView.findViewById(R.id.textDetails);
          holder.textPostTime = (TextView) rowView.findViewById(R.id.textPostTime);
          holder.textPost = (TextView) rowView.findViewById(R.id.textPost);
          rowView.setTag(holder);
      } else {
          holder = (ViewHolder) rowView.getTag();
      }
  
      holder.textDetails.setText(details.toString());
      holder.textPostTime.setText(x.postTime);
      holder.textPost.setText(Html.fromHtml(x.postBody, new URLImageGetter(holder.textPost, context), null, context));
      return rowView;
  }
  </code></pre>
  
  <p>this is row layout:</p>
  
  <pre><code>&lt;TextView
      android:ellipsize="none"
      android:autoLink="web"
      android:textColor="#000000"
      android:id="@+id/textPost"
      android:layout_width="match_parent"
      android:layout_height="wrap_content" /&gt;
  </code></pre>
  
  <p><strong>THE PROBLEM:</strong> The listview recycling mechanism can't calculate the new height for used views according to its new contents.
  Without recycling, it is too slow.</p>