Click here to Skip to main content
15,899,026 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: How can read a unicode text file as character by character? Pin
Albert Holguin21-Mar-11 3:31
professionalAlbert Holguin21-Mar-11 3:31 
GeneralRe: How can read a unicode text file as character by character? Pin
Emilio Garavaglia22-Mar-11 22:43
Emilio Garavaglia22-Mar-11 22:43 
GeneralRe: How can read a unicode text file as character by character? Pin
Albert Holguin23-Mar-11 4:07
professionalAlbert Holguin23-Mar-11 4:07 
GeneralRe: How can read a unicode text file as character by character? Pin
Emilio Garavaglia24-Mar-11 8:37
Emilio Garavaglia24-Mar-11 8:37 
GeneralRe: How can read a unicode text file as character by character? Pin
Albert Holguin24-Mar-11 8:41
professionalAlbert Holguin24-Mar-11 8:41 
GeneralRe: How can read a unicode text file as character by character? Pin
Emilio Garavaglia22-Mar-11 22:46
Emilio Garavaglia22-Mar-11 22:46 
GeneralRe: How can read a unicode text file as character by character? Pin
Albert Holguin23-Mar-11 4:21
professionalAlbert Holguin23-Mar-11 4:21 
GeneralRe: How can read a unicode text file as character by character? Pin
Emilio Garavaglia24-Mar-11 9:57
Emilio Garavaglia24-Mar-11 9:57 
Nope.

1) Unicode is not a Microsoft product. What UNICODE is is defined by www.unicode.org[^]

2) Microsoft use to encode UNICODE into 16-bits units. That is a technique well defined by the UNICODE standard itself, known as UTF-16. Essentially, every code not in the range 0xD800-0xDFFF and lower than 0xFFFF is code as itself.
Every other greater that 0xFFFF is broken in two 10-bits chunks, or-ed with 0xD800 and 0xDC00 respectively.
The range 0xD800 - 0xDFFF is called "UNICODE surropgate" and does not contain valid codepoints.

So you can have single unicode characters requiring two wchar_t in sequence to be represented and sequences of two wchar_t representing a single character, with code greater than 0xFFFF (typical for CJK - Chinese, Japanese, Corean characters).

2 bugs found.
> recompile ...
65534 bugs found.
D'Oh! | :doh:


GeneralRe: How can read a unicode text file as character by character? Pin
Albert Holguin24-Mar-11 10:02
professionalAlbert Holguin24-Mar-11 10:02 
AnswerRe: How can read a unicode text file as character by character? Pin
Richard MacCutchan20-Mar-11 23:18
mveRichard MacCutchan20-Mar-11 23:18 
GeneralRe: How can read a unicode text file as character by character? Pin
Le@rner21-Mar-11 0:51
Le@rner21-Mar-11 0:51 
GeneralRe: How can read a unicode text file as character by character? Pin
Richard MacCutchan21-Mar-11 2:33
mveRichard MacCutchan21-Mar-11 2:33 
GeneralRe: How can read a unicode text file as character by character? Pin
malaugh1-Apr-11 5:03
malaugh1-Apr-11 5:03 
QuestionSee if dll exist Pin
marca29220-Mar-11 22:04
marca29220-Mar-11 22:04 
AnswerRe: See if dll exist Pin
వేంకటనారాయణ(venkatmakam)20-Mar-11 22:32
వేంకటనారాయణ(venkatmakam)20-Mar-11 22:32 
GeneralRe: See if dll exist Pin
marca29221-Mar-11 0:48
marca29221-Mar-11 0:48 
AnswerRe: See if dll exist Pin
CPallini20-Mar-11 22:35
mveCPallini20-Mar-11 22:35 
AnswerRe: See if dll exist Pin
Richard MacCutchan20-Mar-11 23:15
mveRichard MacCutchan20-Mar-11 23:15 
GeneralRe: See if dll exist Pin
marca29221-Mar-11 0:52
marca29221-Mar-11 0:52 
GeneralRe: See if dll exist Pin
Richard MacCutchan21-Mar-11 2:35
mveRichard MacCutchan21-Mar-11 2:35 
GeneralRe: See if dll exist Pin
marca29221-Mar-11 4:49
marca29221-Mar-11 4:49 
GeneralRe: See if dll exist Pin
Richard MacCutchan21-Mar-11 5:47
mveRichard MacCutchan21-Mar-11 5:47 
Questionhide the file or folder Pin
sarfaraznawaz20-Mar-11 21:23
sarfaraznawaz20-Mar-11 21:23 
AnswerRe: hide the file or folder Pin
Vera99920-Mar-11 21:36
Vera99920-Mar-11 21:36 
AnswerRe: hide the file or folder Pin
Richard MacCutchan20-Mar-11 23:13
mveRichard MacCutchan20-Mar-11 23:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.