Bug 47148 - XWPFRun.setFontFamily does not work with chars above 127.
Summary: XWPFRun.setFontFamily does not work with chars above 127.
Status: CLOSED WORKSFORME
Alias: None
Product: POI
Classification: Unclassified
Component: XWPF (show other bugs)
Version: 3.5-dev
Hardware: PC Windows XP
: P2 normal (vote)
Target Milestone: ---
Assignee: POI Developers List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-05-04 06:30 UTC by luzifer
Modified: 2016-10-05 03:20 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description luzifer 2009-05-04 06:30:46 UTC
XWPFDocument doc = new XWPFDocument();
XWPFParagraph paragraph = doc.createParagraph();
XWPFRun run = paragraph.createRun();
run.setText("abc éàèô efg");
run.setFontSize(10);      //NullPointerException if ommitted
run.setFontFamily("Arial");


MyWorkaround:
not only set the Ascii Font, but also set the HAnsi font. (CTFonts.setHAnsi)
Comment 1 Mark Murphy 2016-10-05 03:20:16 UTC
This works for me. Please try using the most recent version of POI, and if you continue having problems, open a new issue.