diff --git a/src/tex2lyx/ChangeLog b/src/tex2lyx/ChangeLog index ae984a25d9..abc8f1e42a 100644 --- a/src/tex2lyx/ChangeLog +++ b/src/tex2lyx/ChangeLog @@ -1,3 +1,8 @@ +2004-07-23 Georg Baum + + * math.C (parse_math): change tex "\\cr" line ending to "\\\\" + * table.C (parse_table): recognize tex "\\cr" line ending + 2004-06-28 Georg Baum * math.C, preamble.C, tex2lyx.[Ch], text.C: const fixes diff --git a/src/tex2lyx/math.C b/src/tex2lyx/math.C index b9458e07ef..eb57b1b822 100644 --- a/src/tex2lyx/math.C +++ b/src/tex2lyx/math.C @@ -216,6 +216,13 @@ void parse_math(Parser & p, ostream & os, unsigned flags, const mode_type mode) else if (t.cs() == "ss") os << "ß"; + else if (t.cs() == "cr") { + // lyx can't handle \\cr + cerr << "Warning: Converting TeX '\\cr' to LaTeX '\\\\'." + << endl; + os << "\\\\"; + } + else os << t.asInput(); diff --git a/src/tex2lyx/table.C b/src/tex2lyx/table.C index 18579870d5..05e1122c52 100644 --- a/src/tex2lyx/table.C +++ b/src/tex2lyx/table.C @@ -220,7 +220,11 @@ void parse_table(Parser & p, ostream & os, unsigned flags) p.skip_spaces(); } - else if (t.cs() == "tabularnewline" || t.cs() == "\\") { + else if (t.cs() == "tabularnewline" || t.cs() == "\\" || + t.cs() == "cr") { + if (t.cs() == "cr") + cerr << "Warning: Converting TeX '\\cr' to LaTeX '\\\\'." + << endl; // stuff before the line break // and look ahead for stuff after the line break os << HLINE << hlines << HLINE << LINE << read_hlines(p) << HLINE;