diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2005-05-01 22:00:40 +0000 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2005-05-01 22:00:40 +0000 |
commit | b05628214d64e579504c87da72e79c024245a631 (patch) | |
tree | 33da048fed86f171d2b260de78ad8d9cc58ccec9 /src | |
parent | c2aaa8d105c0f2378a233a3f992633ccdf40da1d (diff) | |
download | mana-b05628214d64e579504c87da72e79c024245a631.tar.gz mana-b05628214d64e579504c87da72e79c024245a631.tar.bz2 mana-b05628214d64e579504c87da72e79c024245a631.tar.xz mana-b05628214d64e579504c87da72e79c024245a631.zip |
Catch exception to put some message through to the user.
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/gui.cpp | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/src/gui/gui.cpp b/src/gui/gui.cpp index c9f7e571..97423af6 100644 --- a/src/gui/gui.cpp +++ b/src/gui/gui.cpp @@ -64,10 +64,18 @@ Gui::Gui(Graphics *graphics): setTop(guiTop); // Set global font - guiFont = new gcn::ImageFont(TMW_DATADIR "data/graphics/gui/fixedfont.png", - " abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789:@" - "!\"$%&/=?^+*#[]{}()<>_;'.,\\|-~`" - ); + try { + guiFont = new gcn::ImageFont( + TMW_DATADIR "data/graphics/gui/fixedfont.png", + " abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ01234567" + "89:@!\"$%&/=?^+*#[]{}()<>_;'.,\\|-~`" + ); + } + catch (gcn::Exception e) + { + logger.error("Unable to load fixedfont.png!"); + } + gcn::Widget::setGlobalFont(guiFont); } |