C++ string/char and accents
I'm writing a text writer in C++, which I'll have a string of a phrase and
display the appropriate bitmap font for each char value.
For now, it's working for the regular characters, but I'm getting weird
values for accents and other characters such as À, Á, Â, Ã, etc
I'm doing this:
int charToPrint = 'a';
//use this value to figure which bitmap font to display
The bitmap font does have these characters, but on this line I'm not
getting the values I'm supposed to get, such as: 195 for Ã, 199 for Ç,
etc...
I tried changing my project's character set from Multi Byte to Unicode,
but I don't think that does anything for the char->int conversion...
How can I get this conversion with chars?
No comments:
Post a Comment