From 7a5683af31a07f914a48641463ae3a1181741919 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=B6rg=20Lehmann?= Date: Mon, 22 Oct 2007 20:36:13 +0000 Subject: [PATCH] make warnings more explicit concerning the font they refer to (although this leads to them being displayed once for every font) git-svn-id: https://pyx.svn.sourceforge.net/svnroot/pyx/trunk/pyx@2931 069f4177-920e-0410-937b-c2a4a81bcd90 --- pyx/font/t1file.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pyx/font/t1file.py b/pyx/font/t1file.py index 0921c78c..351aeb8b 100644 --- a/pyx/font/t1file.py +++ b/pyx/font/t1file.py @@ -1019,7 +1019,7 @@ class T1file: glyphinfo_period = self.getglyphinfo("period") glyphinfo_colon = self.getglyphinfo("colon") except: - warnings.warn("Auto-guessing font information failed. We're writing stub data instead.") + warnings.warn("Auto-guessing of font information for font '%s' failed. We're writing stub data instead." % self.name) file.write("/Flags 4\n") file.write("/FontBBox [0 -100 0 1000]\n") file.write("/ItalicAngle 0\n") @@ -1045,7 +1045,7 @@ class T1file: file.write("/StemV %f\n" % (glyphinfo_period[4]-glyphinfo_period[2])) def getglyphinfo(self, glyph): - warnings.warn("We are about to extract font information from a type 1 font directly. This is bad practice (and it's slow). You should use an afm file instead.") + warnings.warn("We are about to extract font information for the Type 1 font '%s' from its pfb file. This is bad practice (and it's slow). You should use an afm file instead." % self.name) context = T1context(self) p = path() self.updateglyphpath(glyph, p, trafo.trafo(), context) -- 2.11.4.GIT