开发者

unicode for ગુજરાતી letters [duplicate]

开发者 https://www.devze.com 2023-04-04 05:30 出处:网络
This question already has answers here: Closed 11 开发者_如何学运维years ago. How can I print Gujarati letters in C#?
This question already has answers here: Closed 11 开发者_如何学运维years ago.

How can I print Gujarati letters in C#?

I tried:

Console.Write('\u0A95');

It should print ક,as 0x0A95 is unicode for ક but it displays ? instead.

What's wrong?


The Console window has a limited support for Unicode. Many languages can't be rendered correctly because it doesn't have the auto-fallback to another font. To check this, try copy-pasting something in the Command Line. And you can't really change the font of the console. Read this: http://blogs.msdn.com/b/oldnewthing/archive/2007/05/16/2659903.aspx They tried and they saw that it was useless/impossible. Console font must be monospaced and very regular.

And this from probably one of the gurus of Unicode at MS: http://www.siao2.com/2011/08/18/10196878.aspx

Well, the console can support Unicode, but:
- No complex script support
- No font substitution
- Some console apps don't support Unicode even though the could
- 1 and 2 can be fixed by using the PowerShell ISE

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号