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
29 Converter(string const & f, string const & t, string const & c,
46 /// The converter is latex or its derivatives
48 /// Do we need to run the converter in the original directory?
50 /// This converter needs the .aux files
52 /// If the converter put the result in a directory, then result_dir
53 /// is the name of the directory
55 /// If the converter put the result in a directory, then result_file
56 /// is the name of the main file in that directory
58 /// Command to convert the program output to a LaTeX log file format
67 typedef std::vector<int> EdgePath; // to be removed SOON
69 typedef std::vector<Converter> ConverterList;
71 typedef ConverterList::const_iterator const_iterator;
73 Converter const & get(int i) const {
74 return converterlist_[i];
77 Converter const * getConverter(string const & from, string const & to);
79 int getNumber(string const & from, string const & to);
81 void add(string const & from, string const & to,
82 string const & command, string const & flags);
84 void erase(string const & from, string const & to);
88 std::vector<Format const *> const
89 getReachableTo(string const & target, bool clear_visited);
91 std::vector<Format const *> const
92 getReachable(string const & from, bool only_viewable,
95 bool isReachable(string const & from, string const & to);
97 Graph::EdgePath const getPath(string const & from, string const & to);
99 bool usePdflatex(Graph::EdgePath const & path);
101 bool convert(Buffer const * buffer,
102 string const & from_file, string const & to_file_base,
103 string const & from_format, string const & to_format,
106 bool convert(Buffer const * buffer,
107 string const & from_file, string const & to_file_base,
108 string const & from_format, string const & to_format);
110 string const dvips_options(Buffer const * buffer);
112 string const dvipdfm_options(Buffer const * buffer);
114 void update(Formats const & formats);
116 void updateLast(Formats const & formats);
118 bool formatIsUsed(string const & format);
120 const_iterator begin() const {
121 return converterlist_.begin();
123 const_iterator end() const {
124 return converterlist_.end();
130 std::vector<Format const *> const
131 Converters::intToFormat(std::vector<int> const & input);
133 bool scanLog(Buffer const * buffer, string const & command,
134 string const & filename);
136 bool runLaTeX(Buffer const * buffer, string const & command);
138 ConverterList converterlist_;
140 string latex_command_;
142 bool move(string const & from, string const & to, bool copy);
147 extern Converters converters;
149 extern Converters system_converters;