-rw-r--r-- | inputmethods/multikey/keyboard.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/inputmethods/multikey/keyboard.cpp b/inputmethods/multikey/keyboard.cpp index f8cafd5..96fb484 100644 --- a/inputmethods/multikey/keyboard.cpp +++ b/inputmethods/multikey/keyboard.cpp | |||
@@ -45,61 +45,61 @@ static const char * const kb_config_xpm[] = { | |||
45 | ". c #000000", | 45 | ". c #000000", |
46 | " ", | 46 | " ", |
47 | " . ", | 47 | " . ", |
48 | " ... ", | 48 | " ... ", |
49 | " ..... ", | 49 | " ..... ", |
50 | " . ", | 50 | " . ", |
51 | " . ", | 51 | " . ", |
52 | " "}; | 52 | " "}; |
53 | 53 | ||
54 | /* Keyboard::Keyboard {{{1 */ | 54 | /* Keyboard::Keyboard {{{1 */ |
55 | Keyboard::Keyboard(QWidget* parent, const char* _name, WFlags f) : | 55 | Keyboard::Keyboard(QWidget* parent, const char* _name, WFlags f) : |
56 | QFrame(parent, _name, f), shift(0), lock(0), ctrl(0), alt(0), | 56 | QFrame(parent, _name, f), shift(0), lock(0), ctrl(0), alt(0), |
57 | meta(0), circumflex(0), diaeresis(0), baccent(0), accent(0), | 57 | meta(0), circumflex(0), diaeresis(0), baccent(0), accent(0), |
58 | useLargeKeys(TRUE), usePicks(0), useRepeat(0), | 58 | useLargeKeys(TRUE), usePicks(0), useRepeat(0), |
59 | pressedKeyRow(-1), pressedKeyCol(-1), | 59 | pressedKeyRow(-1), pressedKeyCol(-1), |
60 | unicode(-1), qkeycode(0), modifiers(0), schar(0), mchar(0), echar(0), | 60 | unicode(-1), qkeycode(0), modifiers(0), schar(0), mchar(0), echar(0), |
61 | configdlg(0) | 61 | configdlg(0) |
62 | 62 | ||
63 | { | 63 | { |
64 | 64 | ||
65 | // get the default font | 65 | // get the default font |
66 | Config *config = new Config( "qpe" ); | 66 | Config *config = new Config( "qpe" ); |
67 | config->setGroup( "Appearance" ); | 67 | config->setGroup( "Appearance" ); |
68 | QString familyStr = config->readEntry( "FontFamily", "smallsmooth" ); | 68 | QString familyStr = config->readEntry( "FontFamily", "smallsmooth" ); |
69 | int fontSize = config->readNumEntry( "FontSize", 10 ); | ||
69 | delete config; | 70 | delete config; |
70 | 71 | ||
71 | config = new Config("multikey"); | 72 | config = new Config("multikey"); |
72 | config->setGroup ("general"); | 73 | config->setGroup ("general"); |
73 | usePicks = config->readBoolEntry ("usePickboard", 0); // default closed | 74 | usePicks = config->readBoolEntry ("usePickboard", 0); // default closed |
74 | useRepeat = config->readBoolEntry ("useRepeat", 1); | 75 | useRepeat = config->readBoolEntry ("useRepeat", 1); |
75 | delete config; | 76 | delete config; |
76 | 77 | ||
77 | 78 | setFont( QFont( familyStr, fontSize ) ); | |
78 | setFont( QFont( familyStr, 10 ) ); | ||
79 | 79 | ||
80 | picks = new KeyboardPicks( this ); | 80 | picks = new KeyboardPicks( this ); |
81 | picks->setFont( QFont( familyStr, 10 ) ); | 81 | picks->setFont( QFont( familyStr, fontSize ) ); |
82 | picks->initialise(); | 82 | picks->initialise(); |
83 | if (usePicks) { | 83 | if (usePicks) { |
84 | 84 | ||
85 | QObject::connect( picks, SIGNAL(key(ushort,ushort,ushort,bool,bool) ), | 85 | QObject::connect( picks, SIGNAL(key(ushort,ushort,ushort,bool,bool) ), |
86 | this, SIGNAL(key(ushort,ushort,ushort,bool,bool)) ); | 86 | this, SIGNAL(key(ushort,ushort,ushort,bool,bool)) ); |
87 | 87 | ||
88 | } else picks->hide(); | 88 | } else picks->hide(); |
89 | 89 | ||
90 | loadKeyboardColors(); | 90 | loadKeyboardColors(); |
91 | 91 | ||
92 | keys = new Keys(); | 92 | keys = new Keys(); |
93 | 93 | ||
94 | repeatTimer = new QTimer( this ); | 94 | repeatTimer = new QTimer( this ); |
95 | connect( repeatTimer, SIGNAL(timeout()), this, SLOT(repeat()) ); | 95 | connect( repeatTimer, SIGNAL(timeout()), this, SLOT(repeat()) ); |
96 | 96 | ||
97 | QCopChannel* kbdChannel = new QCopChannel("MultiKey/Keyboard", this); | 97 | QCopChannel* kbdChannel = new QCopChannel("MultiKey/Keyboard", this); |
98 | connect(kbdChannel, SIGNAL(received(const QCString&,const QByteArray&)), | 98 | connect(kbdChannel, SIGNAL(received(const QCString&,const QByteArray&)), |
99 | this, SLOT(receive(const QCString&,const QByteArray&))); | 99 | this, SLOT(receive(const QCString&,const QByteArray&))); |
100 | } | 100 | } |
101 | 101 | ||
102 | Keyboard::~Keyboard() { | 102 | Keyboard::~Keyboard() { |
103 | 103 | ||
104 | if ( configdlg ) { | 104 | if ( configdlg ) { |
105 | delete configdlg; | 105 | delete configdlg; |