2024-06-17 01:46 AM
Hi Community,
Is it possible to cache all fonts at the startup of TouchGFX in order to have a single memory access?
The documentation provides an example of caching a single font associated with a text box when a screen starts. If I understand correctly, this procedure would have to be applied to each screen change and for each text box contained each time.
It would be more useful ( for me ) to have a function like "void Bitmap::cacheAll()" for images.
e.g. "void Font::cacheAll()" to be called in FrontendApplication::FrontandApplication().
Regards
2024-06-25 04:42 AM
Hello @Dadigno,
Yes you can put the code anywhere you what, and create all the cached font at in the FrontendApplication, but if you want to use all font then you'll have a large cache, so you also directly use non-cached font in that case.
Regards,
2024-06-25 05:18 AM
Hi @LouisB ,
Thanks for your support. Could you please provide an example of how to do what you described? I'm not sure which APIs I should use to cache all the fonts.
Regards,
2024-06-25 11:27 AM