Nov 26 2013

docx4j 3.0 released

On behalf of everyone who has contributed to docx4j, Plutext is pleased to announce that version 3 was released today.

You can get it from Maven Central, or from (the jar, the dependencies, or everything including documentation zipped up)

Source code is available at GitHub or from the Maven Central link above.  Javadoc is at Maven Central.

For what you need to know about docx4j 3.0, please see this post.

The XHTML Import stuff is now a separate project (since it and its dependencies are LGPL, not ASLv2 like docx4j).

  • the three jars you need (docx4j-ImportXHTML, xhtmlrenderer, and iText) are included for convenience in the zip file above.  You can delete them if you don’t need or want XHTML import.
  • or you can get it from Maven Central

docx4j 3.0 uses slf4j for logging.  For convenience, log4j is the default implementation.  A follow-up post will explain more about logging config.

Thanks to everyone who has helped to make this release our best yet!

If you have questions pertaining to the use of docx4j, please post them in our forum, or on StackOverflow (rather than in comments to this post).

2 Responses so far

  1. 1

    Atul said,

    November 27, 2013 @ 5:12 pm

    I downloaded docx4j 3.0 and I am trying to modifying texts using ${var_name}. I inspected the document.xml and no mater what I disable (grammar, auto-correct, spelling), I still get ${ split over multiple nodes. I believe new code was developed to handle this in XmlUtils.unmarshallFromTemplate(xml, mappings);

    However, I keep getting following Warnings. I have also disabled “Tracking” and accepted all changes. Is the unmarshallFromTemplate broken in 3.0? I see the code in 2.8 code base.

    WARN org.docx4j.XmlUtils .replace line 451 – Invalid key ‘

    ProviderName’ or key not mapped to a value
    WARN org.docx4j.XmlUtils .replace line 451 – Invalid key ‘

    ProviderName’ or key not mapped to a value

  2. 2

    Jason said,

    November 27, 2013 @ 6:28 pm

    You can use

    See the main method at the end.

    Looks like your key has whitespace in it?

    Please post any followup comment to the docx4j forum, or on StackOverflow.

    Your comment here and my reply will be deleted in due course.

Comment RSS