+2004-10-20 Georg Baum <Georg.Baum@post.rwth-aachen.de>
+
+ * text.C (parse_text): replace newlines with spaces in arguments to
+ known latex commands, fixes bug 1620
+
2004-10-12 Georg Baum <Georg.Baum@post.rwth-aachen.de>
* preamble.C (end_preamble): change file format from 236 to 237
context.check_layout(os);
begin_inset(os, "LatexCommand ");
os << '\\' << t.cs();
- os << p.getOpt();
- os << p.getOpt();
- os << '{' << p.verbatim_item() << "}\n";
+ // lyx cannot handle newlines in a latex command
+ // FIXME: Move the substitution into parser::getOpt()?
+ os << subst(p.getOpt(), "\n", " ");
+ os << subst(p.getOpt(), "\n", " ");
+ os << '{' << subst(p.verbatim_item(), "\n", " ") << "}\n";
end_inset(os);
}