]> git.lyx.org Git - lyx.git/blob - src/frontends/xforms/FormGraphics.h
J�rgen S's patch to the graphics dialog.
[lyx.git] / src / frontends / xforms / FormGraphics.h
1 // -*- C++ -*-
2 /* This file is part of
3  * ====================================================== 
4  *
5  *           LyX, The Document Processor
6  *
7  *           Copyright 2000-2001 The LyX Team.
8  *
9  * ======================================================
10  *
11  * \file FormGraphics.h
12  * \author Baruch Even, baruch.even@writeme.com
13  * \author Herbert Voss, voss@lyx.org
14  */
15
16 #ifndef FORMGRAPHICS_H
17 #define FORMGRAPHICS_H
18
19 #include <boost/smart_ptr.hpp>
20
21 #ifdef __GNUG__
22 #pragma interface
23 #endif 
24
25 #include "FormBase.h"
26 #include "RadioButtonGroup.h"
27
28 class ControlGraphics;
29 struct FD_form_graphics;
30 struct FD_form_file;
31 struct FD_form_size;
32 struct FD_form_bbox;
33 struct FD_form_special;
34
35 /** This class provides an XForms implementation of the Graphics Dialog.
36  */
37 class FormGraphics : public FormCB<ControlGraphics, FormDB<FD_form_graphics> > {
38 public:
39         ///
40         FormGraphics(ControlGraphics &);
41
42 private:
43
44         /** Redraw the form (on receipt of a Signal indicating, for example,
45             that the xforms colours have been re-mapped). */
46         virtual void redraw();
47         /// Set the Params variable for the Controller.
48         virtual void apply();
49         /// Build the dialog.
50         virtual void build();
51         /// Update dialog before/whilst showing it.
52         virtual void update();
53         /// Filter the inputs on callback from xforms
54         virtual ButtonPolicy::SMInput input(FL_OBJECT *, long);
55         /// 
56         void help();
57
58         /// Verify that the input is correct. If not disable ok/apply buttons.
59         ButtonPolicy::SMInput checkInput();
60
61         /// Fdesign generated method
62         FD_form_graphics * build_graphics();
63         ///
64         FD_form_file * build_file();
65         ///
66         FD_form_size * build_size();
67         ///
68         FD_form_bbox * build_bbox();
69         ///
70         FD_form_special * build_special();
71
72         /// Real GUI implementation.
73         boost::scoped_ptr<FD_form_file> file_;
74         ///
75         boost::scoped_ptr<FD_form_size> size_;
76         ///
77         boost::scoped_ptr<FD_form_bbox> bbox_;
78         ///
79         boost::scoped_ptr<FD_form_special> special_;
80 };
81
82 #endif  // FORMGRAPHICS_H