]> source.dussan.org Git - poi.git/commitdiff
Fonts bugfix
authorAndreas Beeker <kiwiwings@apache.org>
Mon, 24 Jul 2017 05:39:33 +0000 (05:39 +0000)
committerAndreas Beeker <kiwiwings@apache.org>
Mon, 24 Jul 2017 05:39:33 +0000 (05:39 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1802751 13f79535-47bb-0310-9956-ffa450edef68

src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFTextRun.java
src/ooxml/testcases/org/apache/poi/sl/TestFonts.java

index d5d57312f28bd219ca98f66015d0e953e688029c..8124ccff1c23c440c86ebaff2cca9e3da5a7193e 100644 (file)
@@ -848,7 +848,7 @@ public class XSLFTextRun implements TextRun {
                 }
                 // SYMBOL is missing
                 
-                if (font != null || !font.isSetTypeface() || "".equals(font.getTypeface())) {
+                if (font == null || !font.isSetTypeface() || "".equals(font.getTypeface())) {
                     font = coll.getLatin();
                 }
             }
index 8b5afc5b8aeb079bd379104790bb8a5a54d774f0..12be322500379bfc1a3dd3e0731b230f6de3f426 100644 (file)
@@ -72,7 +72,7 @@ public class TestFonts {
     private static final String INIT_FONTS[] = { "mona.ttf" };
 
     // currently linux and mac return quite different values
-    private static final int[] expected_sizes = { 311, 312, 313,
+    private static final int[] expected_sizes = { 311, 312, 313, 318,
             362, // Windows 10, 13.3" 1080p high-dpi
             398, 399,
             406  // Ubuntu Trusty, 15", 1680x1050