forked from acaudwell/Gource
/
gource_settings.h
152 lines (108 loc) · 3.25 KB
/
gource_settings.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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
/*
Copyright (C) 2010 Andrew Caudwell (acaudwell@gmail.com)
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version
3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef GOURCE_SETTINGS_H
#define GOURCE_SETTINGS_H
#define GOURCE_VERSION "0.39"
#include <dirent.h>
#include "formats/hg.h"
#include "formats/git.h"
#include "formats/bzr.h"
#include "formats/cvs-exp.h"
#include "formats/cvs2cl.h"
#include "formats/svn.h"
#include "core/settings.h"
#include "core/regex.h"
class GourceSettings : public SDLAppSettings {
protected:
void commandLineOption(const std::string& name, const std::string& value);
public:
int repo_count;
bool hide_date;
bool hide_users;
bool hide_tree;
bool hide_files;
bool hide_usernames;
bool hide_filenames;
bool hide_dirnames;
bool hide_progress;
bool hide_bloom;
bool hide_mouse;
bool hide_root;
bool disable_auto_rotate;
bool show_key;
std::string load_config;
std::string save_config;
std::string path;
std::string logo;
vec2 logo_offset;
float start_position;
float stop_position;
float stop_at_time;
bool stop_on_idle;
bool stop_at_end;
bool dont_stop;
float auto_skip_seconds;
float days_per_second;
float file_idle_time;
bool loop;
bool ffp;
bool colour_user_images;
std::string default_user_image;
std::string user_image_dir;
std::map<std::string, std::string> user_image_map;
float camera_zoom_min;
float camera_zoom_max;
float camera_zoom_default;
std::string camera_mode;
float padding;
bool crop_vertical;
bool crop_horizontal;
float bloom_multiplier;
float bloom_intensity;
vec3 background_colour;
std::string background_image;
std::string title;
int font_size;
vec3 font_colour;
float elasticity;
std::string git_branch;
std::string log_format;
std::string date_format;
int max_files;
float max_user_speed;
float max_file_lag;
float user_idle_time;
float user_friction;
float user_scale;
float time_scale;
bool highlight_dirs;
bool highlight_all_users;
vec3 dir_colour;
vec3 highlight_colour;
vec3 selection_colour;
std::vector<std::string> highlight_users;
std::vector<std::string> follow_users;
std::vector<Regex*> file_filters;
std::vector<Regex*> user_filters;
bool file_extensions;
std::string output_custom_filename;
TextureResource* file_graphic;
int log_level;
GourceSettings();
void setGourceDefaults();
void importGourceSettings(ConfFile& conf, ConfSection* gource_settings = 0);
void help(bool extended_help=false);
};
extern GourceSettings gGourceSettings;
#endif