2 /* This file is part of
3 * ======================================================
5 * LyX, The Document Processor
7 * Copyright (C) 2000 The LyX Team.
11 *======================================================*/
13 #ifndef FORM_DOCUMENT_H
14 #define FORM_DOCUMENT_H
28 struct FD_form_tabbed_document;
29 struct FD_form_doc_paper;
30 struct FD_form_doc_class;
31 struct FD_form_doc_language;
32 struct FD_form_doc_options;
33 struct FD_form_doc_bullet;
35 /** This class provides an XForms implementation of the FormDocument Popup.
36 The table-layout-form here changes values for latex-tabulars
39 class FormDocument : public FormBaseBD {
41 /// #FormDocument x(Communicator ..., Popups ...);#
42 FormDocument(LyXView *, Dialogs *);
46 static void ComboInputCB(int, void *, Combox *);
85 virtual bool input( FL_OBJECT *, long );
87 virtual void update();
91 virtual void cancel();
94 virtual FL_FORM * form() const;
97 bool CheckDocumentInput(FL_OBJECT * ob, long);
99 void ChoiceBulletSize(FL_OBJECT * ob, long);
101 void InputBulletLaTeX(FL_OBJECT * ob, long);
103 void BulletDepth(FL_OBJECT * ob, State);
105 void BulletPanel(FL_OBJECT * ob, State);
107 void BulletBMTable(FL_OBJECT * ob, long);
109 void checkMarginValues();
111 void checkReadOnly();
113 void CheckChoiceClass(FL_OBJECT * ob, long);
115 void UpdateLayoutDocument(BufferParams const & params);
118 void paper_update(BufferParams const &);
120 void class_update(BufferParams const &);
122 void language_update(BufferParams const &);
124 void options_update(BufferParams const &);
126 void bullets_update(BufferParams const &);
133 bool language_apply();
135 bool options_apply();
137 void bullets_apply();
139 /// Typedefinitions from the fdesign produced Header file
140 FD_form_tabbed_document * build_tabbed_document();
142 FD_form_doc_paper * build_doc_paper();
144 FD_form_doc_class * build_doc_class();
146 FD_form_doc_language * build_doc_language();
148 FD_form_doc_options * build_doc_options();
150 FD_form_doc_bullet * build_doc_bullet();
152 /// Real GUI implementation.
153 FD_form_tabbed_document * dialog_;
155 FD_form_doc_paper * paper_;
157 FD_form_doc_class * class_;
159 FD_form_doc_language * language_;
161 FD_form_doc_options * options_;
163 FD_form_doc_bullet * bullets_;
169 int current_bullet_panel;
171 int current_bullet_depth;
175 Combox * combo_language;
177 Combox * combo_doc_class;