namespace {
-static unsigned int const LYXRC_FILEFORMAT = 9; // spitz: remove \\default_language
+static unsigned int const LYXRC_FILEFORMAT = 11; // gb: Split pdf format into pdf and pdf6
// when adding something to this array keep it sorted!
LexerKeyword lyxrcTags[] = {
}
case RC_VIEWER_ALTERNATIVES: {
string format, command;
- if (lexrc.next())
- format = lexrc.getString();
- if (lexrc.eatLine())
- command = lexrc.getString();
+ lexrc >> format;
+ lexrc >> command;
viewer_alternatives[format].insert(command);
break;
}
case RC_EDITOR_ALTERNATIVES: {
string format, command;
- if (lexrc.next())
- format = lexrc.getString();
- if (lexrc.eatLine())
- command = lexrc.getString();
+ lexrc >> format;
+ lexrc >> command;
editor_alternatives[format].insert(command);
break;
}
|| sysfmt == sysend // format not found
|| sysfmt->second.count(cmd) == 0 // this command not found
)
- os << "\\viewer_alternatives " << fmt << " " << cmd << "\n";
+ os << "\\viewer_alternatives " << fmt << " \"" << escapeCommand(cmd) << "\"\n";
}
}
if (tag != RC_LAST)
|| sysfmt == sysend // format not found
|| sysfmt->second.count(cmd) == 0 // this command not found
)
- os << "\\editor_alternatives " << fmt << " " << cmd << "\n";
+ os << "\\editor_alternatives " << fmt << " \"" << escapeCommand(cmd) << "\"\n";
}
}
if (tag != RC_LAST)