-
Notifications
You must be signed in to change notification settings - Fork 10
/
dictionarysettings.h
43 lines (32 loc) · 1.2 KB
/
dictionarysettings.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
/*
** Copyright 2007-2013, 2017-2018 Sólyom Zoltán
** This file is part of zkanji, a free software released under the terms of the
** GNU General Public License version 3. See the file LICENSE for details.
**/
#ifndef DICTIONARYSETTINGS_H
#define DICTIONARYSETTINGS_H
enum class BrowseOrder : uchar { ABCDE, AIUEO };
enum class ResultOrder : uchar { Relevance, Frequency, JLPTfrom1, JLPTfrom5 };
struct DictionarySettings
{
enum InflectionShow { Never, CurrentRow, Everywhere };
enum JlptColumn { Frequency, Definition, Both };
bool autosize = false;
InflectionShow inflection = CurrentRow;
ResultOrder resultorder = ResultOrder::Relevance;
BrowseOrder browseorder = BrowseOrder::ABCDE;
bool showingroup = false;
bool showjlpt = true;
JlptColumn jlptcolumn = Frequency;
// Number of last searches stored.
int historylimit = 1000;
// Whether an entered string should be saved if the user doesn't touch the search field.
bool historytimer = true;
// Seconds timeout after last keypress in search field when its text is saved to history.
int historytimeout = 4;
};
namespace Settings
{
extern DictionarySettings dictionary;
}
#endif // DICTIONARYSETTINGS_H