2 /* This file is part of
3 * ======================================================
5 * LyX, The Document Processor
6 * Copyright 1995 Matthias Ettrich
7 * Copyright 1995-1996 The Lyx Team
9 * This file is Copyright (C) 1996-1999
12 *======================================================
39 Error () : error_in_line(0) {}
41 Error(int line, string const & desc, string const & text)
42 : error_in_line(line),
45 /// what line in the TeX file the error occured in
49 /// The line/cmd that caused the error.
54 typedef vector<Error> Errors;
56 Errors::const_iterator begin() const { return errors.begin(); }
58 Errors::const_iterator end() const { return errors.end(); }
60 void insertError(int line, string const & error_desc,
61 string const & error_text);
71 /** All the different files produced by TeX.
73 This is the files mentioned on page 208-9 in Lamports book +
79 /// used for table of contents et.al.
85 /// glossary (not supported by LyX so far)
89 /// written by makeindex
93 /// the LaTeX log file
103 /// list of algorithms
107 /** Return values from scanLogFile() and run() (to come)
109 This enum should be enlarged a bit so that one could
110 get more feedback from the LaTeX run.
120 UNDEF_REF = 4, // Reference '...' on page ... undefined.
122 UNDEF_CIT = 8, // Citation '...' on page ... undefined.
124 RERUN = 16, // Label(s) may have changed. Rerun to get...
134 PACKAGE_WARNING = 512,
140 TOO_MANY_ERRORS = 4096,
142 ERRORS = TEX_ERROR + LATEX_ERROR,
144 WARNINGS = TEX_WARNING + LATEX_WARNING + PACKAGE_WARNING
149 cmd = the latex command, file = name of the (temporary) latex file,
150 path = name of the files original path.
152 LaTeX(string const & cmd, string const & file, string const & path);
154 /// runs LaTeX several times
155 int run(TeXErrors &, MiniBuffer *);
158 int getNumErrors() { return num_errors;}
160 /// use this for running LaTeX once
163 /// The dependency file.
167 LaTeX(LaTeX const &);
169 LaTeX & operator=(LaTeX const &);
172 void deplog(DepTable & head);
175 void deptex(DepTable & head);
178 int scanLogFile(TeXErrors &);
181 bool runMakeIndex(string const &);
184 bool runBibTeX(string const &, DepTable &);
200 // used by scanLogFile