tags:

views:

120

answers:

1

I am required to use custom fonts in my application.

Problem: For ListViews that contain rows with Multi-Line TextViews having ellipsize property set to true, I can see some illegible characters after the ellipsis. Apparently Android pads the String(in TextView) with some characters(ZERO WIDTH NO BREAK-SPACE) unknown to my custom font.

Single line TextView seem to work just fine.

What is the best way to hide these characters or remove the padding? Also, is there any variant of Helvetica font, freely available that would have ZERO WIDTH NO BREAK-SPACE character?

Thanks.

+1  A: 

What is the best way to hide these characters or remove the padding?

I do not know of a way to do that.

Also, is there any variant of Helvetica font, freely available that would have ZERO WIDTH NO BREAK-SPACE character?

Considering that Helvetica is very similar to the built-in Droid Sans, I am not sure why you are bothering embedding Helvetica in an application. Also, by definition, there is no "freely available" Helvetica font, as that font is not free.

That being said, given a font that lacks the ZERO WIDTH NO BREAK-SPACE glyph, have somebody open your font file and add in the glyph. We did that on one consulting project of mine, and it worked out well. I am under the impression that a graphic artist may know how to do this.

CommonsWare
Do you really have to be a graphic artist to do that? Wont a good Font editor cover my naivety with this? :)I am using Droid Sans at the moment. Thanks for your reply!
Samuh
If your font editor allows copying glyphs from one font to another, then you may be able to simply copy ZERO WIDTH NO BREAK SPACE from Droid Sans to your desired font. However, I have not tried this.
CommonsWare
Hmmm...thanks again!
Samuh