The branch, master, has been updated.

- Log -----------------------------------------------------------------

commit 56e6549b11bbba857fba1fe620b589b9b923d456
Merge: 719ec62 4dd86ad
Author: Juergen Spitzmueller <sp...@lyx.org>
Date:   Sat Aug 25 10:49:08 2012 +0200

    Merge branch 'master' of git.lyx.org:lyx


commit 719ec62e28ee9ec6caaab5f0e89a62a180f45524
Author: Juergen Spitzmueller <sp...@lyx.org>
Date:   Sat Aug 25 10:48:37 2012 +0200

    Fix thinkos in LaTeX font reading

diff --git a/src/LaTeXFonts.cpp b/src/LaTeXFonts.cpp
index b165258..b603f81 100644
--- a/src/LaTeXFonts.cpp
+++ b/src/LaTeXFonts.cpp
@@ -394,8 +394,14 @@ LaTeXFonts::TexFontMap LaTeXFonts::getLaTeXFonts()
 
 LaTeXFont LaTeXFonts::getLaTeXFont(docstring const & name)
 {
+       if (name == "default")
+               return LaTeXFont();
        if (texfontmap_.empty())
                readLaTeXFonts();
+       if (texfontmap_.find(name) == texfontmap_.end()) {
+               LYXERR0("LaTeXFonts::getLaTeXFont: font '" << name << "' not 
found!");
+               return LaTeXFont();
+       }
        return texfontmap_[name];
 }
 
diff --git a/src/frontends/qt4/GuiDocument.cpp 
b/src/frontends/qt4/GuiDocument.cpp
index ee39809..6ccc86e 100644
--- a/src/frontends/qt4/GuiDocument.cpp
+++ b/src/frontends/qt4/GuiDocument.cpp
@@ -1840,8 +1840,10 @@ void GuiDocument::updateTexFonts()
        LaTeXFonts::TexFontMap::const_iterator end = texfontmap.end();
        for (; it != end; ++it) {
                LaTeXFont lf = it->second;
-               if (lf.name().empty())
-                       return;
+               if (lf.name().empty()) {
+                       LYXERR0("Error: Unnamed font: " << it->first);
+                       continue;
+               }
                docstring const family = lf.family();
                docstring guiname = translateIfPossible(lf.guiname());
                if (!lf.available(ot1()))

-----------------------------------------------------------------------

Summary of changes:
 src/LaTeXFonts.cpp                |    6 ++++++
 src/frontends/qt4/GuiDocument.cpp |    6 ++++--
 2 files changed, 10 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
The LyX Source Repository

Reply via email to