]> git.lyx.org Git - lyx.git/blobdiff - src/LaTeXFeatures.cpp
Try to deal with one of the big problems here, namely, that we
[lyx.git] / src / LaTeXFeatures.cpp
index e39dc92bb7d15cfd1dc44a1d6fb9ee26f0754f4b..81bebfdeda7416f63ae6ea4d66fc07a0ec5100de 100644 (file)
@@ -182,12 +182,12 @@ static docstring const changetracking_dvipost_def = from_ascii(
 
 static docstring const changetracking_xcolor_ulem_def = from_ascii(
        "%% Change tracking with ulem\n"
-       "\\newcommand{\\lyxadded}[3]{{\\color{lyxadded}#3}}\n"
+       "\\newcommand{\\lyxadded}[3]{{\\color{lyxadded}{}#3}}\n"
        "\\newcommand{\\lyxdeleted}[3]{{\\color{lyxdeleted}\\sout{#3}}}\n");
 
 static docstring const changetracking_xcolor_ulem_hyperref_def = from_ascii(
        "%% Change tracking with ulem\n"
-       "\\newcommand{\\lyxadded}[3]{{\\texorpdfstring{\\color{lyxadded}}{}#3}}\n"
+       "\\newcommand{\\lyxadded}[3]{{\\texorpdfstring{\\color{lyxadded}{}}{}#3}}\n"
        "\\newcommand{\\lyxdeleted}[3]{{\\texorpdfstring{\\color{lyxdeleted}\\sout{#3}}{}}}\n");
 
 static docstring const changetracking_none_def = from_ascii(
@@ -195,8 +195,11 @@ static docstring const changetracking_none_def = from_ascii(
        "\\newcommand{\\lyxdeleted}[3]{}\n");
 
 static docstring const textgreek_def = from_ascii(
-       "\\DeclareRobustCommand{\\greektext}{%\n"
-       "  \\fontencoding{LGR}\\selectfont\\def\\encodingdefault{LGR}}\n"
+       "\\providecommand*{\\perispomeni}{\\char126}\n"
+       "\\AtBeginDocument{\\DeclareRobustCommand{\\greektext}{%\n"
+       "  \\fontencoding{LGR}\\selectfont\\def\\encodingdefault{LGR}%\n"
+       "  \\renewcommand{\\~}{\\perispomeni}\n"
+       "}}\n"
        "\\DeclareRobustCommand{\\textgreek}[1]{\\leavevmode{\\greektext #1}}\n"
        "\\DeclareFontEncoding{LGR}{}{}\n");
 
@@ -365,12 +368,10 @@ void LaTeXFeatures::useInsetLayout(InsetLayout const & lay)
 {
        docstring const & lname = lay.name();
        DocumentClass const & tclass = params_.documentClass();
-       if (!tclass.hasInsetLayout(lname)) {
-               lyxerr << "LaTeXFeatures::useInsetLayout: layout `"
-                      << to_utf8(lname) << "' does not exist in this class"
-                      << endl;
+
+       // this is a default inset layout, nothing useful here
+       if (!tclass.hasInsetLayout(lname))
                return;
-       }
        // Is this layout already in usedInsetLayouts?
        if (find(usedInsetLayouts_.begin(), usedInsetLayouts_.end(), lname) 
                        != usedInsetLayouts_.end())