[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Freetype] Japanese text
From: |
Chris Forno |
Subject: |
[Freetype] Japanese text |
Date: |
Sat, 25 May 2002 20:59:26 -0400 |
User-agent: |
Mutt/1.2.5i |
Perhaps this is not the right place to be asking this, but I've been searching
for an answer for days, so...
How exactly can I go about setting up freetype to render Japanese characters
(or characters from non-English languages, for that matter). I have no problem
rendering English text with C++/FreeType/SDL, but I'm unsure of how to approach
Japanese text.
I'm able to load the font without problems, but I'm unsure of how to get
C++/FreeType to recognize a string as Japanese text. So far I'm only typing
the text into my source file (which is getting saved in the EUC encoding) and
prefixing it with L (which I guess makes it a wide string). Then I use a
basic_string<wchar_t> and an iterator to pass characters to FreeType. The
problem is that instead of taking a 16-bit character and looking it up, it
takes 2 8-bit characters.
I know that I'm way off here and I really don't have a clue of how to do this
correctly. I've tried a combination of converting my source file to jis/sjis
and setting the encoding to unicode and sjis with FT_Select_Charmap. I haven't
been able to figure out how to use FT_Set_Charmap yet since I don't know how to
get a Charmap to send to it!
Anyway, I know this is a mess, but I would really appreciate any pointers to
any information that can help me figure out how to do this.
By the way, I do not speak (much) Japanese and have very little experience with
Japanese information processing outside of using a Japanese IRC client.
Thanks in advance for any help that you can provide.
- [Freetype] Japanese text,
Chris Forno <=