Summary: | [PATCH] XWPFNumbering and XWPFStyles classes lack a constructor that doesn't call onDocumentRead | ||
---|---|---|---|
Product: | POI | Reporter: | Mike McEuen <mceuen> |
Component: | XWPF | Assignee: | POI Developers List <dev> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | P2 | ||
Version: | 3.7-FINAL | ||
Target Milestone: | --- | ||
Hardware: | All | ||
OS: | All | ||
Attachments: |
Changes in tar.gz format
Diff Unit tests for creating and adding Numberings and Styles to a new document. |
Description
Mike McEuen
2011-04-28 10:26:36 UTC
Created attachment 27042 [details]
Changes in tar.gz format
Allow new XWPFDocuments to create Numbering and Styles elements from scratch. Previously, these elements could only be modified if read in from existing an existing docx. This patch also contains new methods to XWPFStyles to set default spelling language and font properties. These changes can be moved to a different patch/bug if necessary.
Created attachment 27043 [details]
Diff
Thanks, committed in r1128296. Any chance you could knock up a quick unit test for this? A test that springs to mind is to create a doc, add the numbering and styles and set these. Then, save it and re-open it in XWPF, and check the expected things are all there Created attachment 27268 [details]
Unit tests for creating and adding Numberings and Styles to a new document.
As per Nick's suggestion, here are some unit tests for the functionality I added.
|