X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2FLaTeXFeatures.cpp;h=e4f563a456faf5b378792678d1b0b714979bea85;hb=f34394460a1c22937c9732f55f00aa6952764264;hp=ece463005caf15d12b9e151f5c428db96b9ae765;hpb=274b3caff2a9a0258f5895def30e352c72bdf2da;p=lyx.git diff --git a/src/LaTeXFeatures.cpp b/src/LaTeXFeatures.cpp index ece463005c..e4f563a456 100644 --- a/src/LaTeXFeatures.cpp +++ b/src/LaTeXFeatures.cpp @@ -825,20 +825,25 @@ string const LaTeXFeatures::getPackages() const // also unknown packages can be requested. They are silently // swallowed now. We should change this eventually. - // + // Output all the package option stuff we have been asked to do. + map::const_iterator it = + params_.documentClass().packageOptions().begin(); + map::const_iterator en = + params_.documentClass().packageOptions().end(); + for (; it != en; ++it) + if (mustProvide(it->first)) + packages << "\\PassOptionsToPackage{" << it->second << "}" + << "{" << it->first << "}\n"; + // These are all the 'simple' includes. i.e // packages which we just \usepackage{package} - // for (int i = 0; i < nb_simplefeatures; ++i) { if (mustProvide(simplefeatures[i])) - packages << "\\usepackage{" - << simplefeatures[i] << "}\n"; + packages << "\\usepackage{" << simplefeatures[i] << "}\n"; } - // // The rest of these packages are somewhat more complicated // than those above. - // // if fontspec is used, AMS packages have to be loaded before // fontspec (in BufferParams)