-/** The .tex to .lyx converter
- \author André Pönitz (2003)
+/**
+ * \file tex2lyx.C
+ * This file is part of LyX, the document processor.
+ * Licence details can be found in the file COPYING.
+ *
+ * \author André Pönitz
+ *
+ * Full author contact details are available in file CREDITS.
*/
// {[(
+#include <config.h>
+
#include "tex2lyx.h"
+#include "context.h"
#include "debug.h"
#include "lyx_main.h"
#include <sstream>
#include <vector>
+using std::endl;
using std::cout;
using std::cerr;
-using std::endl;
using std::getline;
-using std::istream;
+
using std::ifstream;
using std::istringstream;
-using std::ostream;
using std::ostringstream;
using std::stringstream;
using std::string;
stringstream ss;
LyXTextClass textclass = parse_preamble(p, ss);
active_environments.push_back("document");
- parse_text(p, ss, FLAG_END, true, textclass);
- check_end_layout(ss);
+ Context context(true, textclass);
+ parse_text(p, ss, FLAG_END, true, context);
+ context.check_end_layout(ss);
ss << "\n\\end_document\n";
ss.seekg(0);