Re: std::wofstream

From: Chris \( Val \) (
Date: 12/01/03

Date: Mon, 1 Dec 2003 23:08:07 +1100

"Gene Wirchenko" <> wrote in message
| On Wed, 26 Nov 2003 22:50:07 +1100, "Chris \( Val \)"
| <> wrote:
| >"Gene Wirchenko" <> wrote in message
| >
| >> I have some data in Unicode. I wish to write it to a file. I do
| >> so. The resulting file is ASCII. This will not do. How do I make
| >> sure that the output is Unicode?
| >You have to set your O/S and programs to be able
| >to support the output, aka fonts, locale etc...
| >Read this:
| >
| That is a sizeable site, and I do not see where the C++
| programming section is, or even if there is one. Could you please be
| more specific?

There is no mention of C++ there, and there wasn't meant to be :-).

It was meant to provide you with some information, that you won't
see the characters you expect, if you do not alter your default
font set.

| I have already done some Web hunting, but have found nothing
| about adjusting the character set, only vague hints.

Well, in windows 2000 and XP for example, you would change the font
notepad uses to the one you want, furthermore, you would no longer
save the file as a plain 'ANSI' text file, but rather to one that
supports the wide character encoding set you wish to use.

For example: 'Unicode', 'Unicode Big Endian' or 'UTF-8' are amongst
the options in notepad.

The locale you use might also play a part.

Chris Val