Cyrillic Fonts
Moderator: Moderators
Cyrillic Fonts
Hello, long time lurker here. Now I decided to translate BA into russian for my friends, but when I change the game text (unit descriptions, etc.), the game shows "strange symbols" instead of cyrillic ones. How can I get this working?
-
- MC: Legacy & Spring 1944 Developer
- Posts: 1948
- Joined: 21 Sep 2004, 08:25
Re: Cyrillic Fonts
Teach your friends english.
Re: Cyrillic Fonts
You need to make sure the fonts being used have cryllic characters. There may also be parts of code that simply do not support unicode characters.
Re: Cyrillic Fonts
Pretty sure?
Well if they're not coming up as the proper character then they dont.
Also
Ah well, best of luck in your endeavor anyway hope you get it sorted.
Well if they're not coming up as the proper character then they dont.
Also
although harsh i do share the same sentiment at times. its a real pain when people try to join games and dont speak a word of english so are unable to hear tips / understand whats going on. (not going to name names cos that's dis respective here).Teach your friends English
Ah well, best of luck in your endeavor anyway hope you get it sorted.
Re: Cyrillic Fonts
Well, thanks for info. Then I should make not a translation, but a transliteration.
Re: Cyrillic Fonts
Wow, I managed to get cyrillic fonts working! Thread can be closed.
Re: Cyrillic Fonts
For the record how did you get them working? This might come up again one day.
Re: Cyrillic Fonts
I wrote russian alphabet instead of unit's name and made a screenshot of "strange symbols". Then I copied the standart font (FreeSansBold) and with font-editing software changed these symbols with cyrillic ones. Then I changed the font in springsettings.cfg. Now it works almost fine (sometimes string can change color in random place).
Re: Cyrillic Fonts
Odd, Free Sans Bold seems to contain the cyrillic character set from Unicode 0414 thru 042F for caps and 0430 thu 044F for lowercase... what symbols was it using instead?
Re: Cyrillic Fonts
huh, my theory is that spring is taking the ANSI/DOS character codes (CYRILLIC SMALL LETTER A is 0xE0 and Lower Case Cyrillic Ya is 0xDE) and displaying the corresponding Unicode/UTF-8 character (LATIN SMALL LETTER A WITH GRAVE is U+00E0 and Latin Capital Thorn is U+00DE) so ð░ becomes ├á and ÐÅ becomes ├×
Crazy...
EDIT:
Huh, what text editor are you using and what character encoding are you saving your files in... perhaps you are saving your files in a DOS format and if you instead saved it as UTF-8 the characters would be mapped correctly (spring may be assuming UTF-8 encoded text files and not bothering to check the header.)
Crazy...
EDIT:
Huh, what text editor are you using and what character encoding are you saving your files in... perhaps you are saving your files in a DOS format and if you instead saved it as UTF-8 the characters would be mapped correctly (spring may be assuming UTF-8 encoded text files and not bothering to check the header.)
Re: Cyrillic Fonts
I decided to make a Bump post because my proposed solution was edited in and no one responded and I wanted to know if my suggestion worked or not.
So, did it work if you save your text files in UTF-8?
So, did it work if you save your text files in UTF-8?
Re: Cyrillic Fonts
I just experimented with using Cyrillic letters in unit description. I tried DOS (866), Win (1251) and UTF-8 encodings. None of those resulted in readable letters.
Moreover, saving an .fbi file in UTF-8 (at least using Notepad++) results in file having some kind of 2-byte header which prevents Spring from reading it (I had to remove that header with another text editor which doesn't support UTF).
Edit: I installed FreeSans font from Spring dir into Windows and found it surely supports Cyrillic letters (in apps such as MS Word), so it must be something in Spring code that breaks them.
Moreover, saving an .fbi file in UTF-8 (at least using Notepad++) results in file having some kind of 2-byte header which prevents Spring from reading it (I had to remove that header with another text editor which doesn't support UTF).
Edit: I installed FreeSans font from Spring dir into Windows and found it surely supports Cyrillic letters (in apps such as MS Word), so it must be something in Spring code that breaks them.