]> git.lyx.org Git - lyx.git/blob - src/frontends/gtk/GCharacter.h
Change glob() API to accept a dir parameter.
[lyx.git] / src / frontends / gtk / GCharacter.h
1 // -*- C++ -*-
2 /**
3  * \file GCharacter.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author John Spray
8  * Based on version from xforms frontend
9  *
10  * Full author contact details are available in file CREDITS.
11  */
12
13 #ifndef GCHARACTER_H
14 #define GCHARACTER_H
15
16 #include "GViewBase.h"
17 #include "ControlCharacter.h" // for ControlCharacter enum
18
19 struct LColor_color;
20
21 namespace lyx {
22 namespace frontend {
23
24 /**
25  * This class provides a GTK+ implementation of the Character Dialog.
26  * The character dialog allows users to change the character settings
27  * in their documents.
28  */
29 class GCharacter
30         : public GViewCB<ControlCharacter, GViewGladeB> {
31 public:
32         ///
33         GCharacter(Dialog &);
34 private:
35         /// Apply from dialog
36         virtual void apply();
37
38         /// Build the dialog
39         virtual void doBuild();
40
41         /// Update the dialog.
42         virtual void update();
43
44         void PopulateComboBox(Gtk::ComboBox * combo,
45                               std::vector<std::string> const & strings);
46
47         std::vector<LyXFont::FONT_FAMILY> family_;
48         std::vector<LyXFont::FONT_SERIES> series_;
49         std::vector<LyXFont::FONT_SHAPE> shape_;
50         std::vector<LyXFont::FONT_SIZE> size_;
51         std::vector<FONT_STATE> bar_;
52         std::vector<LColor_color> color_;
53         std::vector<std::string> lang_;
54
55         Gtk::ComboBox * familycombo_;
56         Gtk::ComboBox * seriescombo_;
57         Gtk::ComboBox * shapecombo_;
58         Gtk::ComboBox * colorcombo_;
59         Gtk::ComboBox * languagecombo_;
60         Gtk::ComboBox * sizecombo_;
61         Gtk::ComboBox * misccombo_;
62
63         Gtk::TreeModelColumn<Glib::ustring> stringcol_;
64         Gtk::TreeModel::ColumnRecord cols_;
65
66         Gtk::CheckButton * toggleallcheck_;
67
68         void GCharacter::onChange();
69 };
70
71 } // namespace frontend
72 } // namespace lyx
73
74 #endif