Skip to main content
Paulo Rego
Associate II
Solved

touchgfx print Unicode para o caractere "♂" 0x2642

Hello everyone,
I spend hours trying to print the male and female ♂ ♀ symbol on the screen, without success.

I tested this code and it works perfectly, when I change the hex to the desired symbol does it print "?"

 Screen1ViewBase::setupScreen();

 Unicode::UnicodeChar buf[2] = {0x2082, 0};
 Unicode::strncpy(textArea1Buffer, buf, 5); 
 textArea1.invalidate();

any tips please

Regards,

Rego

This topic has been closed for replies.
JTP1Best answer
Graduate II

Hello

First, you must list these characters in Typographies -> Wildcard ranges, for example 0x00-0xff,0x2640,0x2642

And then you must select font which has these symbols, default font verdana does not include these two, but for example arial does.

Btw, symbol 0x2082 is some small number 2.

Hope this helps

Br JTP

2 replies

JTP1Best answer
Graduate II

Hello

First, you must list these characters in Typographies -> Wildcard ranges, for example 0x00-0xff,0x2640,0x2642

And then you must select font which has these symbols, default font verdana does not include these two, but for example arial does.

Btw, symbol 0x2082 is some small number 2.

Hope this helps

Br JTP

Paulo Rego
Associate II

Hi Br JTP,

helped a lot!

the problem was in the font.

thank you very much

Rego