From e99870759dc603bcce21a792ed30a4b227f11527 Mon Sep 17 00:00:00 2001 From: "Steinar H. Gunderson" Date: Sat, 19 Feb 2005 12:24:03 +0000 Subject: [PATCH] FreeType initialization errors are runtime errors, not logic errors. --- bigscreen/ccbs_bigscreen.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/bigscreen/ccbs_bigscreen.cpp b/bigscreen/ccbs_bigscreen.cpp index d71b4c1..8e09f0d 100644 --- a/bigscreen/ccbs_bigscreen.cpp +++ b/bigscreen/ccbs_bigscreen.cpp @@ -153,15 +153,15 @@ void init_freetype() { FT_Library library; if (FT_Init_FreeType(&library)) - throw std::logic_error("FreeType init failed."); + throw std::runtime_error("FreeType init failed."); if (FT_New_Face(library, "/usr/share/fonts/truetype/msttcorefonts/Georgia.ttf", 0, &font)) - throw std::logic_error("Face opening failed."); + throw std::runtime_error("Face opening failed."); if (FT_New_Face(library, "/usr/share/fonts/truetype/freefont/FreeSerif.ttf", 0, &symbolfont)) - throw std::logic_error("Face opening failed."); + throw std::runtime_error("Face opening failed."); if (FT_Set_Char_Size(font, 0, 12 * 64, 96, 96)) - throw std::logic_error("Size set failed."); + throw std::runtime_error("Size set failed."); if (FT_Set_Char_Size(symbolfont, 0, 12 * 64, 96, 96)) - throw std::logic_error("Size set failed."); + throw std::runtime_error("Size set failed."); } int my_draw_text(const widestring &str, unsigned char *buf, int xpos, int ypos, bool real_render, int r, int g, int b, FT_Face face, FT_Face symbolface) -- 2.39.2