Closed keestux closed 3 years ago
I'm sorry, style management for ODF is complex. From the method insert_style() doc string: "If default is True, the style will be inserted as a default style and would replace any existing default style of the same family. Any name or display name would be ignored."
See also the "limitations" paragraph from the readme.md: "the best (only ?) way to apply style is by merging styles from a template document into your generated document. See odfdo-style.py in "scripts" folder."
Hmm, sorry for the noise. I messed up myself. I modified something I shouldn't have.
Not a problem. Your issue will help others to understand that : styles in ODF are not what most people would expect from a concept having that name. What ever anybody would think about that "style" thing is off topic, as the main requirement is to implement something compliant with actual ODF format.
While I was trying to create a new document and fill it with a table from a template document I noticed that that styles are not inserted properly in the new document. Every time
.insert_style
is called it will delete the previously inserted style.