I’d like to define styles () in an XML file and add it to a stylesheet.
I can make the parser, but how do I create and add new styles programmatically?
I’d like to define styles () in an XML file and add it to a stylesheet.
I can make the parser, but how do I create and add new styles programmatically?
Some TMP are creating styles dynamically. To do so, I believe they modified the TMP_Styles.cs and possibly the TMP_StyleSheet.cs to add a setter on the required properties.
Assuming you are using the TMP UPM package for Unity 2018.1 and up which includes source code, your should be able to make the necessary changes.
When grabbing text from XML, be mindful of control characters being escaped.
I used to modify TMP back when you sold it, but every version update made it really difficult to maintain.
So you can’t do this out of the box? Are there any plans for adding this?
This is functionality that is now more frequently used / requested.
I can’t provide on ETA on when I can add support for this but I will most certainly add it to my list.
Thank you so much. I’m looking forward to it!!