3 * \file FormMathsBitmap.h
4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Alejandro Aguilar Sierra
9 * \author Angus Leeming
11 * Full author contact details are available in file CREDITS
14 #ifndef FORM_MATHSBITMAP_H
15 #define FORM_MATHSBITMAP_H
22 #include <boost/shared_ptr.hpp>
27 BitmapStore(int nt_in, int nx_in, int ny_in, int bw_in, int bh_in,
28 unsigned char const * data_in, bool vert_in)
29 : nt(nt_in), nx(nx_in), ny(ny_in), bw(bw_in), bh(bh_in),
30 data(data_in), vert(vert_in)
38 unsigned char const * data;
43 struct FD_maths_bitmap
47 FL_OBJECT * button_close;
52 * This class provides an XForms implementation of a maths bitmap form.
57 class FormMathsBitmap : public FormCB<ControlMathSub, FormDB<FD_maths_bitmap> >
61 FormMathsBitmap(string const &, std::vector<string> const &);
63 void addBitmap(int, int, int, int, int, unsigned char const *,
68 int GetIndex(FL_OBJECT *);
75 virtual ButtonPolicy::SMInput input(FL_OBJECT *, long);
77 virtual void update() {}
80 FL_OBJECT * buildBitmap(BitmapStore const & bmstore);
82 /// The latex names associated with each symbol
83 std::vector<string> latex_;
84 /// The latex name chosen
87 /** Temporary store for bitmap data passed to addBitmap()
88 * but before the FL_OBJECT is created in build().
90 std::vector<BitmapStore> bitmaps_;
105 #endif // FORM_MATHSBITMAP_H