I'm unsure if this is a c++ issue or a Compiler issue, but i believe you should be able to display foreign characters in C++ so I assume its a C++ thing. So I want to display this text in my program: きゃっかんてき and I did this:
the first output gives me strange characters and the second gives me a memory address (0x47403c) so how do I display this text in c++? I thought L in front of the string was used to display exotic characters? My Compiler is CodeBlocks btw,.
Alas, you've got to set up the console properly, and using the standard C++ streams is unlikely to work unless you are encoding with UTF-8. http://www.cplusplus.com/forum/general/81427/
Hope this helps.
This test tells me whether or not the issue is with either your editor or libc++ vs the console setup. :OJ
(Also, I forgot that the Console has something of a bug in it. You must output something 7-bit before anything UTF-8 in order for it to not garble き. Hence the newline at the front. Soulless console.)
Open console, change codepage, then launch already compiled program from that console. Note that font used by console usually does not support anything non-ASCII, so you will have to make sure that current console font is able to display those characters
Ah, yes, that's an important point. In the top left corner of your Console Window, right-click the icon and select "Properties" from the popup-menu. Select the "Font" tab in the window that appears and make sure "Lucida Console" is the chosen font. Click "OK' to save your changes. If it asks, you might as well make the changes permanent for all future invocations of the Windows Console as well.