[wingide-users] Display Unicode strings in console?

Graham Wideman initcontact at grahamwideman.com
Wed Mar 19 17:18:15 EDT 2014

Thanks Stephan for the clues -- which leads to a question:

Setting Debug I/O Encoding preference to utf-8 works nicely to allow print() to show all kinds of nice characters in the Debug I/O window.

If fact, it seems to work magically better than it should! I'm now trying to understand how that's possible.

print("This has [\u265E] non-ASCII chars")

... prints the string to the Debug I/O window, including correctly showing the Chess Knight symbol. 

However, I don't think the font actually has that glyph!

(Win7-64, Python 3.3.2)
WingIDE Preferences > UI > Fonts shows:
Display Font: Default: Lucida Grande 12
Editor Font: Default: Consolas 12 

I assume it's the "Editor Font" in the Debug I/O window: Consolas.

Looking at Consolas in Windows Character Map (or using a font editor), code point \u265E doesn't seem to have a glyph.

In agreement with that finding, the same code in cmd.exe (with font set to Consolas, and after chcp 65001), the string will print, but the Knight character appears as a generic [?] box.

So -- how does WingIDE manage to show the correct glyph? 

Does WingIDE have its own private fonts that are different from the OS's fonts? (Incidentally, I noticed that the default display font, Lucida Grande, is not a font that is installed in Windows -- again suggesting private fonts.)

-- Graham

More information about the wingide-users mailing list