Actions
Support #4403
closedRussian text
Start date:
08/19/2015
Due date:
% Done:
0%
Estimated time:
Description
Hello!
How I can write to webpage russians symbols?
i try
WContaierWidget *interface = new WContainerWidget(this->root());
...
interface->addWidget(new WText("Русский тескт <--- Russian text"));
and i see result:
?? <--- Russian text. How fix it?
Updated by Wim Dumon about 9 years ago
- Status changed from New to Resolved
The only portable way is to put the text in a message resource bundle outside of the .C file.
Non-portable alternatives:
interface->addWidget(new WText(WString::fromUTF8("Русский тескт <-- Russian text")));
interface->addWidget(new WText(L"Русский тескт <-- Russian text"));
Updated by ioann sys about 9 years ago
Thank you! It work for me.
I write simple function for printing text:
void print_str(WContainerWidget *widget, string text, int h = 0)
{
WText *txt_widget = new WText( WString("<h{1}>").arg(h) + WString::fromUTF8(text) + WString("</h{1}>").arg(h), widget);
return;
}
Updated by Koen Deforche about 9 years ago
- Status changed from Resolved to Closed
Actions