X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2FFontLoader.C;h=6f1480c31488beedfe88af2578db2412bb0b2295;hb=a858be7332e331e0244e4dba7b0931b6072ffd3d;hp=a46495f16bf9f503b39681b79462165bc2457dee;hpb=27de1486ca34aaad446adb798d71a77d6f6304da;p=lyx.git diff --git a/src/FontLoader.C b/src/FontLoader.C index a46495f16b..6f1480c314 100644 --- a/src/FontLoader.C +++ b/src/FontLoader.C @@ -10,8 +10,8 @@ *======================================================*/ #include -#include // fabs() -#include // atoi() +#include // fabs() +#include // atoi() #ifdef __GNUG__ #pragma implementation "FontLoader.h" @@ -20,7 +20,7 @@ #include "gettext.h" #include "FontLoader.h" #include "FontInfo.h" -#include "error.h" +#include "debug.h" #include "lyxrc.h" // lyxrc.font_* extern LyXRC * lyxrc; #include "minibuffer.h" @@ -98,11 +98,11 @@ void FontLoader::getFontinfo(LyXFont::FONT_FAMILY family, } // Normal font. Let's search for an existing name that matches. - LString ffamily; - LString fseries; - LString fshape; - LString norm = lyxrc->font_norm; - LString fontname; + string ffamily; + string fseries; + string fshape; + string norm = lyxrc->font_norm; + string fontname; FontInfo * fi = new FontInfo(); fontinfo[family][series][shape] = fi; @@ -205,11 +205,11 @@ XFontStruct* FontLoader::doLoad(LyXFont::FONT_FAMILY family, int fsize = (int) ( (lyxrc->font_sizes[size] * lyxrc->dpi * (lyxrc->zoom/100.0) ) / 72.27 + 0.5 ); - LString font = fontinfo[family][series][shape]->getFontname(fsize); + string font = fontinfo[family][series][shape]->getFontname(fsize); if (font.empty()) { - lyxerr.print("No font matches request. Using 'fixed'."); - lyxerr.print("Start LyX as 'lyx -dbg 515' to get more information."); + lyxerr << "No font matches request. Using 'fixed'." << endl; + lyxerr << "Start LyX as 'lyx -dbg 515' to get more information." << endl; font = "fixed"; } @@ -220,13 +220,13 @@ XFontStruct* FontLoader::doLoad(LyXFont::FONT_FAMILY family, if (fs == 0) { if (font=="fixed") { - lyxerr.print("We're doomed. Can't get 'fixed' font."); + lyxerr << "We're doomed. Can't get 'fixed' font." << endl; } else { - lyxerr.print("Could not get font. Using 'fixed'."); + lyxerr << "Could not get font. Using 'fixed'." << endl; fs = XLoadQueryFont(fl_display, "fixed"); } } else { - if (lyxerr.debugging(Error::FONT)) { + if (lyxerr.debugging(Debug::FONT)) { // Tell user the font matching LyXFont f; f.setFamily(family); @@ -239,8 +239,8 @@ XFontStruct* FontLoader::doLoad(LyXFont::FONT_FAMILY family, f.setNoun(LyXFont::INHERIT); f.setLatex(LyXFont::INHERIT); f.setColor(LyXFont::INHERIT_COLOR); - lyxerr.print(LString("Font '") + f.stateText() - + "' matched by\n" + font + '\n'); + lyxerr << "Font '" << f.stateText() + << "' matched by\n" << font << endl; } } minibuffer->Reset();