Skip to content

SDT bind and removal extensions for Footnotes and Endnotes#266

Open
jaboj78 wants to merge 4 commits into
plutext:masterfrom
jaboj78:sdt-bind-removal-ext
Open

SDT bind and removal extensions for Footnotes and Endnotes#266
jaboj78 wants to merge 4 commits into
plutext:masterfrom
jaboj78:sdt-bind-removal-ext

Conversation

@jaboj78

@jaboj78 jaboj78 commented Oct 4, 2017

Copy link
Copy Markdown

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.

  • Jacob

…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() {

Copy link
Copy Markdown
Owner

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

Copy link
Copy Markdown
Author

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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants