JoanZapata / android-iconify

Android integration of multiple icon providers such as FontAwesome, Entypo, Typicons,...
http://joanzapata.com/android-iconify
Other
3.93k stars 526 forks source link

Problem when using words with "~" for example "Padrão" (Portuguese word) #92

Closed Damore closed 9 years ago

Damore commented 9 years ago

Hello,

I'm using the iconify and one of my buttons is like the below:

botao_iconify

However, the character " ã " is misaligned, probably because it is a portuguese word.

Any ideas?

JoanZapata commented 9 years ago

The whole string actually use the fontawesome typeface, so I don't think there's a workaround, you'd have to use 2 TextView side by side, the left one being an IconTextView.

Damore commented 9 years ago

I can't imagine how to do what you are suggesting to do... Can you show me an example?

JoanZapata commented 9 years ago

Sorry I didn't notice it was a button, which makes it harder. I think the best way to go is to do it programmatically like :

yourButton.setCompoundDrawablesWithIntrinsicBounds(
     new IconDrawable(context, IconValue.fa_save), 
     null, null, null)

(Don't forget to set the icon size and color on IconDrawable using setters.)

JoanZapata commented 9 years ago

@Damore I'm currently working on a V2 which would fix this problem. Hopefully it should be available by the end of the week. In the meanwhile you can still use the compoundDrawable as suggested.

Damore commented 9 years ago

Thank you very much!

JoanZapata commented 9 years ago

Fixed by v2.