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 * ======================================================
35 Error () : error_in_line(0) {}
37 Error(int line, string const & desc, string const & text)
38 : error_in_line(line),
41 /// what line in the TeX file the error occured in
45 /// The line/cmd that caused the error.
50 typedef vector<Error> Errors;
52 Errors::const_iterator begin() const { return errors.begin(); }
54 Errors::const_iterator end() const { return errors.end(); }
56 void insertError(int line, string const & error_desc,
57 string const & error_text);
67 /** All the different files produced by TeX.
69 This is the files mentioned on page 208-9 in Lamports book +
75 /// used for table of contents et.al.
81 /// glossary (not supported by LyX so far)
85 /// written by makeindex
89 /// the LaTeX log file
99 /// list of algorithms
103 /** Return values from scanLogFile() and run() (to come)
105 This enum should be enlarged a bit so that one could
106 get more feedback from the LaTeX run.
116 UNDEF_REF = 4, // Reference '...' on page ... undefined.
118 UNDEF_CIT = 8, // Citation '...' on page ... undefined.
120 RERUN = 16, // Label(s) may have changed. Rerun to get...
130 PACKAGE_WARNING = 512,
136 TOO_MANY_ERRORS = 4096,
138 ERRORS = TEX_ERROR + LATEX_ERROR,
140 WARNINGS = TEX_WARNING + LATEX_WARNING + PACKAGE_WARNING
145 cmd = the latex command, file = name of the (temporary) latex file,
146 path = name of the files original path.
148 LaTeX(string const & cmd, string const & file, string const & path);
150 /// runs LaTeX several times
151 int run(TeXErrors &, MiniBuffer *);
154 int getNumErrors() { return num_errors;}
156 /// use this for running LaTeX once
159 /// The dependency file.
163 LaTeX(LaTeX const &);
165 LaTeX & operator= (LaTeX const &);
168 void deplog(DepTable & head);
171 void deptex(DepTable & head);
174 int scanLogFile(TeXErrors &);
177 bool runMakeIndex(string const &);
180 bool scanAux(DepTable &);
183 bool runBibTeX(string const &, DepTable &);
199 // used by scanLogFile