In my application, I have a listview whose list item consists of a TextView and a Checkbox. The textview holds the name of some song and checkbox is always positioned at parent right with 5dip margin to all the sides.
Now the problem is, whenever the title of the song exceeds some limit, I want to show "..." after the songs title. e.g. Song’s title is "My heart will go on", I want to display only "My heart wil...". And of course, if the title is short enough, no “…” needed. I don’t want the text to be of marquee type. Can this be done? How?
A textview provide attribute ellipsize, simply add below attribute it will give same result as you want.