Search code examples
windowsc++11consolelocale

C++ wcout unocode(Cyrillic, Japanese)


In my application I use Cyrillic and Japanese characters. When I use:

_setmode(_fileno(stdout), _O_U16TEXT).

On OS Windows - my output data looks like:

  1. cyrillic : Привет
  2. japanese : ???

What could be the problem?


Solution

  • You must install the Japanese locale on you machine.

    For your OS, i.e Windows, check here.

    This is a list of locales for Windows.