poi-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject [Bug 54849] Controlled content/Form (Std/StdBlock) content is not processed
Date Tue, 16 Apr 2013 01:43:09 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=54849

Tim Allison <tallison@mitre.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 OS|                            |All

--- Comment #1 from Tim Allison <tallison@mitre.org> ---
A quick fix is to add:


else if ( o instanceof CTSdtBlock){
                    CTSdtBlock block = (CTSdtBlock)o;
                    CTSdtContentBlock content = block.getSdtContent();
                    List<CTP> ctps = content.getPList();

                    for (CTP ctp : ctps){
                         XWPFParagraph p = new XWPFParagraph((CTP) ctp, this);
                         bodyElements.add(p);
                         paragraphs.add(p);
                    }
                    List<CTTbl> cttables = content.getTblList();
                    for (CTTbl table : cttables){
                        XWPFTable t = new XWPFTable((CTTbl) table, this);
                        bodyElements.add(t);
                        tables.add(t);
                    }
                }

after:
 else if (o instanceof CTTbl) {
                    XWPFTable t = new XWPFTable((CTTbl) o, this);
                    bodyElements.add(t);
                    tables.add(t);
                }

in XWPFDocument's onDocumentRead

If someone can help me add a few files to poi-ooxml-schemas from the larger
ooxml-schemas-1.1.jar, I'll be happy to submit a formal patch.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


Mime
View raw message