I'm having some trouble getting a line of unicode printed to the screen properly.
I'm calling:
wc_message(L">¡¢£¤¥¦§¨©ª«®¯");
Where wc_message() is:
void wc_message (wchar_t *text)
{
wchar_t mstring[256];
swprintf(mstring, L"MESSAGE: %s\n", text);
wprintf(mstring);
fwprintf(test_log, mstring);
}
When the text is printed:
I get --MESSAGE: >íóúñѪº¿¬¬½¡«»
instead of -- MESSAGE: >¡¢£¤¥¦§¨©ª«®¯")
I've never worked with unicode before so maybe I'm making a simple mistake -- sorry if that happens to be the case. Does anyone have any ideas on this though?
Thanks in advance.
-mark
I'm calling:
wc_message(L">¡¢£¤¥¦§¨©ª«®¯");
Where wc_message() is:
void wc_message (wchar_t *text)
{
wchar_t mstring[256];
swprintf(mstring, L"MESSAGE: %s\n", text);
wprintf(mstring);
fwprintf(test_log, mstring);
}
When the text is printed:
I get --MESSAGE: >íóúñѪº¿¬¬½¡«»
instead of -- MESSAGE: >¡¢£¤¥¦§¨©ª«®¯")
I've never worked with unicode before so maybe I'm making a simple mistake -- sorry if that happens to be the case. Does anyone have any ideas on this though?
Thanks in advance.
-mark