Automatically change font size in label according to text

,

I use the LVGL library version 8.3 to render graphics on the display. I have a label that has a fixed size (width and height). I need to solve the problem of automatically adjusting the font size according to the text that is inserted in the label. For example, if there is only one word below the text, the largest possible font will be used. If the text would be outside the size of the label, the font should be changed to one where the text is inside the label. Is there such a thing in LVGL? Or can anyone advise how to solve this?