]> git.lyx.org Git - lyx.git/blob - src/frontends/qt2/chardlgimpl.h
Qt2 compilation + LColor cleanup from John
[lyx.git] / src / frontends / qt2 / chardlgimpl.h
1 /**
2  * \file chardlgimpl.h
3  * Copyright 2001 LyX Team
4  * see the file COPYING
5  *
6  * \author Edwin Leuven
7  */
8
9 #ifndef CHARDLGIMPL_H
10 #define CHARDLGIMPL_H
11
12 #include <config.h>
13  
14 #include "chardlg.h"
15 #include "FormCharacter.h"
16 #include <qevent.h>
17 #include <qcheckbox.h>
18 #include <qcombobox.h>
19
20 class LyXFont;
21 class FormCharacter;
22
23 class CharDlgImpl : public CharDlg
24
25         Q_OBJECT
26
27 public:
28         CharDlgImpl(FormCharacter * form, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0 );
29          
30         ~CharDlgImpl();
31         
32         LyXFont getChar();
33         
34         int langItem() { 
35                 return lang->currentItem();
36         };
37         
38         bool toggleAll() { 
39                 return toggleall->isChecked(); 
40         };
41         
42         void setReadOnly(bool);
43         
44 protected:
45         void closeEvent(QCloseEvent * e);
46
47 private:
48         FormCharacter * form_;
49         
50
51 protected slots:
52         
53         void apply_adaptor() {
54                 form_->apply();
55         }
56          
57         void cancel_adaptor() {
58                 form_->close();
59                 hide();
60         }
61          
62         void close_adaptor() {
63                 form_->apply();
64                 form_->close();
65                 hide();
66         }
67
68 };
69
70 #endif // CHARDLGIMPL_H