-
Notifications
You must be signed in to change notification settings - Fork 63
/
preferences.h
36 lines (33 loc) · 1003 Bytes
/
preferences.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
#pragma once
#include <QFont>
#include <QSettings>
#include "packet_composer.h"
struct PersistentPreferences
{
enum class ThemeAppearanceConfig
{
Auto = 0,
Light = 1,
Dark = 2,
};
EncryptPad::PacketMetadata defaultFileProperties;
EncryptPad::PacketMetadata keyFileProperties;
bool saveLastUsedDirectory;
bool enableBakFiles;
bool windowsEol;
bool displayLineNumbers;
bool wordWrap;
bool enableFakeVim;
int recentFiles;
int s2kResultsPoolSize;
QFont font;
int tabSize;
QString libCurlPath;
QString libCurlParameters;
int kfKeyLength;
ThemeAppearanceConfig themeAppearance;
};
void SetDefaultPreferences(PersistentPreferences &preferences);
void ReadPreferences(QSettings &settings, PersistentPreferences &preferences);
void WritePreferences(QSettings &settings, PersistentPreferences &preferences);
void CopyMetadataPreferences(EncryptPad::PacketMetadata &source, EncryptPad::PacketMetadata &target);