pvpgn / pvpgn-magic-builder

Ultimate program for building PvPGN on Windows
https://pvpgn.pro
MIT License
85 stars 40 forks source link

Change font for better unicode support #6

Closed RElesgoe closed 10 years ago

RElesgoe commented 10 years ago

The default font in the Command Prompt isn't good for unicode text but Lucida can support displaying cyrillic without changing the codepage or file encoding. 99.9% of people hasn't enabled Lucida font yet and registry changes aren't a good idea. A workaround for this situation is to create a shortcut of the main Magic Builder batch file and set it to use Lucida in the file properties. The user only has to run the shortcut so you should probably hide the main batch file in another folder.

HarpyWar commented 10 years ago

What the initial encoding of file should be to correct display cyrillic text with Licuda Console? Will it work with cyrillic or any text? Chinese for example.

RElesgoe commented 10 years ago

Use UTF-8 without BOM for file encodings. I've tried Korean however it doesn't work correctly but I can confirm that cyrillic works on my computer which is set to US English locale and still on codepage 437.

HarpyWar commented 10 years ago

It doesn't work for me licuda console

RElesgoe commented 10 years ago

Hmm, try setting the size to 14

HarpyWar commented 10 years ago

No changes. The same hieroglyphs with and without this font.

Another problem is we can't set relative path for a shortcut. I found this way but font resets to default.

RElesgoe commented 10 years ago

Ok in this case, set the codepage to 65001. I was testing this by changing the font to Lucida by default for all instances of the command prompt(not just the batch file) so that's why it was working for me.

HarpyWar commented 10 years ago

Nice, it works! But still issue with relative paths.

RElesgoe commented 10 years ago

We could write a very simple exe file to run the shortcut or have the initial batch file open another command prompt with the shortcut

HarpyWar commented 10 years ago

There are possible bugs and obscurity to go this way. For instance, I tried it on Windows XP and batch takes off with empty screen if set codepage to 65001.

Actually now it gives only a thinner font (although it looks better). If you have a ready tested solution it can be used. Now it can't.

RElesgoe commented 10 years ago

http://www.dostips.com/forum/viewtopic.php?p=34428 This seems to be a workaround for the Windows XP problem