cancel
Showing results for 
Search instead for 
Did you mean: 

What file we need to include to use" touchgfx ::Unicode::UnicodeChar " and strncpy

RG.3
Associate III

In my code when I am using touchgfx::Unicode::UnicodeChar it is showing expected an expression....What files should I include to solve this error

12 REPLIES 12
RG.3
Associate III

Present documentation is actually good. What I feel is it will be helpful if you make some tutorials for adding text in other languages.

Thanks and Regards

Rishikesh G.

One comment to add:

TouchGFX uses 16 bit characters (UnicodeChar). Any data coming from 8-bit sources must be converted to 16bit. This can be done with Unicode::strncpy and the similar functions. These are basically just extending the (unsigned) 8-bit values to 16-bit. Then TouchGFX can show the characters, provided the font contains the characters as explained above. Typically a range of printable characters ascii are required if you plan to receive strings from say a serial port. The TouchGFXDesigner only includes the characters used by the texts in the project.

We also have a converter from UTF-8 to U16, which can be used when you received a text from eg. a cell-phone.

Hi RG.3,

Could you add this suggestion to the "Idea Zone" section of this forum ?

This will greatly help us keep track of this.

Best regards,

/Romain