-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathgeneralsettings.h
More file actions
47 lines (34 loc) · 1.25 KB
/
generalsettings.h
File metadata and controls
47 lines (34 loc) · 1.25 KB
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
43
44
45
/*
** 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 GENERALSETTINGS_H
#define GENERALSETTINGS_H
struct GeneralSettings
{
enum DateFormat { DayMonthYear, MonthDayYear, YearMonthDay };
enum StartState { SaveState, AlwaysMinimize, AlwaysMaximize, ForgetState };
enum MinimizeBehavior { DefaultMinimize, TrayOnMinimize, TrayOnClose };
DateFormat dateformat = DayMonthYear;
// Whether to save and restore window sizes.
bool savewinpos = true;
// Tool window states (i.e. kanji information window.)
//bool savetoolstates = false;
StartState startstate = SaveState;
MinimizeBehavior minimizebehavior = DefaultMinimize;
// Interface scaling saved from the settings window, but not applied. Values 100-400.
int savedscale = 100;
// Current applied scaling. Loaded at the start of the program and not changed.
int scale = 100;
};
namespace Settings
{
extern GeneralSettings general;
double scaling();
int scaled(int siz);
int scaled(double siz);
QSize scaled(QSize siz);
QSizeF scaled(QSizeF siz);
}
#endif // GENERALSETTINGS_H