Currency Symbols £

Hi All,

I would like to include the £ symbol on my UI.
Is it really the case that LVGL only has the $ currency symbol and no other currency symbols?
Isn’t LVGL used loads for vending machines and so on?

cheers, Giles

Hello,

LVGL’s default font is actually missing a lot of characters. It is basically just the latin alphabet with (almost) no accents and only a select few icons.

You will have to generate your own font with all the characters you might need. See the documentation Fonts — LVGL documentation

Ah OK thanks Tinus - is it best to completely create a new font or should I just create a £ symbol and try to add it to the existing font?

It’s best to create a completely new font. I doubt it is even possible to add onto an existing font without generating a completely new one anyway.

1 Like

@Tinus - do you know what the “standard” settings are for the font converter?
BPP for example?
I’m thinking of creating some SF files to go alongside the Montserrat files - ideally exactly the same as the built in fonts just including the £ sign and not bothering with any of the other symbols.
This is my current setup:

Hello,

Judging by the source files for the default font lvgl/src/font/lv_font_montserrat_12.c at master · lvgl/lvgl · GitHub

it looks like 4 bits per pixel and no further settings.

I personally use 4bpp and the “glyph color info” setting, it looks quite crisp but I’m not sure if that extra setting makes a big difference.

brilliant, thanks @Tinus

Update: @Tinus
I’ve just spotted there is a section in Squareline Studio that also generates the fonts and lets you use them straight away. Here’s my settings. Note that the £ symbol did not work when I put the 0xa3 in the Symbols section, I needed it in the Range section for it to work. I had to export the SF-Pro font from Font Book on the Mac to get the .ttf file to use.

Hello Giles,

Sounds good, as long as it works!

In the symbols section you are supposed to put the literal ASCII characters used,
so in your case that would be something like

[space][a…z]0123456789£[etc.]

1 Like