Display French characters

Display French characters
0.0 0


I’m trying to use CCLabelTTF and display characters like é , but it obviously doesn’t work. How should I handle this?


Works very well for me (cocos2d-x2.2 with Android and iOS). On Android and iOS, CCLabelTTF use the native font rendering, and support mostly everything.

What version of cocos2d-x, what font are you using and on what platform ?

Beware that not all fonts support special characters.


The font I’m using does support special characters… using 2.2.3


Can you post some sample code and a link to the font you are using ? On which platform are you testing ?


testing on windows phone.

string thisLine, result, fullPath, contents;

// Get absolute path of file
fullPath = CCFileUtils::sharedFileUtils()->fullPathForFilename(string(dict_name + "_easy.ait").c_str());

// Get data of file
fileContents = CCFileUtils::sharedFileUtils()->getFileData(fullPath.c_str(), "rb", &fileSize);
contents.append((char *)fileContents);

// Create a string stream so that we can use getline( ) on it
istringstream fileStringStream(contents);

// Get file contents line by line
while (getline(fileStringStream, thisLine)) {
	// Put all lines in vector


IMPORTANT NOTE: Using visual studio, I looked at the values that thisLine gets, and it does look like it has the right characters with the right accents. But still, on screen I see weird symbols.


I can’t test on Windows Phone, but if you have weird symbols on screen, you should check your source files encoding (where the string is declared).


i checked again. Since the file is actually a text file, i saved it again as unicode text. The symbols are still there.


Any news on this? I got the same issue. I use 2.2.3 and VS2012.