Fix default biblio style detection

This commit is contained in:
Juergen Spitzmueller 2017-01-04 17:11:25 +01:00
parent 298730215c
commit 78eb821038
2 changed files with 7 additions and 4 deletions

View File

@ -3241,7 +3241,7 @@ bool BufferParams::addCiteEngine(vector<string> const & engine)
string const & BufferParams::defaultBiblioStyle() const
{
map<string, string> bs = documentClass().defaultBiblioStyle();
return bs[documentClass().opt_enginetype()];
return bs[theCiteEnginesList.getTypeAsString(citeEngineType())];
}

View File

@ -772,9 +772,12 @@ TextClass::ReturnValues TextClass::read(Lexer & lexrc, ReadType rt)
vector<string>::const_iterator it = dbs.begin();
vector<string>::const_iterator end = dbs.end();
for (; it != end; ++it) {
if (!contains(*it, ':'))
cite_default_biblio_style_[opt_enginetype_] = *it;
else {
if (!contains(*it, ':')) {
vector<string> const enginetypes =
getVectorFromString(opt_enginetype_, "|");
for (string const &s: enginetypes)
cite_default_biblio_style_[s] = *it;
} else {
string eng;
string const db = split(*it, eng, ':');
cite_default_biblio_style_[eng] = db;