#include "Lexer.h"
#include "LyX.h"
#include "Mover.h"
-#include "Session.h"
#include "SpellChecker.h"
#include "version.h"
-#include "graphics/GraphicsTypes.h"
-
#include "support/convert.h"
#include "support/debug.h"
#include "support/environment.h"
#include "support/FileName.h"
#include "support/filetools.h"
-#include "support/gettext.h"
#include "support/lstrings.h"
#include "support/os.h"
#include "support/Package.h"
#include "support/TempFile.h"
-#include "support/userinfo.h"
#ifdef USE_MACOSX_PACKAGING
#include "support/AppleSupport.h"
// The format should also be updated in configure.py, and conversion code
// should be added to prefs2prefs_prefs.py.
-static unsigned int const LYXRC_FILEFORMAT = 34; // yuriy: rename kmap files
+static unsigned int const LYXRC_FILEFORMAT = 36; // rkh: spellcheck_continuously default
// when adding something to this array keep it sorted!
LexerKeyword lyxrcTags[] = {
{ "\\accept_compound", LyXRC::RC_ACCEPT_COMPOUND },
}
string const x11_name = lexrc.getString();
+ string x11_darkname = x11_name;
+ if (lexrc.next())
+ x11_darkname = lexrc.getString();
+
ColorCode const col =
lcolor.getFromLyXName(lyx_name);
if (col == Color_none ||
col == Color_ignore)
break;
- if (!lcolor.setColor(col, x11_name))
+ if (!lcolor.setColor(col, x11_name, x11_darkname))
LYXERR0("Bad lyxrc set_color for " << lyx_name);
- LYXERR(Debug::LYXRC, "Set " << lyx_name << "(" << col << ") to " << x11_name);
+ LYXERR(Debug::LYXRC, "Set " << lyx_name << "(" << col << ") to "
+ << x11_name << " and " << x11_darkname);
break;
}
case RC_SET_COLOR:
for (int i = 0; i < Color_ignore; ++i) {
ColorCode lc = static_cast<ColorCode>(i);
- string const col = lcolor.getX11HexName(lc);
+ string const col = lcolor.getAllX11HexNames(lc).first;
+ string const darkcol = lcolor.getAllX11HexNames(lc).second;
if (ignore_system_lyxrc
- || col != system_lcolor.getX11HexName(lc)) {
+ || col != system_lcolor.getAllX11HexNames(lc).first
+ || darkcol != system_lcolor.getAllX11HexNames(lc).second) {
os << "\\set_color \""
<< lcolor.getLyXName(lc) << "\" \""
- << col << "\"\n";
+ << col << "\" \""
+ << darkcol << "\"\n";
}
}
if (tag != RC_LAST)
break;
// fall through
case RC_DEFAULT_VIEW_FORMAT:
- if (ignore_system_lyxrc ||
- default_view_format != system_lyxrc.default_view_format) {
+ if ((ignore_system_lyxrc ||
+ default_view_format != system_lyxrc.default_view_format)
+ && !default_view_format.empty()) {
os << "\\default_view_format " << default_view_format << '\n';
}
if (tag != RC_LAST)
|| lyxrc_orig.roman_font_foundry != lyxrc_new.roman_font_foundry
|| lyxrc_orig.sans_font_foundry != lyxrc_new.sans_font_foundry
|| lyxrc_orig.use_scalable_fonts != lyxrc_new.use_scalable_fonts
- || lyxrc_orig.font_sizes != lyxrc_new.font_sizes
+ || !std::equal(std::begin(lyxrc_orig.font_sizes), std::end(lyxrc_orig.font_sizes),
+ std::begin(lyxrc_new.font_sizes))
|| lyxrc_orig.typewriter_font_foundry != lyxrc_new.typewriter_font_foundry
|| lyxrc_orig.defaultZoom != lyxrc_new.defaultZoom) {
dispatch(FuncRequest(LFUN_SCREEN_FONT_UPDATE));