GUI preview: use kbytes not mbytes for specifying the threshold size for not highlighting preview: with a slow splitter 1MB could be too high
This commit is contained in:
parent
5719cada57
commit
ac5ff471f2
@ -158,7 +158,15 @@ void rwSettings(bool writing)
|
||||
"/Recoll/prefs/reslist/collapseDuplicates", Bool, false);
|
||||
SETTING_RW(prefs.showResultsAsTable,
|
||||
"/Recoll/prefs/showResultsAsTable", Bool, false);
|
||||
SETTING_RW(prefs.maxhltextmbs, "/Recoll/prefs/preview/maxhltextmbs", Int, 3);
|
||||
|
||||
SETTING_RW(prefs.maxhltextkbs, "/Recoll/prefs/preview/maxhltextkbs", Int,
|
||||
3000);
|
||||
// Compat: if maxhltextkbs is not set but old maxhltextmbs is set use it
|
||||
if (!writing && !settings.contains("/Recoll/prefs/preview/maxhltextkbs") &&
|
||||
settings.contains("/Recoll/prefs/preview/maxhltextmbs")) {
|
||||
prefs.maxhltextkbs = settings.value(
|
||||
"/Recoll/prefs/preview/maxhltextmbs").toInt() * 1024;
|
||||
}
|
||||
|
||||
SETTING_RW(prefs.previewPlainPre,
|
||||
"/Recoll/prefs/preview/plainPre", Int, PrefsPack::PP_PREWRAP);
|
||||
|
||||
@ -46,7 +46,7 @@ class PrefsPack {
|
||||
int filterCtlStyle;
|
||||
int respagesize{8};
|
||||
int historysize{0};
|
||||
int maxhltextmbs;
|
||||
int maxhltextkbs;
|
||||
QString reslistfontfamily;
|
||||
// Not saved in prefs for now. Computed from qt defaults and used to
|
||||
// set main character color for webkit/textbrowser reslist and
|
||||
|
||||
2296
src/qtgui/uiprefs.ui
2296
src/qtgui/uiprefs.ui
File diff suppressed because it is too large
Load Diff
@ -112,7 +112,7 @@ void UIPrefsDialog::setFromPrefs()
|
||||
pageLenSB->setValue(prefs.respagesize);
|
||||
maxHistSizeSB->setValue(prefs.historysize);
|
||||
collapseDupsCB->setChecked(prefs.collapseDuplicates);
|
||||
maxHLTSB->setValue(prefs.maxhltextmbs);
|
||||
maxHLTSB->setValue(prefs.maxhltextkbs);
|
||||
|
||||
if (prefs.ssearchTypSav) {
|
||||
ssearchTypCMB->setCurrentIndex(4);
|
||||
@ -304,7 +304,7 @@ void UIPrefsDialog::accept()
|
||||
prefs.respagesize = pageLenSB->value();
|
||||
prefs.historysize = maxHistSizeSB->value();
|
||||
prefs.collapseDuplicates = collapseDupsCB->isChecked();
|
||||
prefs.maxhltextmbs = maxHLTSB->value();
|
||||
prefs.maxhltextkbs = maxHLTSB->value();
|
||||
|
||||
prefs.qtermstyle = qtermStyleLE->text();
|
||||
prefs.abssep = abssepLE->text();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user