Akira-Hayasaka / ofxGLEditor

Script editor for oF Live Coding
GNU General Public License v2.0
100 stars 16 forks source link

issue with displaying some utf8 wide characters on certain fonts #22

Closed RVirmoors closed 8 years ago

RVirmoors commented 8 years ago

Hi there, I posted the same on the ofx forums thread: http://forum.openframeworks.cc/t/ofxgleditor/10425/12

I'm trying to use utf8 characters, and while Arial Unicode.ttf displays everything correctly, with others some characters are missing. Using this test:

2 bytes: Ø Æ ö ä « » þ 3 bytes: € Ж 丽 4 bytes: 日本国

..only the 2-bytes and part of the 3-bytes ones appear. Not sure why, since I can use the same font (Consolas, Menlo ...) in other editors, and all characters render correctly. Any clue why this happens?

The ideal would be to have a single-spaced font with full utf8 compatibility.

danomatika commented 8 years ago

Short answer is that ofxGLEditor is meant to be a simple text editor, so loading multiple fonts isn't a high priority at this time.

danomatika commented 8 years ago

Long answer is that text editors generally load multiple fonts when supporting multiple languages/glyphs. There are a few fonts that supports lots of characters, but they aren't really used much. Unifont is one but it's a 10+ MB font file: http://www.unifoundry.com/unifont.html