You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by "pjfanning (via GitHub)" <gi...@apache.org> on 2026/04/06 10:00:33 UTC

Re: [PR] Fix Bug 66263 — Add support for reading SDT row in tables [poi]

pjfanning commented on code in PR #971:
URL: https://github.com/apache/poi/pull/971#discussion_r3038902865


##########
poi-ooxml/src/main/java/org/apache/poi/xwpf/usermodel/XWPFParagraph.java:
##########
@@ -138,10 +138,22 @@ private void buildRunsInOrderFromXml(XmlObject object) {
                 if (o instanceof CTSdtBlock) {
                     XWPFSDT cc = new XWPFSDT((CTSdtBlock) o, part);
                     iruns.add(cc);
+                    CTSdtContentBlock content = ((CTSdtBlock)o).getSdtContent();
+                    if (content != null) {
+                        for (CTP ctp : content.getPList()) {
+                            processCTRs(ctp.getRList());
+                        }
+                    }
                 }
                 if (o instanceof CTSdtRun) {
-                    XWPFSDT cc = new XWPFSDT((CTSdtRun) o, part);
-                    iruns.add(cc);
+                        XWPFSDT cc = new XWPFSDT((CTSdtRun)o, part);

Review Comment:
   can you fix the indentation?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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