Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

CodeBlock Unicode conversion

<< < (2/4) > >>

cyberkoa:
I have read the wxwidgets documentation on writing unicode program ..

This link give us a useful information
http://wiki.wxwidgets.org/wiki.pl?WxWidgets_Source_Oddities

I think takeshimiya is right.

rickg22:
Oh,I see. Until we're translating into other languages, we should use _T() always. Thanks for the info :)

mandrav:

--- Quote from: rickg22 ---Oh,I see. Until we're translating into other languages, we should use _T() always.
--- End quote ---

No, this is the correct way:

--- Quote from: takeshimiya ---_() for translatable text, and _T() for text that must not be translated.
--- End quote ---

Everything that will possibly need to be translated (i.e. every text presented to the user), will be wrapped with _().
_T() will be used only for hardcoded strings like paths, filenames, etc.

Yiannis.

rickg22:
Thanks for the info! :)

Oh, any advises on which char types should be changed to wxChar ?

takeshimiya:
I think I should have to be more explicit. :)

Example for text:
wxChar im_a_character = _T('f');

Example for not text (not character):
char im_a_byte = 254;
but perhaps better would be to use:
byte im_a_byte = 254;
so it's clear that it's a byte and not a character.

but yes rickg22, the _() and _T() name convention is confusing, as one would think that the T in the _T() means Translatable or Translate.
So to memorize I put a 'logic not' of what would be logical :D and if I see _T() I think in 'Not Translatable'.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version