Closed ChrisBellBO closed 2 months ago
Shouldn't it be property in Section counting elements in section and then in Document merging the sections?
Possibly but I don't currently have any interest in sections so I'd be pulling apart into sections to recombine into the document
if you don't want to incorporate this into the library code base, I can implement it in my own code base if ConvertParagraphToWordParagraphs and the WordTable constructor taking a WordDocument and Table are made public?
I need to sit down and understand/test if this can be approved in current form or with changes. In the end I would like to have this ability just want to make sure we cover the basics of Sections/Documents orderwhich is what most users will require. I do understand that you have your own temporary need or later lack of need for sections, but this would mean I need to change it later anyways. So I will try to spend some time on it, see how you did it and whether it's working as expected and then let you know.
Don't worry. Either way you'll get your functionality as I believe it's needed.
Hi,
I had some time and reviewed your code for Elements and it wasn't covering some cases.
allElements = document.AllElements();
elements = document.Elements;
I still need to do some work, but we should have something solid soon. I may also add something like ElementsExpanded or so where it tries to convert WordParagraph to actual subtype, but I am not sure if it's worth the effort.
So, to summarize this PR:
Elements
property in Document\SectionElementsByType
property in Document\SectionHasNestedTables
and `NestedTables properties to WordTableCellVerticalTextAlignment
in Paragraph which allows for Baseline/Subscript/SuperscriptSetVerticalTextAlignment()
methodSetSubscript()
methodSetSuperScript()
methodI also changed behavior of VerticalTextAlignment so that if it's not set it should be null, and if it's explicitly set to Baseline it shows baseline. Setting it to null should clear the value as well
Sorry for changing quite a bit, hopefully this will be useful to you too.
Added AllElements method that works with all test documents, although I suspect there may be better ways to handle some of the elements and there are no doubt other elements we are currently ignoring