using std::endl;
-LaTeXFeatures::LaTeXFeatures(int n)
- : layout(n, false)
+LaTeXFeatures::LaTeXFeatures(BufferParams const & p, int n)
+ : layout(n, false), params(p)
{
// packages
color = false;
}
-string LaTeXFeatures::getPackages(BufferParams const & params)
+string LaTeXFeatures::getPackages()
{
string packages;
- LyXTextClass const & tclass = textclasslist.TextClass(params.textclass);
+ LyXTextClass const & tclass =
+ textclasslist.TextClass(params.textclass);
// color.sty
if (color) {
packages += "\\doublespacing\n";
break;
case Spacing::Other:
- //char value[30];
- //sprintf(value, "%.2f", params.spacing.getValue());
#ifdef HAVE_SSTREAM
std::ostringstream value;
#else
}
-string LaTeXFeatures::getMacros(BufferParams const & /* params */)
+string LaTeXFeatures::getMacros()
{
string macros;
}
-string LaTeXFeatures::getTClassPreamble(BufferParams const & params)
+string LaTeXFeatures::getTClassPreamble()
{
// the text class specific preamble
- LyXTextClass const & tclass = textclasslist.TextClass(params.textclass);
+ LyXTextClass const & tclass =
+ textclasslist.TextClass(params.textclass);
string tcpreamble = tclass.preamble();
for (unsigned int i = 0; i < tclass.numLayouts(); ++i) {
}
-void LaTeXFeatures::showStruct(BufferParams const & params) {
+void LaTeXFeatures::showStruct() {
lyxerr << "LyX needs the following commands when LaTeXing:"
- // packs
- << "\n***** Packages:" << getPackages(params)
- << "\n***** Macros:" << getMacros(params)
- << "\n***** Textclass stuff:" << getTClassPreamble(params)
+ << "\n***** Packages:" << getPackages()
+ << "\n***** Macros:" << getMacros()
+ << "\n***** Textclass stuff:" << getTClassPreamble()
<< "\n***** done." << endl;
}
+
+
+BufferParams const & LaTeXFeatures::bufferParams() const
+{
+ return params;
+}