Intended way to format text?
qwoodmansee opened this issue · 2 comments
Edit:
I see this comment from a previous issue:
"This is not possible with this package. The text you provide will be injected inside some XML node as the node's text. In order to specify the markup, you would have to provide the correct Word XML markup and not the HTML markup. So you would have to come up with a transformation from HTML to Word XML. This package would have to be changed such that it inserts XML instead of text, in order to support formatted text."
I'm going to close this because it looks like you do not plan on supporting this feature anytime soon. Please feel free to add it as a suggestion if you have interest in supporting it in the future - I think it's pretty important for the generation of documents
Expected Behavior
I've attempted to add formatting to my text (just by adding characters to the strings) a few different ways (html tags and rtf symbols) and nothing has seemed to work. As of right now i'm trying simple thing like, bold and italics. Is there currently a way to make this happen? If not, it would be nice to have a simple way to make text formatted.
Current Behavior
Currently adding "\b [text] \b0" in my python strings just displays all the characters. Same with HTML tags.
Context
I'm creating a list of instructions, some of them are supposed to be bold and some are supposed to be italics. I can make the whole list bold by highlighting the symbol in the template, but that doesn't work for my use case
Your Environment
- Python version: 3.5
- docx-mailmerge version: 0.4.0
Thank you!
@Bouke please let me know if my edit is incorrect
Well it would be a nice feature to have, sure. And I'd welcome a good PR that adds such a feature.