2 * \file xforms/Dialogs.C
3 * Copyright 1995 Matthias Ettrich
4 * Copyright 1995-2001 The LyX Team.
5 * See the file COPYING.
7 * \author Allan Rae, rae@lyx.org
13 #pragma implementation
21 #include "combox.h" // needed for clean destruction of boost::scoped_ptr
22 #include "form_aboutlyx.h"
23 #include "form_bibitem.h"
24 #include "form_bibtex.h"
25 #include "form_browser.h"
26 #include "form_character.h"
27 #include "form_citation.h"
28 #include "form_error.h"
30 #include "form_external.h"
31 #include "form_float.h"
32 #include "form_forks.h"
33 #include "form_graphics.h"
34 #include "form_include.h"
35 #include "form_index.h"
36 #include "form_minipage.h"
37 #include "form_preamble.h"
38 #include "form_print.h"
40 #include "form_search.h"
41 #include "form_sendto.h"
42 #include "form_spellchecker.h"
43 #include "form_tabular_create.h"
44 #include "form_texinfo.h"
45 #include "form_thesaurus.h"
49 #include "FormAboutlyx.h"
50 #include "FormBibitem.h"
51 #include "FormBibtex.h"
52 #include "FormCharacter.h"
53 #include "FormCitation.h"
54 #include "FormError.h"
56 #include "FormExternal.h"
57 #include "FormFloat.h"
58 #include "FormForks.h"
59 #include "FormGraphics.h"
60 #include "FormInclude.h"
61 #include "FormIndex.h"
63 #include "FormMinipage.h"
64 #include "FormPreamble.h"
65 #include "FormPrint.h"
67 #include "FormSearch.h"
68 #include "FormSendto.h"
69 #include "FormShowFile.h"
70 #include "FormSpellchecker.h"
71 #include "FormTabularCreate.h"
72 #include "FormTexinfo.h"
73 #include "FormThesaurus.h"
76 #include "FormVCLog.h"
78 #include "FormDocument.h"
79 #include "FormMathsPanel.h"
80 #include "FormParagraph.h"
81 #include "FormPreferences.h"
82 #include "FormTabular.h"
86 /// Are the tooltips on or off?
87 bool Dialogs::tooltipsEnabled()
89 return Tooltips::enabled();
93 Dialogs::Dialogs(LyXView * lv)
95 add(new GUI<ControlAboutlyx, FormAboutlyx,
96 OkCancelPolicy, xformsBC>(*lv, *this));
97 add(new GUI<ControlBibitem, FormBibitem,
98 OkCancelReadOnlyPolicy, xformsBC>(*lv, *this));
99 add(new GUI<ControlBibtex, FormBibtex,
100 OkCancelReadOnlyPolicy, xformsBC>(*lv, *this));
101 add(new GUI<ControlCharacter, FormCharacter,
102 OkApplyCancelReadOnlyPolicy, xformsBC>(*lv, *this));
103 add(new GUI<ControlCitation, FormCitation,
104 NoRepeatedApplyReadOnlyPolicy, xformsBC>(*lv, *this));
105 add(new GUI<ControlError, FormError,
106 OkCancelPolicy, xformsBC>(*lv, *this));
107 add(new GUI<ControlERT, FormERT,
108 NoRepeatedApplyReadOnlyPolicy, xformsBC>(*lv, *this));
109 add(new GUI<ControlExternal, FormExternal,
110 OkApplyCancelReadOnlyPolicy, xformsBC>(*lv, *this));
111 add(new GUI<ControlForks, FormForks,
112 OkApplyCancelPolicy, xformsBC>(*lv, *this));
113 add(new GUI<ControlGraphics, FormGraphics,
114 NoRepeatedApplyReadOnlyPolicy, xformsBC>(*lv, *this));
115 add(new GUI<ControlInclude, FormInclude,
116 OkCancelReadOnlyPolicy, xformsBC>(*lv, *this));
117 add(new GUI<ControlIndex, FormIndex,
118 NoRepeatedApplyReadOnlyPolicy, xformsBC>(*lv, *this));
119 add(new GUI<ControlLog, FormLog,
120 OkCancelPolicy, xformsBC>(*lv, *this));
121 add(new GUI<ControlMinipage, FormMinipage,
122 NoRepeatedApplyReadOnlyPolicy, xformsBC>(*lv, *this));
123 add(new GUI<ControlFloat, FormFloat,
124 NoRepeatedApplyReadOnlyPolicy, xformsBC>(*lv, *this));
125 add(new GUI<ControlPreamble, FormPreamble,
126 NoRepeatedApplyReadOnlyPolicy, xformsBC>(*lv, *this));
127 add(new GUI<ControlPrint, FormPrint,
128 OkApplyCancelPolicy, xformsBC>(*lv, *this));
129 add(new GUI<ControlRef, FormRef,
130 NoRepeatedApplyReadOnlyPolicy, xformsBC>(*lv, *this));
131 add(new GUI<ControlSearch, FormSearch,
132 NoRepeatedApplyReadOnlyPolicy, xformsBC>(*lv, *this));
133 add(new GUI<ControlSendto, FormSendto,
134 OkApplyCancelPolicy, xformsBC>(*lv, *this));
135 add(new GUI<ControlShowFile, FormShowFile,
136 OkCancelPolicy, xformsBC>(*lv, *this));
137 add(new GUI<ControlSpellchecker, FormSpellchecker,
138 NoRepeatedApplyReadOnlyPolicy, xformsBC>(*lv, *this));
139 add(new GUI<ControlTabularCreate, FormTabularCreate,
140 OkApplyCancelReadOnlyPolicy, xformsBC>(*lv, *this));
141 #ifdef HAVE_LIBAIKSAURUS
142 add(new GUI<ControlThesaurus, FormThesaurus,
143 OkApplyCancelReadOnlyPolicy, xformsBC>(*lv, *this));
145 add(new GUI<ControlTexinfo, FormTexinfo,
146 OkCancelPolicy, xformsBC>(*lv, *this));
147 add(new GUI<ControlToc, FormToc,
148 OkCancelPolicy, xformsBC>(*lv, *this));
149 add(new GUI<ControlUrl, FormUrl,
150 NoRepeatedApplyReadOnlyPolicy, xformsBC>(*lv, *this));
151 add(new GUI<ControlVCLog, FormVCLog,
152 OkCancelPolicy, xformsBC>(*lv, *this));
154 add(new FormDocument(lv, this));
155 add(new FormMathsPanel(lv, this));
156 add(new FormParagraph(lv, this));
157 add(new FormPreferences(lv, this));
158 add(new FormTabular(lv, this));
160 // reduce the number of connections needed in
161 // dialogs by a simple connection here.
162 hideAll.connect(hideBufferDependent);