diff --git a/src/tex2lyx/Preamble.cpp b/src/tex2lyx/Preamble.cpp index 09ef31b631..6e6e3d0245 100644 --- a/src/tex2lyx/Preamble.cpp +++ b/src/tex2lyx/Preamble.cpp @@ -124,8 +124,8 @@ const char * const known_old_language_packages[] = {"french", "frenchle", char const * const known_fontsizes[] = { "10pt", "11pt", "12pt", 0 }; const char * const known_roman_fonts[] = { "ae", "beraserif", "bookman", -"ccfonts", "chancery", "charter", "cmr", "fourier", "lmodern", "mathpazo", -"mathptmx", "newcent", "utopia", 0}; +"ccfonts", "chancery", "charter", "cmr", "fourier", "lmodern", +"mathdesign", "mathpazo", "mathptmx", "newcent", "utopia", 0}; const char * const known_sans_fonts[] = { "avant", "berasans", "cmbr", "cmss", "helvet", "kurier", "kurierl", "lmss", 0}; @@ -669,6 +669,20 @@ void Preamble::handle_package(Parser &p, string const & name, h_font_sc = "true"; } + if (name == "mathdesign") { + // when font uses real small capitals + if (opts.find("charter") != string::npos) + h_font_roman = "md-charter"; + if (opts.find("garamond") != string::npos) + h_font_roman = "md-garamond"; + if (opts.find("utopia") != string::npos) + h_font_roman = "md-utopia"; + if (opts.find("expert") != string::npos) { + h_font_sc = "true"; + h_font_osf = "true"; + } + } + else if (name == "mathpazo") h_font_roman = "palatino"; diff --git a/src/tex2lyx/TODO.txt b/src/tex2lyx/TODO.txt index 9a8459eadf..4bb98cdfba 100644 --- a/src/tex2lyx/TODO.txt +++ b/src/tex2lyx/TODO.txt @@ -64,7 +64,6 @@ Format LaTeX feature LyX feature 434 libertine-type1, libertine.sty, \font_osf, \font_roman libertine-legacy.sty 435 txtt LaTeX font \font_typewriter -436 mathdesign.sty \font_roman 437 TeX Gyre LaTeX fonts \font_* 438 \tone{51}, \tone{15}, \tone{45}, InsetTIPA \tone{12}, \tone{454}, \toptiebar,