UTF-8 format for display º and %

the font.c file should contain this degree symbol.
to add those symbols, you must include symbols.ttf file along with ascii ttf file while converting to font.c file.
this should definitely work.

For future people searching for the answer, I found a reliable solution to this that is working in LVGL v8.3:

  1. Create a custom font with this range of characters: 0x20-0x7F,0xB0 (the 0xB0 is the degree symbol).

  2. While using that font, format your string for rendering like this:

sprintf(buffer, "%d °C", degrees);

This embeds 0xC2 then 0xB0 which is the UTF-8 encoding for the degree symbol.

Then the rendering engine using that font will output a beautiful “99 °C”.

I hope that helps.

Kind regards,
Vic