Kodi Community Forum

Full Version: Dynamic font size
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi there,

I'm writing an addon and in one of the interfaces I have a text area that I would like to be filled up automatically with the text. This means that I would like to have the text font automatically resized in order to fill up (as most as possible) the whole area. Is this possible? Is there any element I can put in the "label" control in the Window XML file? Or is it possible to do in the code by using XBMC API?

Thanks
You can set the font for ControlLabel or (better for multiple lines of text) ControlTextBox. So you have to set it manually based on the text length and box size.
But how can you do it after the label control is created? I can't find any method for that? Maybe setProperty()?

Thanks