]> git.lyx.org Git - features.git/blob - src/frontends/qt2/Dialogs.C
fix up build (also need patch sent to list), bring back doc/par dialogs,
[features.git] / src / frontends / qt2 / Dialogs.C
1 /**
2  * \file Dialogs.C
3  * Copyright 2001 the LyX Team
4  * Read the file COPYING
5  *
6  */
7
8 #include <config.h>
9
10 #ifdef __GNUG__
11 #pragma implementation
12 #endif
13
14 // the dialog definitions
15 #include "QAboutDialog.h"
16 #include "QBibitemDialog.h"
17 #include "QBibtexDialog.h"
18 #include "QCharacterDialog.h"
19 #include "QCitationDialog.h"
20 #include "QErrorDialog.h"
21 #include "QERTDialog.h"
22 #include "QExternalDialog.h"
23 #include "QFloatDialog.h"
24 #include "QGraphicsDialog.h"
25 #include "QIncludeDialog.h"
26 #include "QIndexDialog.h"
27 #include "QLogDialog.h"
28 #include "QMinipageDialog.h"
29 #include "QPreambleDialog.h"
30 #include "QPrintDialog.h"
31 #include "QRefDialog.h"
32 #include "QSearchDialog.h"
33 #include "QShowFileDialog.h"
34 #include "QSpellcheckerDialog.h"
35 #include "QTabularCreateDialog.h"
36 #include "QTexinfoDialog.h"
37 #include "QThesaurusDialog.h"
38 #include "QTocDialog.h"
39 #include "QURLDialog.h"
40 #include "QVCLogDialog.h"
41
42 #include "QAbout.h"
43 #include "QBibitem.h"
44 #include "QBibtex.h"
45 #include "QCharacter.h"
46 #include "QCitation.h"
47 #include "QError.h"
48 #include "QERT.h"
49 #include "QExternal.h"
50 #include "QFloat.h"
51 #include "QGraphics.h"
52 #include "QInclude.h"
53 #include "QIndex.h"
54 #include "QLog.h"
55 #include "QMinipage.h"
56 #include "QPreamble.h"
57 #include "QPrint.h"
58 #include "QRef.h"
59 #include "QSearch.h"
60 #include "QShowFile.h"
61 #include "QSpellchecker.h"
62 #include "QTabularCreate.h"
63 #include "QTexinfo.h"
64 #include "QToc.h"
65 #include "QThesaurus.h"
66 #include "QURL.h"
67 #include "QVCLog.h"
68
69 #include "QtLyXView.h"
70 #include "Dialogs.h"
71 #include "BufferView.h"
72 #include "buffer.h"
73 #include "Qt2BC.h"
74
75 // xforms stuff
76 #include "xforms/FormDocument.h"
77 #include "xforms/FormMathsPanel.h"
78 #include "xforms/FormParagraph.h"
79 #include "xforms/FormPreferences.h"
80 #include "xforms/FormShowFile.h"
81 #include "xforms/FormTabular.h"
82  
83 #include "graphics/GraphicsImageXPM.h"
84  
85 #include "GUI.h"
86
87 // this makes no real sense for Qt2
88 SigC::Signal0<void> Dialogs::redrawGUI;
89
90
91 Dialogs::Dialogs(LyXView * lv)
92 {
93         // dialogs that have been converted to new scheme
94         add(new GUICitation<QCitation, Qt2BC>(*lv, *this));
95         add(new GUIAboutlyx<QAbout, Qt2BC>(*lv, *this));
96         add(new GUIBibitem<QBibitem, Qt2BC>(*lv, *this));
97         add(new GUIBibtex<QBibtex, Qt2BC>(*lv, *this));
98         add(new GUICharacter<QCharacter, Qt2BC>(*lv, *this));
99         add(new GUIError<QError, Qt2BC>(*lv, *this));
100         add(new GUIERT<QERT, Qt2BC>(*lv, *this));
101         add(new GUIExternal<QExternal, Qt2BC>(*lv, *this));
102         add(new GUIFloat<QFloat, Qt2BC>(*lv, *this));
103         add(new GUIGraphics<QGraphics, Qt2BC>(*lv, *this));
104         add(new GUIInclude<QInclude, Qt2BC>(*lv, *this));
105         add(new GUIIndex<QIndex, Qt2BC>(*lv, *this));
106         add(new GUILog<QLog, Qt2BC>(*lv, *this));
107         add(new GUIMinipage<QMinipage, Qt2BC>(*lv, *this));
108         add(new GUIPreamble<QPreamble, Qt2BC>(*lv, *this)); 
109         add(new GUIPrint<QPrint, Qt2BC>(*lv, *this));
110         add(new GUIRef<QRef, Qt2BC>(*lv, *this));
111         add(new GUISearch<QSearch, Qt2BC>(*lv, *this)); 
112         add(new GUIShowFile<QShowFile, Qt2BC>(*lv, *this));
113         add(new GUISpellchecker<QSpellchecker, Qt2BC>(*lv, *this));
114         add(new GUITabularCreate<QTabularCreate, Qt2BC>(*lv, *this));
115         add(new GUITexinfo<QTexinfo, Qt2BC>(*lv, *this));
116         add(new GUIThesaurus<QThesaurus, Qt2BC>(*lv, *this));
117         add(new GUIToc<QToc, Qt2BC>(*lv, *this));
118         add(new GUIUrl<QURL, Qt2BC>(*lv, *this));
119         add(new GUIVCLog<QVCLog, Qt2BC>(*lv, *this));
120
121         // dialogs not yet MVCd
122         add(new FormDocument(lv, this));
123         add(new FormMathsPanel(lv, this));
124         add(new FormParagraph(lv, this));
125         add(new FormPreferences(lv, this));
126         add(new FormTabular(lv, this));
127  
128         // reduce the number of connections needed in
129         // dialogs by a simple connection here.
130         hideAll.connect(hideBufferDependent.slot());
131 }
132  
133  
134 // Called bu the graphics cache to connect the approriate frontend
135 // image loading routines to the LyX kernel.
136 void Dialogs::initialiseGraphics()
137 {
138         using namespace grfx;
139         using SigC::slot;
140     
141         // connect the image loader based on the XPM library
142         GImage::newImage.connect(slot(&GImageXPM::newImage));
143         GImage::loadableFormats.connect(slot(&GImageXPM::loadableFormats));
144 }