0

I develop an application in english and for a client, i must to translate some text in hungarian. I've got a menu.xml files in values folder and i create a new menu.xml in values-hu folder. I start my phone and i select Magyar language. The good language is selected and i see the text in hungarian... well almost!

In my menu.xml, i've this text : Információ and on my screen phone : Inform∂ciciy, why ?

I use Android 2.3 on my phone and my application supports Android 2.1 minimum. I can change the encoding of my menu.xml file but ISO is not agree by eclipse.

FinalSpirit
  • 569
  • 1
  • 6
  • 17
  • You don't write which encoding you use, but that you can change to ISO. How about utf-8? – bos Nov 23 '11 at 14:23
  • Sorry, i use utf-8 encoding by default. It doesn't work. I try to replace by ISO 8859-16 but eclipse doesn't like this value and does'nt want to save my file... – FinalSpirit Nov 23 '11 at 14:39
  • It's strange, the test appears normal in dialog box but in all TextView, characters are changed by itself. á replace to ∂ / ó replace to y,... i don't undertand what i miss :( – FinalSpirit Nov 23 '11 at 15:27

1 Answers1

2

change the preferences in eclipse - Window->Preferences->XML->XML Files

EDIT (Actual solution): This is because the android font doesn't support these characters. You can try register your own font and set it to your textviews. I think I had this kind of problem and I ended up with a CustomTextView where the TextView is created with custom Typeface

mihail
  • 2,173
  • 19
  • 31
  • Thanks, eclipse save my file now but when i change the value in the xml header, i've this error : Invalid encoding name: "ISO 8859-16" – FinalSpirit Nov 23 '11 at 15:03
  • inst it ISO-8859-16 - with a dash – mihail Nov 23 '11 at 15:04
  • It's ISO-8859-2 for hungarian characters but i've this error when i setup this value : Error parsing XML: unknown encoding. ISO-8859-1 works but all caracters were always strange. – FinalSpirit Nov 23 '11 at 15:15
  • 1
    what if you leave the layout files with utf-8 encoding? I'm working with german symbols, ISO-8859-1 is used only when have to deal with http requests. All my layout files have utf-8 encoding – mihail Nov 23 '11 at 15:23
  • It don't seem to be an encoding problem. The text appears normal in dialog box but in all TextView, characters are changed by itself. á replace to ∂ / ó replace to y,... i don't undertand what i miss :( i set utf-8 encoding finally. – FinalSpirit Nov 23 '11 at 15:29
  • I guess this is because the android font doesn't support this characters. You can try register your own font and set it to your textviews. I think I had this kind of problem and I ended up with a CustomTextView where the TextView is created with custom Typeface – mihail Nov 23 '11 at 15:34
  • Of course ! I use a custom font and this font doesn't support these characters. I've removed my font and it works now, thank you ! – FinalSpirit Nov 23 '11 at 15:59