]> git.lyx.org Git - lyx.git/blob - src/frontends/lyx_gui.h
better selection and scrolling behaviour
[lyx.git] / src / frontends / lyx_gui.h
1 // -*- C++ -*-
2 /**
3  * \file lyx_gui.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author John Levon
8  *
9  * Full author contact details are available in file CREDITS
10  */
11
12 #ifndef LYX_GUI_H
13 #define LYX_GUI_H
14
15 #include "LColor.h"
16 #include "LString.h"
17
18 #include <vector>
19
20 class Dialogs;
21 class LyXFont;
22 class LyXComm;
23
24 /// GUI interaction
25 namespace lyx_gui {
26
27 /// parse command line and do basic initialisation
28 void parse_init(int & argc, char * argv[]);
29
30 /**
31  * set up GUI parameters. At this point lyxrc may
32  * be used.
33  */
34 void parse_lyxrc();
35
36 /**
37  * Start the main event loop, after executing the given
38  * batch commands, and loading the given documents
39  */
40 void start(string const & batch, std::vector<string> const & files);
41
42 /**
43  * quit running LyX
44  */
45 void exit();
46
47 /** Eg, passing LColor::black returns "000000",
48  *      passing LColor::white returns "ffffff".
49  */
50 string const hexname(LColor::color col);
51
52 /**
53  * update an altered GUI color
54  */
55 void update_color(LColor::color col);
56
57 /**
58  * update the font cache
59  */
60 void update_fonts();
61
62 /**
63  * is the given font available ?
64  */
65 bool font_available(LyXFont const & font);
66
67 /**
68  * add a callback for I/O read notification
69  */
70 void set_read_callback(int fd, LyXComm * comm);
71
72 /**
73  * remove a I/O read callback
74  * @param fd file descriptor
75  */
76 void remove_read_callback(int fd);
77
78 } // namespace lyx_gui
79
80 #endif // LYX_GUI_H