Summary: | XWPFTableCell.getCell() creates an unecessary Paragraph | ||
---|---|---|---|
Product: | POI | Reporter: | luzifer |
Component: | XWPF | Assignee: | POI Developers List <dev> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | P2 | ||
Version: | 3.5-dev | ||
Target Milestone: | --- | ||
Hardware: | PC | ||
OS: | Windows XP | ||
Attachments: | Fix issues with "setText". |
Description
luzifer
2009-05-04 06:15:05 UTC
Patch in progress, coming soon. Created attachment 26963 [details]
Fix issues with "setText".
Looking into the ECM-576 specification, an empty cell always comes with an empty paragraph. Or, to use Word as reference, create an empty Word DOCX document, add a table with 2 rows and 2 coloums, save the document and look into the XML. You'll see that Word creates an empty Paragraph for each Cell.
What was wrong in the XWPFCell class was the "setText" method. Fixed this method and another bug in the contructor. There every row created was added to the "rows" field twice. Once in "createRow" method and afterwards in the constructor.
|