if (converter.latex
&& (latex_command_.empty() || converter.latex_flavor == "latex"))
latex_command_ = subst(command, token_from, "");
+ // Similarly, set xelatex_command to xelatex.
+ if (converter.latex
+ && (xelatex_command_.empty() || converter.latex_flavor == "xelatex"))
+ xelatex_command_ = subst(command, token_from, "");
if (it == converterlist_.end()) {
converterlist_.push_back(converter);
} else {
if (conv.need_aux && !run_latex
&& !latex_command_.empty()) {
- LYXERR(Debug::FILES, "Running " << latex_command_
+ string const command = (buffer && buffer->params().useNonTeXFonts) ?
+ xelatex_command_ : latex_command_;
+ LYXERR(Debug::FILES, "Running " << command
<< " to update aux file");
- runLaTeX(*buffer, latex_command_, runparams, errorList);
+ if (!runLaTeX(*buffer, command, runparams, errorList))
+ return false;
}
// FIXME UNICODE
command = subst(command, token_from, quoteName(infile2));
command = subst(command, token_base, quoteName(from_base));
command = subst(command, token_to, quoteName(outfile2));
- command = subst(command, token_path, quoteName(infile.onlyPath().absFileName()));
- command = subst(command, token_orig_path, quoteName(orig_from.onlyPath().absFileName()));
+ command = subst(command, token_path, quoteName(onlyPath(infile.absFileName())));
+ command = subst(command, token_orig_path, quoteName(onlyPath(orig_from.absFileName())));
command = subst(command, token_encoding, buffer ? buffer->params().encoding().iconvName() : string());
command = libScriptSearch(command);
vector<Format const *> const
Converters::getReachable(string const & from, bool const only_viewable,
- bool const clear_visited)
+ bool const clear_visited, set<string> const & excludes)
{
+ set<int> excluded_numbers;;
+
+ set<string>::const_iterator sit = excludes.begin();
+ set<string>::const_iterator const end = excludes.end();
+ for (; sit != end; ++sit)
+ excluded_numbers.insert(formats.getNumber(*sit));
+
vector<int> const & reachables =
G_.getReachable(formats.getNumber(from),
only_viewable,
- clear_visited);
+ clear_visited,
+ excluded_numbers);
return intToFormat(reachables);
}