]> git.lyx.org Git - lyx.git/blob - src/frontends/lyx_gui.C
* lyx_gui: create_view(), start() and exit() functions deleted.
[lyx.git] / src / frontends / lyx_gui.C
1 /**
2  * \file frontends/lyx_gui.C
3  * This file is part of LyX, the document processor.
4  * Licence details can be found in the file COPYING.
5  *
6  * \author John Levon
7  * \author Abdelrazak Younes
8  *
9  * Full author contact details are available in file CREDITS.
10  */
11
12 #include <config.h>
13
14 #include "lyx_gui.h"
15
16 #include "Application.h"
17
18 #include "funcrequest.h"
19
20 using std::string;
21
22 lyx::frontend::Application * theApp;
23
24
25 namespace lyx_gui {
26
27 bool use_gui = true;
28
29 void parse_lyxrc()
30 {}
31
32
33 FuncStatus getStatus(FuncRequest const & ev)
34 {
35         FuncStatus flag;
36         switch (ev.action) {
37         case LFUN_TOOLTIPS_TOGGLE:
38                 flag.unknown(true);
39                 break;
40         default:
41                 break;
42         }
43
44         return flag;
45 }
46
47
48 string const roman_font_name()
49 {
50         if (!use_gui)
51                 return "serif";
52
53         return theApp->romanFontName();
54 }
55
56
57 string const sans_font_name()
58 {
59         if (!use_gui)
60                 return "sans";
61
62         return theApp->sansFontName();
63 }
64
65
66 string const typewriter_font_name()
67 {
68         if (!use_gui)
69                 return "monospace";
70
71         return theApp->typewriterFontName();
72 }
73
74 }; // namespace lyx_gui