0
我想为同一段落设置多个样式,只应用一种样式。我想应用多种风格如何使用apache poi将多个样式设置为单词段落
XWPFDocument document = new XWPFDocument(new FileInputStream("D:\\LatestStyleTemplates.docx"));
out = new FileOutputStream(new File("D:\\createdocument.docx"));
XWPFParagraph article = document.createParagraph();
XWPFParagraph title = document.createParagraph();
XWPFParagraph endnoteText = document.createParagraph();
XWPFParagraph heading1 = document.createParagraph();
endnoteText.setStyle("Strong");
endnoteText.setStyle("EndnoteText");
Microsoft Word甚至允许您这样做吗? – Gagravarr