Mercurial > fife-parpg
changeset 207:40257a6dc57d
PyChan: Meaningful error if a font wasn't loaded.
author | phoku@33b003aa-7bff-0310-803a-e67f0ece8222 |
---|---|
date | Sun, 15 Mar 2009 18:34:49 +0000 |
parents | 6214a0b91eb2 |
children | e281223a03a6 |
files | engine/extensions/pychan/internal.py |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/engine/extensions/pychan/internal.py Sat Mar 14 12:32:11 2009 +0000 +++ b/engine/extensions/pychan/internal.py Sun Mar 15 18:34:49 2009 +0000 @@ -1,4 +1,4 @@ -# coding: utf-8 +# -*- coding: utf-8 -*- from compat import guichan, in_fife import widgets @@ -91,7 +91,7 @@ return font if hasattr(font,"font") and isinstance(getattr(font,"font"),guichan.GuiFont): return font.font - return fonts.parseFontSpec(name) + raise InitializationError("Couldn't find the font '%s' - did you forget loading a .fontdef?" % str(name)) else: return self.hook.get_font(name)