In gridview , i want to set an image and a name to that image?
<p>I successfully set the image from the adapter. I want to set the name below the image. How to do this. The names are stored in a string array. The code snippet from the adapter is as below.</p>

<pre><code>if (convertView == null) {  // if it's not recycled, initialise some attributes
            imageView = new ImageView(mContext);
            imageView.setLayoutParams(new GridView.LayoutParams(85, 85));
            imageView.setScaleType(ImageView.ScaleType.CENTER_CROP);
            imageView.setPadding(8, 6 , 4 ,2);

        } else {
            imageView = (ImageView) convertView;
        }
</code></pre>

<p>also i want the images and the image title to be as close as in the image in the link below.</p>

<p><a href="http://stackoverflow.com/questions/4438935/how-to-implement-custom-device-photos-gallery-for-android">How to implement custom device photos gallery for android?</a></p>

<p>Thank you.</p>
