8 * This file is part of LyX, the document processor.
9 * Licence details can be found in the file COPYING.
13 * Full author contact details are available in file CREDITS
16 #include "latexrunparams.h"
30 Converter(string const & f, string const & t, string const & c,
47 /// The converter is latex or its derivatives
49 /// Do we need to run the converter in the original directory?
51 /// This converter needs the .aux files
53 /// If the converter put the result in a directory, then result_dir
54 /// is the name of the directory
56 /// If the converter put the result in a directory, then result_file
57 /// is the name of the main file in that directory
59 /// Command to convert the program output to a LaTeX log file format
68 typedef std::vector<int> EdgePath; // to be removed SOON
70 typedef std::vector<Converter> ConverterList;
72 typedef ConverterList::const_iterator const_iterator;
74 Converter const & get(int i) const {
75 return converterlist_[i];
78 Converter const * getConverter(string const & from, string const & to);
80 int getNumber(string const & from, string const & to);
82 void add(string const & from, string const & to,
83 string const & command, string const & flags);
85 void erase(string const & from, string const & to);
89 std::vector<Format const *> const
90 getReachableTo(string const & target, bool clear_visited);
92 std::vector<Format const *> const
93 getReachable(string const & from, bool only_viewable,
96 bool isReachable(string const & from, string const & to);
98 Graph::EdgePath const getPath(string const & from, string const & to);
100 bool usePdflatex(Graph::EdgePath const & path);
102 bool convert(Buffer const * buffer,
103 string const & from_file, string const & to_file_base,
104 string const & from_format, string const & to_format,
107 bool convert(Buffer const * buffer,
108 string const & from_file, string const & to_file_base,
109 string const & from_format, string const & to_format);
111 void update(Formats const & formats);
113 void updateLast(Formats const & formats);
115 bool formatIsUsed(string const & format);
117 const_iterator begin() const {
118 return converterlist_.begin();
120 const_iterator end() const {
121 return converterlist_.end();
127 std::vector<Format const *> const
128 Converters::intToFormat(std::vector<int> const & input);
130 bool scanLog(Buffer const * buffer, string const & command,
131 string const & filename);
133 bool runLaTeX(Buffer const * buffer, string const & command,
134 LatexRunParams const &);
136 ConverterList converterlist_;
138 string latex_command_;
140 bool move(string const & from, string const & to, bool copy);
145 extern Converters converters;
147 extern Converters system_converters;