4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Lars Gullik Bjønnes
8 * \author Jean-Marc Lasgouttes
9 * \author Angus Leeming
11 * \author André Pönitz
15 * Full author contact details are available in file CREDITS.
22 #include "graphics/GraphicsTypes.h"
24 #include "support/std_string.h"
26 /// This contains the runtime configuration of LyX
27 class LyXRC //: public noncopyable {
28 // after 1.1.6 I will use a LyXRCStruct here and then this can be made
29 // noncopyable again. For now I want to minimise changes. ARRae 20001010
38 RC_PRINTPAGERANGEFLAG,
40 RC_PRINTCOLLCOPIESFLAG,
42 RC_PRINTLANDSCAPEFLAG,
46 RC_PRINTFILEEXTENSION,
47 RC_PRINTEXSTRAOPTIONS,
48 RC_PRINTSPOOL_COMMAND,
49 RC_PRINTSPOOL_PRINTERPREFIX,
51 RC_PRINTPAPERDIMENSIONFLAG,
52 RC_CUSTOM_EXPORT_COMMAND,
53 RC_CUSTOM_EXPORT_FORMAT,
59 RC_SCREEN_FONT_TYPEWRITER,
60 RC_SCREEN_FONT_ROMAN_FOUNDRY,
61 RC_SCREEN_FONT_SANS_FOUNDRY,
62 RC_SCREEN_FONT_TYPEWRITER_FOUNDRY,
63 RC_SCREEN_FONT_ENCODING,
66 RC_POPUP_FONT_ENCODING,
87 RC_VIEWDVI_PAPEROPTION,
96 RC_SCREEN_FONT_SCALABLE,
101 RC_CURSOR_FOLLOWS_SCROLLBAR,
102 RC_DIALOGS_ICONIFY_WITH_MAIN,
107 RC_MARK_FOREIGN_LANGUAGE,
109 RC_LANGUAGE_AUTO_BEGIN,
110 RC_LANGUAGE_AUTO_END,
111 RC_LANGUAGE_COMMAND_BEGIN,
112 RC_LANGUAGE_COMMAND_END,
113 RC_LANGUAGE_COMMAND_LOCAL,
114 RC_LANGUAGE_GLOBAL_OPTIONS,
115 RC_LANGUAGE_USE_BABEL,
116 RC_DATE_INSERT_FORMAT,
123 RC_LABEL_INIT_LENGTH,
126 RC_PREVIEW_HASHED_LABELS,
127 RC_PREVIEW_SCALE_FACTOR,
140 int read(string const & filename);
142 void write(string const & filename) const;
146 void output(std::ostream & os) const;
148 static string const getDescription(LyXRCTags);
156 string print_command;
158 string print_evenpage_flag;
160 string print_oddpage_flag;
162 string print_pagerange_flag;
164 string print_copies_flag;
166 string print_collcopies_flag;
168 string print_reverse_flag;
170 string print_landscape_flag;
172 string print_to_printer;
174 bool print_adapt_output;
176 string print_to_file;
178 string print_file_extension;
180 string print_extra_options;
182 string print_spool_command;
184 string print_spool_printerprefix;
186 string print_paper_flag;
188 string print_paper_dimension_flag;
190 string custom_export_command;
192 string custom_export_format;
193 /// postscript interpreter (in general "gs", if it is installed)
195 /// option for telling the dvi viewer about the paper size
196 string view_dvi_paper_option;
197 /// default paper size for local xdvi/dvips/ghostview/whatever
198 PAPER_SIZE default_papersize;
199 /// command to run chktex incl. options
200 string chktex_command;
202 string document_path;
204 string template_path;
210 bool auto_region_delete;
211 /// flag telling whether lastfiles should be checked for existance
212 bool auto_reset_options;
214 bool check_lastfiles;
215 /// filename for lastfiles file
217 /// maximal number of lastfiles
218 unsigned int num_lastfiles;
219 /// shall a backup file be created
221 /// A directory for storing backup files
222 string backupdir_path;
223 /// Zoom factor for screen fonts
225 /// parameter for button_4 and button_5 (scrollwheel)
226 unsigned int wheel_jump;
227 /// Screen font sizes in points for each font size
228 float font_sizes[10];
229 /// Allow the use of scalable fonts? Default is yes.
230 bool use_scalable_fonts;
236 string roman_font_name;
238 string sans_font_name;
240 string typewriter_font_name;
242 string roman_font_foundry;
244 string sans_font_foundry;
246 string typewriter_font_foundry;
248 string popup_bold_font;
250 string popup_normal_font;
273 FontEncoding font_norm_type;
275 void set_font_norm_type();
277 string popup_font_encoding;
279 unsigned int autosave;
281 string ascii_roff_command;
283 unsigned int ascii_linelen;
284 /// use library instead of process
288 /// Accept compound words in spellchecker?
289 bool isp_accept_compound;
290 /// Pass input encoding switch to ispell?
291 bool isp_use_input_encoding;
292 /// Use alternate language?
293 bool isp_use_alt_lang;
294 /// Use personal dictionary?
295 bool isp_use_pers_dict;
296 /// Use escape chars?
297 bool isp_use_esc_chars;
298 /// Alternate language for ispell
300 /// Alternate personal dictionary file for ispell
301 string isp_pers_dict;
302 /// Escape characters
303 string isp_esc_chars;
307 string primary_kbmap;
309 string secondary_kbmap;
313 string date_insert_format;
315 string language_package;
317 bool language_auto_begin;
319 bool language_auto_end;
321 string language_command_begin;
323 string language_command_end;
325 string language_command_local;
327 bool language_global_options;
329 bool language_use_babel;
335 bool mark_foreign_language;
337 string default_language;
339 bool cursor_follows_scrollbar;
341 bool dialogs_iconify_with_main;
343 int label_init_length;
345 lyx::graphics::DisplayType display_graphics;
351 bool preview_hashed_labels;
353 float preview_scale_factor;
363 extern LyXRC system_lyxrc;