Open Marcel0024 opened 1 year ago
I do not know (because I do not use it much)
But I think that if the placeholder already has styles applied (like bold/italic/underline) then DocumentAssemblier should insert text and preserve styles. Is not it?
Yes it does. But that's for the whole variable. I want to add a big paragraph and format the text myself. So a long text with bold/italic a few words.
How complicated is your template document? Maybe you can use DocumentBuilder
API?
You can generate Word document with arbitrary formatting and then merge multiple documents into one using DocumentBuilder.
Nice suggestion, but I don't think it will work. My templates are quite complicated. Users fill in their profile and can generate a Word document out of it with the company styling. So, some paragraphs inside tables need some formatting by the users.
Then I probably have nothing to offer ...
Maybe HtmlToWmlConverter.ConvertHtmlToWml
? Generate HTML and convert it to Word? (never used this part of the library myself)
I am looking for a suitable home for a number of improvements that I have made to OpenXmlPowerTools over the years. One of the improvements is to support some inline formatting from HTML, including:
I would be happy to open a PR here if you have the time to review / merge it?
@MalcolmJohnston Sure, PRs are more than welcome, especially if they are relatively small, keep build green and ideally contain some tests 😀
I couldn't find a way to format text in the document assembler. rtf/markdown/html or anything? Am i correct in this?
I'm willing to take a stab at it, with some guidance, does it happen anywhere else in the library that i can look how it should be done?
With some formatting, like bold, italic, underline and list would make this killer library.