#include "support/lstrings.h"
#include "support/path.h"
#include "support/path_defines.h"
-#include "support/translator.h"
-
-#include <boost/assert.hpp>
-
-#include <algorithm>
namespace support = lyx::support;
<< "\tHelpTextEnd\n"
<< "\tInputFormat " << et.inputFormat << '\n'
<< "\tFileFilter " << et.fileRegExp << '\n'
- << "\tEditCommand " << et.editCommand << '\n'
<< "\tAutomaticProduction " << et.automaticProduction << '\n';
typedef vector<TransformID> IDs;
ost << "\t\tPreamble " << *pit << '\n';
}
+ typedef Template::Format::FileMap FileMap;
+ FileMap::const_iterator rit = ft.referencedFiles.begin();
+ FileMap::const_iterator rend = ft.referencedFiles.end();
+ for (; rit != rend; ++rit) {
+ vector<string>::const_iterator fit = rit->second.begin();
+ vector<string>::const_iterator fend = rit->second.end();
+ for (; fit != fend; ++fit) {
+ ost << "\t\tReferencedFile " << rit->first
+ << " \"" << *fit << "\"\n";
+ }
+ }
+
ost << "\tFormatEnd\n";
}
private:
TO_HELPTEXT,
TO_INPUTFORMAT,
TO_FILTER,
- TO_EDITCMD,
TO_AUTOMATIC,
TO_TRANSFORM,
TO_FORMAT,
keyword_item templateoptiontags[] = {
{ "automaticproduction", TO_AUTOMATIC },
- { "editcommand", TO_EDITCMD },
{ "filefilter", TO_FILTER },
{ "format", TO_FORMAT },
{ "guiname", TO_GUINAME },
fileRegExp = lex.getString();
break;
- case TO_EDITCMD:
- lex.next(true);
- editCommand = lex.getString();
- break;
-
case TO_AUTOMATIC:
lex.next();
automaticProduction = lex.getBool();
FO_PREAMBLE,
FO_TRANSFORMCOMMAND,
FO_TRANSFORMOPTION,
+ FO_REFERENCEDFILE,
FO_END
};
{ "option", FO_OPTION },
{ "preamble", FO_PREAMBLE },
{ "product", FO_PRODUCT },
+ { "referencedfile", FO_REFERENCEDFILE },
{ "requirement", FO_REQUIREMENT },
{ "transformcommand", FO_TRANSFORMCOMMAND },
{ "transformoption", FO_TRANSFORMOPTION },
break;
}
+ case FO_REFERENCEDFILE: {
+ lex.next(true);
+ string const format = lex.getString();
+ lex.next(true);
+ string const file = lex.getString();
+ referencedFiles[format].push_back(file);
+ break;
+ }
+
case FO_END:
return;
}