[poppler] splash/SplashFTFont.cc

Albert Astals Cid aacid at kemper.freedesktop.org
Fri Feb 25 12:31:10 PST 2011


 splash/SplashFTFont.cc |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

New commits:
commit 97e7ab1a4eea2160f3f0847d10f6c16f2d66ef11
Author: Albert Astals Cid <aacid at kde.org>
Date:   Fri Feb 25 20:33:39 2011 +0000

    Do not ask freetype for a font of size 0x0
    
    Fixes rendering bug at 34602

diff --git a/splash/SplashFTFont.cc b/splash/SplashFTFont.cc
index a69da6e..eea3d64 100644
--- a/splash/SplashFTFont.cc
+++ b/splash/SplashFTFont.cc
@@ -11,7 +11,7 @@
 // All changes made under the Poppler project to this file are licensed
 // under GPL version 2 or later
 //
-// Copyright (C) 2005, 2007-2010 Albert Astals Cid <aacid at kde.org>
+// Copyright (C) 2005, 2007-2011 Albert Astals Cid <aacid at kde.org>
 // Copyright (C) 2006 Kristian Høgsberg <krh at bitplanet.net>
 // Copyright (C) 2009 Petr Gajdos <pgajdos at novell.com>
 // Copyright (C) 2010 Suzuki Toshiya <mpsuzuki at hiroshima-u.ac.jp>
@@ -71,6 +71,9 @@ SplashFTFont::SplashFTFont(SplashFTFontFile *fontFileA, SplashCoord *matA,
   }
   face->size = sizeObj;
   size = splashSqrt(mat[2]*mat[2] + mat[3]*mat[3]);
+  if ((int)size < 1) {
+    size = 1;
+  }
   if (FT_Set_Pixel_Sizes(face, 0, (int)size)) {
     return;
   }


More information about the poppler mailing list