Home » Developing U++ » U++ Developers corner » about unicode supporting
about unicode supporting [message #59239] |
Thu, 01 December 2022 15:38 |
Satervalley
Messages: 18 Registered: December 2022
|
Promising Member |
|
|
I'm working on a app with upp under windows,as I want an "unicode built"(use -DUNICODE with clang or /D UNICODE with vc), but both have compiling error(upp core or ctrlcore packages), says that calling some wchar version function(xxxW()) with parameter of char *. I try UWord example, same error messages. how can I create an "unicode built" of my app?
|
|
|
|
|
|
|
Re: about unicode supporting [message #59260 is a reply to message #59257] |
Wed, 07 December 2022 17:32 |
|
mirek
Messages: 13975 Registered: November 2005
|
Ultimate Member |
|
|
Satervalley wrote on Wed, 07 December 2022 02:45thanks 4 replying. In fact, I'm confused on UPP's unicode handling, there's seems some inconsistent. 4 instance, SelectFileOpen()accept a const char* parameter and return String(that not good),imo that's not unicode friendly, ioh EditField ctrl SetText() accepts both String and WString(that's good), but GetText() only return WString.
The idea is to prefer UTF-8 everywhere. Sometimes, some methods are better returning WString - e.g. as internal representation in EditField is WString, it is easier to have GetText returning this internal WString directly, without converting it into utf-8.
If function/method accepts const char * or String, it is usually UTF-8 (there are some exception, e.g. String is often used with binary data).
And, BTW, Unicode support at this moment is not perfect, but is has nothing to do with this (we are yet missing some advanced typography features like combination characters needed to support languages like bengali, also RTL support is missing - all this is planed)
[Updated on: Wed, 07 December 2022 17:35] Report message to a moderator
|
|
|
Goto Forum:
Current Time: Thu Apr 18 03:29:30 CEST 2024
Total time taken to generate the page: 0.01854 seconds
|