''[[FrontPage]]''
*この記事はまだ書きかけです。管理人が今後加筆していく予定ですので、参考にする場合は注意してください。
* アプリケーションをUnicodeに対応させる [#r2296e76]
ワイド文字列を扱う場合に注意しなければならないこと。~
よくやるのは
#ifdef UNICODE // 強引に対応。単独プロジェクトならOK?
typedef wregex tregex; // 正直自分でも何してるのか分からない。
typedef wstring tstring; //
typedef wsmatch tsmatch; //
typedef wstringstream tstringstream; //
//typedef wprintf tprintf; //
#else //
typedef regex tregex; //
typedef string tstring; //
typedef smatch tsmatch; //
typedef stringstream tstringstream; //
//typedef wprintf tprintf; //
#endif //
のように、あくまでどっちつかずな方法。~
TCHARの概念をすべてに適用するというわけだけど、神経質すぎ?
*** 参考ページ [#ce23eda2]
http://www.246.ne.jp/~y-ookubo/program/tips/unicode.html~
http://www.usefullcode.net/2006/11/tcharlpctstrlptstr.html~
http://hw001.gate01.com/eggplant/tcf/cpp/wchar_t_trap.html~
http://hp.vector.co.jp/authors/VA019646/software/func_list.htm~