-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SDT bind and removal extensions for Footnotes and Endnotes #266
base: master
Are you sure you want to change the base?
Conversation
…r FootnotesPart and EndnotesPart. This makes it possible to bind values in these parts as well as remove SDT's from the parts if requested. WML parts for EndnotesPart and FootnotesPart implements ContentAccessor (again..). Docx4J now used RemoveHandler to remove SDT's from supported parts (Main, Footer, Header, Footnotes, Endnotes)
…r FootnotesPart and EndnotesPart. This makes it possible to bind values in these parts as well as remove SDT's from the parts if requested. WML parts for EndnotesPart and FootnotesPart implements ContentAccessor (again..). Docx4J now used RemoveHandler to remove SDT's from supported parts (Main, Footer, Header, Footnotes, Endnotes)
* Convenience method to getJaxbElement().getEndnote() | ||
* @since 2.8.1 | ||
*/ | ||
public List<Object> getContent() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By the look of it, this won't work properly. getContent().add(foo) doesn't add foo to the endnote object
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've tried to let FootnotePart and EndnotePart implement the same ContentAccessor as FooterPart and HeaderPart, to handle each part in a similar way. In some previous version, the getContent() method has been un-commented. Is it possible to let FootnotePart and EnddnotePart implement ContentAccessor in a proper way?
If it's not possible to let FootnotePart and EndnotePart implement ContentAccessor, this particullar change can be reverted. The most important part, is the ability to update content controls bindings in these parts.
…art now implements ContentAccessor in a proper way. All this to support OpenDope processing of SDTs in Footnotes and Endnotes part
HI,
I hope this pull request is created properly.
I've added some extension to Docx4J SDT binding- and removal- handlers, to support FootnotesPart and EndnotesPart. This makes it possible to bind values in these parts as well as remove SDT's from these parts, if requested in the bind-flags. WML parts for EndnotesPart and FootnotesPart implements ContentAccessor (again..). Docx4J now uses RemoveHandler to remove SDT's from supported parts (Main, Footer, Header, Footnotes, Endnotes)
I hope you'll incorporate these changes in a futurer build, or make a similar extension. I need this extension, to be able to use SDT's in footnotes and endnotes.
Thanks a lot.