]> git.lyx.org Git - features.git/blobdiff - src/Converter.cpp
Load hyperref with a suitable driver
[features.git] / src / Converter.cpp
index d433f83c98d8581c28d45af308b0e26e699985cb..37977b46c089a7fde1030a95db8d6cbc4917df09 100644 (file)
@@ -136,6 +136,8 @@ void Converter::readFlags()
                        nice_ = true;
                else if (flag_name == "needauth")
                        need_auth_ = true;
+               else if (flag_name == "hyperref-driver")
+                       href_driver_ = flag_value;
        }
        if (!result_dir_.empty() && result_file_.empty())
                result_file_ = "index." + theFormats().extension(to_);
@@ -283,6 +285,18 @@ OutputParams::FLAVOR Converters::getFlavor(Graph::EdgePath const & path,
 }
 
 
+string Converters::getHyperrefDriver(Graph::EdgePath const & path)
+{
+       for (Graph::EdgePath::const_iterator cit = path.begin();
+            cit != path.end(); ++cit) {
+               Converter const & conv = converterlist_[*cit];
+               if (!conv.hyperref_driver().empty())
+                       return conv.hyperref_driver();
+       }
+       return string();
+}
+
+
 bool Converters::checkAuth(Converter const & conv, string const & doc_fname,
                           bool use_shell_escape)
 {