我正在尝试使用apache poi在java中读取Word文档,但是当它遇到MS字符号列表中的符号时,它在字符串中显示为空格。以下是我正在使用的代码
WPFDocument doc = new XWPFDocument(new FileInputStream(fileName));
XWPFWordExtractor ex = new XWPFWordExtractor(doc);
List<XWPFParagraph> xwpfParagraphs=doc.getParagraphs();
for(XWPFParagraph xwpfParagraph:xwpfParagraphs)
{
System.out.println("paragraph");
System.out.println(xwpfParagraph.getParagraphText());
}