]> git.lyx.org Git - lyx.git/blob - src/frontends/xforms/FormMathsBitmap.h
implement getLabelList
[lyx.git] / src / frontends / xforms / FormMathsBitmap.h
1 /**
2  * \file FormMathsBitmap.h
3  * Copyright 2001 the LyX Team
4  * Read the file COPYING
5  *
6  * \author Alejandro Aguilar Sierra
7  * \author John Levon, moz@compsoc.man.ac.uk
8  * \author Angus Leeming, a.leeming@ic.ac.uk
9  */
10
11 #ifndef FORM_MATHSBITMAP_H
12 #define FORM_MATHSBITMAP_H
13
14 #include <vector>
15 #include <boost/smart_ptr.hpp>
16
17 #ifdef __GNUG__
18 #pragma interface
19 #endif
20
21 #include "LString.h"
22 #include "FormMathsPanel.h"
23
24 /** 
25  * This class provides an XForms implementation of a maths bitmap form.
26  */
27 class FormMathsBitmap : public FormMathsSub {
28         friend class FormMathsPanel;
29
30   public:
31         ///
32         typedef boost::shared_ptr<FL_OBJECT> bm_ptr;
33         ///
34         FormMathsBitmap(LyXView *, Dialogs * d, FormMathsPanel const &,
35                         std::vector<string> const &);
36         ///
37         void addBitmap(int, int, int, int, int, unsigned char const *,
38                        bool = true);
39
40 private:
41         ///
42         int GetIndex(FL_OBJECT *);
43
44         /// Build the dialog
45         virtual void build();
46         /// apply the data
47         virtual void apply();
48         /// input handler
49         bool input(FL_OBJECT *, long);
50
51         /// Pointer to the actual instantiation of the xforms form
52         virtual FL_FORM * form() const;
53
54         /// The latex names associated with each symbol
55         std::vector<string> latex_;
56         /// The latex name chosen
57         string latex_chosen_;
58         /// Real GUI implementation
59         FL_FORM * form_;
60         /// The bitmap tables
61         std::vector<bm_ptr> bitmaps_;
62
63         /// Border width
64         int ww_;
65         ///
66         int x_;
67         ///
68         int y_;
69         ///
70         int w_;
71         ///
72         int h_;
73 };
74
75
76 #endif // FORM_MATHSBITMAP_H