summaryrefslogtreecommitdiff
path: root/inputmethods
authoralwin <alwin>2004-03-02 12:14:15 (UTC)
committer alwin <alwin>2004-03-02 12:14:15 (UTC)
commit0d59c780513da78033f4d9040475dee9db0256d4 (patch) (unidiff)
tree503d320b4aa3daae9982082e7b34e3e2c48bdfb7 /inputmethods
parenta0981652d61776d70f25980f035748b21339e946 (diff)
downloadopie-0d59c780513da78033f4d9040475dee9db0256d4.zip
opie-0d59c780513da78033f4d9040475dee9db0256d4.tar.gz
opie-0d59c780513da78033f4d9040475dee9db0256d4.tar.bz2
run the optimize_connect script
the whole cvs is tagged with "before_optimize_connect" if there are problems you can check the diff (but it had compiled and run here)
Diffstat (limited to 'inputmethods') (more/less context) (ignore whitespace changes)
-rw-r--r--inputmethods/handwriting/qimpenhelp.cpp12
-rw-r--r--inputmethods/handwriting/qimpeninput.cpp24
-rw-r--r--inputmethods/handwriting/qimpensetup.cpp12
-rw-r--r--inputmethods/multikey/keyboard.cpp4
4 files changed, 26 insertions, 26 deletions
diff --git a/inputmethods/handwriting/qimpenhelp.cpp b/inputmethods/handwriting/qimpenhelp.cpp
index a294301..0727931 100644
--- a/inputmethods/handwriting/qimpenhelp.cpp
+++ b/inputmethods/handwriting/qimpenhelp.cpp
@@ -154,53 +154,53 @@ HandwritingTrainer::HandwritingTrainer( QIMPenProfile *p, QWidget *parent, const
154 gl->addWidget(charList, 1, 0); 154 gl->addWidget(charList, 1, 0);
155 155
156 result = new QLabel( this ); 156 result = new QLabel( this );
157 result->setAlignment(AlignLeft | AlignVCenter | WordBreak); 157 result->setAlignment(AlignLeft | AlignVCenter | WordBreak);
158 result->setText( 158 result->setText(
159 tr( "Select a reference character from the list. Practice writing in " 159 tr( "Select a reference character from the list. Practice writing in "
160 "the area on the right.")); 160 "the area on the right."));
161 gl->addMultiCellWidget(result, 1, 2, 1, 1); 161 gl->addMultiCellWidget(result, 1, 2, 1, 1);
162 162
163 matcher = new QIMPenMatch( this ); 163 matcher = new QIMPenMatch( this );
164 matcher->setCharSet( currentSet ); 164 matcher->setCharSet( currentSet );
165 connect( matcher, SIGNAL(noMatch()), this, SLOT(noMatch()) ); 165 connect( matcher, SIGNAL(noMatch()), this, SLOT(noMatch()) );
166 connect( matcher, SIGNAL(matchedCharacters(const QIMPenCharMatchList &)), 166 connect( matcher, SIGNAL(matchedCharacters(const QIMPenCharMatchList&)),
167 this, SLOT(matched(const QIMPenCharMatchList &)) ); 167 this, SLOT(matched(const QIMPenCharMatchList&)) );
168 168
169 QHBoxLayout *hb = new QHBoxLayout(); 169 QHBoxLayout *hb = new QHBoxLayout();
170 gl->addLayout( hb, 2, 0 ); 170 gl->addLayout( hb, 2, 0 );
171 prevBtn = new QPushButton( this ); 171 prevBtn = new QPushButton( this );
172 prevBtn->setPixmap( QPixmap( (const char **)left_xpm ) ); 172 prevBtn->setPixmap( QPixmap( (const char **)left_xpm ) );
173 connect( prevBtn, SIGNAL(clicked()), SLOT(prevChar())); 173 connect( prevBtn, SIGNAL(clicked()), SLOT(prevChar()));
174 hb->addWidget( prevBtn ); 174 hb->addWidget( prevBtn );
175 175
176 nextBtn = new QPushButton( this ); 176 nextBtn = new QPushButton( this );
177 nextBtn->setPixmap( QPixmap( (const char **)right_xpm ) ); 177 nextBtn->setPixmap( QPixmap( (const char **)right_xpm ) );
178 connect( nextBtn, SIGNAL(clicked()), SLOT(nextChar())); 178 connect( nextBtn, SIGNAL(clicked()), SLOT(nextChar()));
179 hb->addWidget( nextBtn ); 179 hb->addWidget( nextBtn );
180 180
181 refPw = new QIMPenWidget( this ); 181 refPw = new QIMPenWidget( this );
182 refPw->setReadOnly( TRUE ); 182 refPw->setReadOnly( TRUE );
183 gl->addWidget( refPw, 3, 0 ); 183 gl->addWidget( refPw, 3, 0 );
184 184
185 pracPw = new QIMPenWidget( this ); 185 pracPw = new QIMPenWidget( this );
186 connect( matcher, SIGNAL(removeStroke()), pracPw, SLOT(removeStroke()) ); 186 connect( matcher, SIGNAL(removeStroke()), pracPw, SLOT(removeStroke()) );
187 connect( pracPw, SIGNAL(beginStroke()), 187 connect( pracPw, SIGNAL(beginStroke()),
188 this, SLOT(beginStroke()) ); 188 this, SLOT(beginStroke()) );
189 connect( pracPw, SIGNAL(stroke( QIMPenStroke * )), 189 connect( pracPw, SIGNAL(stroke(QIMPenStroke*)),
190 this, SLOT(strokeEntered( QIMPenStroke * )) ); 190 this, SLOT(strokeEntered(QIMPenStroke*)) );
191 connect( pracPw, SIGNAL(beginStroke()), 191 connect( pracPw, SIGNAL(beginStroke()),
192 matcher, SLOT(beginStroke()) ); 192 matcher, SLOT(beginStroke()) );
193 connect( pracPw, SIGNAL(stroke( QIMPenStroke * )), 193 connect( pracPw, SIGNAL(stroke(QIMPenStroke*)),
194 matcher, SLOT(strokeEntered( QIMPenStroke * )) ); 194 matcher, SLOT(strokeEntered(QIMPenStroke*)) );
195 gl->addWidget( pracPw, 3, 1 ); 195 gl->addWidget( pracPw, 3, 1 );
196 196
197 redrawTimer = new QTimer( this ); 197 redrawTimer = new QTimer( this );
198 connect( redrawTimer, SIGNAL(timeout()), this, SLOT(redrawChar()) ); 198 connect( redrawTimer, SIGNAL(timeout()), this, SLOT(redrawChar()) );
199 redrawTimer->start( 5000 ); 199 redrawTimer->start( 5000 );
200 200
201 currentSet = 0; 201 currentSet = 0;
202 charSetCombo->setCurrentItem( 1 ); 202 charSetCombo->setCurrentItem( 1 );
203 selectCharSet( 1 ); 203 selectCharSet( 1 );
204} 204}
205 205
206HandwritingTrainer::~HandwritingTrainer() 206HandwritingTrainer::~HandwritingTrainer()
diff --git a/inputmethods/handwriting/qimpeninput.cpp b/inputmethods/handwriting/qimpeninput.cpp
index db33c9b..d073cdf 100644
--- a/inputmethods/handwriting/qimpeninput.cpp
+++ b/inputmethods/handwriting/qimpeninput.cpp
@@ -140,28 +140,28 @@ QIMPenInput::QIMPenInput( QWidget *parent, const char *name, WFlags wf )
140 setFrameStyle( Box | Plain ); 140 setFrameStyle( Box | Plain );
141 141
142 profileList.setAutoDelete( true ); 142 profileList.setAutoDelete( true );
143 143
144 matcher = new QIMPenMatch( this ); 144 matcher = new QIMPenMatch( this );
145 connect( matcher, SIGNAL(keypress(uint)), this, SLOT(keypress(uint)) ); 145 connect( matcher, SIGNAL(keypress(uint)), this, SLOT(keypress(uint)) );
146 connect( matcher, SIGNAL(erase()), this, SLOT(erase()) ); 146 connect( matcher, SIGNAL(erase()), this, SLOT(erase()) );
147 147
148 QGridLayout *gl = new QGridLayout( this, 5, 2, 1, 0 ); 148 QGridLayout *gl = new QGridLayout( this, 5, 2, 1, 0 );
149 gl->setColStretch( 0, 1 ); 149 gl->setColStretch( 0, 1 );
150 150
151 wordPicker = new QIMPenWordPick( this ); 151 wordPicker = new QIMPenWordPick( this );
152 connect( wordPicker, SIGNAL(wordClicked(const QString &)), 152 connect( wordPicker, SIGNAL(wordClicked(const QString&)),
153 this, SLOT(wordPicked(const QString &)) ); 153 this, SLOT(wordPicked(const QString&)) );
154 connect( matcher, SIGNAL(matchedCharacters(const QIMPenCharMatchList &)), 154 connect( matcher, SIGNAL(matchedCharacters(const QIMPenCharMatchList&)),
155 this, SLOT(matchedCharacters(const QIMPenCharMatchList &)) ); 155 this, SLOT(matchedCharacters(const QIMPenCharMatchList&)) );
156 connect( matcher, SIGNAL(matchedWords(const QIMPenMatch::MatchWordList&)), 156 connect( matcher, SIGNAL(matchedWords(const QIMPenMatch::MatchWordList&)),
157 wordPicker, SLOT(setWords(const QIMPenMatch::MatchWordList&)) ); 157 wordPicker, SLOT(setWords(const QIMPenMatch::MatchWordList&)) );
158 QFont f("smallsmooth",9); 158 QFont f("smallsmooth",9);
159 QFontInfo fi( f ); 159 QFontInfo fi( f );
160 wordPicker->setFont( f ); 160 wordPicker->setFont( f );
161 wordPicker->setBackgroundColor( white ); 161 wordPicker->setBackgroundColor( white );
162 gl->addMultiCellWidget( wordPicker, 0, 0, 0, 1 ); 162 gl->addMultiCellWidget( wordPicker, 0, 0, 0, 1 );
163 if ( !Global::fixedDawg().root() || !matcher->isWordMatchingEnabled() ) 163 if ( !Global::fixedDawg().root() || !matcher->isWordMatchingEnabled() )
164 wordPicker->hide(); 164 wordPicker->hide();
165 165
166 pw = new QIMPenWidget( this ); 166 pw = new QIMPenWidget( this );
167 gl->addMultiCellWidget( pw, 1, 4, 0, 0 ); 167 gl->addMultiCellWidget( pw, 1, 4, 0, 0 );
@@ -191,34 +191,34 @@ QIMPenInput::QIMPenInput( QWidget *parent, const char *name, WFlags wf )
191 gl->addWidget( helpBtn, 3, 1 ); 191 gl->addWidget( helpBtn, 3, 1 );
192 connect( helpBtn, SIGNAL(clicked()), SLOT(help())); 192 connect( helpBtn, SIGNAL(clicked()), SLOT(help()));
193 193
194 QPixmap pm( (const char **)pen_xpm ); 194 QPixmap pm( (const char **)pen_xpm );
195 setupBtn = new QPushButton( this ); 195 setupBtn = new QPushButton( this );
196 setupBtn->setFocusPolicy( NoFocus ); 196 setupBtn->setFocusPolicy( NoFocus );
197 setupBtn->setPixmap( pm ); 197 setupBtn->setPixmap( pm );
198 setupBtn->setFixedHeight(bh); 198 setupBtn->setFixedHeight(bh);
199 gl->addWidget( setupBtn, 4, 1 ); 199 gl->addWidget( setupBtn, 4, 1 );
200 connect( setupBtn, SIGNAL(clicked()), SLOT(setup())); 200 connect( setupBtn, SIGNAL(clicked()), SLOT(setup()));
201 201
202 connect( matcher, SIGNAL(removeStroke()), pw, SLOT(removeStroke()) ); 202 connect( matcher, SIGNAL(removeStroke()), pw, SLOT(removeStroke()) );
203 connect( pw, SIGNAL(changeCharSet( QIMPenCharSet * )), 203 connect( pw, SIGNAL(changeCharSet(QIMPenCharSet*)),
204 matcher, SLOT(setCharSet( QIMPenCharSet * )) ); 204 matcher, SLOT(setCharSet(QIMPenCharSet*)) );
205 connect( pw, SIGNAL(changeCharSet( int )), 205 connect( pw, SIGNAL(changeCharSet(int)),
206 this, SLOT(selectCharSet( int )) ); 206 this, SLOT(selectCharSet(int)) );
207 connect( pw, SIGNAL(beginStroke()), 207 connect( pw, SIGNAL(beginStroke()),
208 matcher, SLOT(beginStroke()) ); 208 matcher, SLOT(beginStroke()) );
209 connect( pw, SIGNAL(stroke( QIMPenStroke * )), 209 connect( pw, SIGNAL(stroke(QIMPenStroke*)),
210 this, SLOT(strokeEntered( QIMPenStroke * )) ); 210 this, SLOT(strokeEntered(QIMPenStroke*)) );
211 connect( pw, SIGNAL(stroke( QIMPenStroke * )), 211 connect( pw, SIGNAL(stroke(QIMPenStroke*)),
212 matcher, SLOT(strokeEntered( QIMPenStroke * )) ); 212 matcher, SLOT(strokeEntered(QIMPenStroke*)) );
213 213
214 shortcutCharSet = 0; 214 shortcutCharSet = 0;
215 currCharSet = 0; 215 currCharSet = 0;
216 setupDlg = 0; 216 setupDlg = 0;
217 profile = 0; 217 profile = 0;
218 mode = Normal; 218 mode = Normal;
219 219
220 loadProfiles(); 220 loadProfiles();
221} 221}
222 222
223QIMPenInput::~QIMPenInput() 223QIMPenInput::~QIMPenInput()
224{ 224{
diff --git a/inputmethods/handwriting/qimpensetup.cpp b/inputmethods/handwriting/qimpensetup.cpp
index d0f9ffd..d1297a9 100644
--- a/inputmethods/handwriting/qimpensetup.cpp
+++ b/inputmethods/handwriting/qimpensetup.cpp
@@ -92,26 +92,26 @@ QIMPenSetup::QIMPenSetup( QIMPenProfile *p, QWidget *parent,
92 setCaption( tr("Setup Handwriting Input") ); 92 setCaption( tr("Setup Handwriting Input") );
93 93
94 QVBoxLayout *vb = new QVBoxLayout( this ); 94 QVBoxLayout *vb = new QVBoxLayout( this );
95 95
96#define MULTIPROFILE 96#define MULTIPROFILE
97#ifdef MULTIPROFILE 97#ifdef MULTIPROFILE
98 profileList.setAutoDelete( true ); 98 profileList.setAutoDelete( true );
99 QHBoxLayout *hb = new QHBoxLayout( vb ); 99 QHBoxLayout *hb = new QHBoxLayout( vb );
100 hb->setMargin( 6 ); 100 hb->setMargin( 6 );
101 QLabel *l = new QLabel( tr("Character Profile:"), this ); 101 QLabel *l = new QLabel( tr("Character Profile:"), this );
102 hb->addWidget( l ); 102 hb->addWidget( l );
103 profileCombo = new QComboBox( this ); 103 profileCombo = new QComboBox( this );
104 connect( profileCombo, SIGNAL(activated(const QString &)), 104 connect( profileCombo, SIGNAL(activated(const QString&)),
105 this, SLOT(selectProfile(const QString &)) ); 105 this, SLOT(selectProfile(const QString&)) );
106 hb->addWidget( profileCombo ); 106 hb->addWidget( profileCombo );
107#else 107#else
108 profileList.append( profile ); 108 profileList.append( profile );
109#endif 109#endif
110 110
111 qWarning("profiles: %d", profileList.count()); 111 qWarning("profiles: %d", profileList.count());
112 112
113 QTabWidget *tw = new QTabWidget( this ); 113 QTabWidget *tw = new QTabWidget( this );
114 vb->addWidget( tw ); 114 vb->addWidget( tw );
115 115
116 pref = new QIMPenPrefBase( this ); 116 pref = new QIMPenPrefBase( this );
117 tw->addTab( pref, tr("Preferences") ); 117 tw->addTab( pref, tr("Preferences") );
@@ -238,26 +238,26 @@ QIMPenInputCharDlg::QIMPenInputCharDlg( QWidget *parent, const char *name,
238 uni = 0; 238 uni = 0;
239 239
240 QVBoxLayout *vb = new QVBoxLayout( this, 10 ); 240 QVBoxLayout *vb = new QVBoxLayout( this, 10 );
241 241
242 QHBoxLayout *hb = new QHBoxLayout(); 242 QHBoxLayout *hb = new QHBoxLayout();
243 vb->addLayout( hb ); 243 vb->addLayout( hb );
244 244
245 QLabel *label = new QLabel( tr("Character:"), this ); 245 QLabel *label = new QLabel( tr("Character:"), this );
246 hb->addWidget( label ); 246 hb->addWidget( label );
247 247
248 QComboBox *cb = new QComboBox( TRUE, this ); 248 QComboBox *cb = new QComboBox( TRUE, this );
249 connect( cb, SIGNAL(activated(int)), SLOT(setSpecial(int)) ); 249 connect( cb, SIGNAL(activated(int)), SLOT(setSpecial(int)) );
250 connect( cb, SIGNAL(textChanged(const QString &)), 250 connect( cb, SIGNAL(textChanged(const QString&)),
251 SLOT(setCharacter(const QString &)) ); 251 SLOT(setCharacter(const QString&)) );
252 addSpecial( cb ); 252 addSpecial( cb );
253 cb->setEditText( "" ); 253 cb->setEditText( "" );
254 hb->addWidget( cb ); 254 hb->addWidget( cb );
255 255
256 hb = new QHBoxLayout(); 256 hb = new QHBoxLayout();
257 vb->addLayout( hb ); 257 vb->addLayout( hb );
258 258
259 QPushButton *pb = new QPushButton( "OK", this ); 259 QPushButton *pb = new QPushButton( "OK", this );
260 connect( pb, SIGNAL(clicked()), SLOT(accept())); 260 connect( pb, SIGNAL(clicked()), SLOT(accept()));
261 hb->addWidget( pb ); 261 hb->addWidget( pb );
262 pb = new QPushButton( "Cancel", this ); 262 pb = new QPushButton( "Cancel", this );
263 connect( pb, SIGNAL(clicked()), SLOT(reject())); 263 connect( pb, SIGNAL(clicked()), SLOT(reject()));
@@ -331,26 +331,26 @@ QIMPenEdit::QIMPenEdit( QIMPenProfile *p, QWidget *parent,
331 for ( ; it.current(); ++it ) { 331 for ( ; it.current(); ++it ) {
332 charSetCombo->insertItem( it.current()->description() ); 332 charSetCombo->insertItem( it.current()->description() );
333 } 333 }
334 334
335 charList = new QListBox( this ); 335 charList = new QListBox( this );
336 charList->setMinimumHeight( charList->sizeHint().height() ); 336 charList->setMinimumHeight( charList->sizeHint().height() );
337 connect( charList, SIGNAL(highlighted(int)), SLOT(selectChar(int)) ); 337 connect( charList, SIGNAL(highlighted(int)), SLOT(selectChar(int)) );
338 gl->addWidget( charList, 1, 0 ); 338 gl->addWidget( charList, 1, 0 );
339 339
340 pw = new QIMPenWidget( this ); 340 pw = new QIMPenWidget( this );
341 pw->setFixedHeight( 75 ); 341 pw->setFixedHeight( 75 );
342 gl->addMultiCellWidget( pw, 2, 3, 0, 0 ); 342 gl->addMultiCellWidget( pw, 2, 3, 0, 0 );
343 connect( pw, SIGNAL(stroke(QIMPenStroke *)), 343 connect( pw, SIGNAL(stroke(QIMPenStroke*)),
344 SLOT(newStroke(QIMPenStroke *)) ); 344 SLOT(newStroke(QIMPenStroke*)) );
345 345
346 QVBoxLayout *vb = new QVBoxLayout(); 346 QVBoxLayout *vb = new QVBoxLayout();
347 gl->addLayout( vb, 1, 1 ); 347 gl->addLayout( vb, 1, 1 );
348 newBtn = new QPushButton( tr("New..."), this ); 348 newBtn = new QPushButton( tr("New..."), this );
349 connect( newBtn, SIGNAL(clicked()), SLOT(addNewChar()) ); 349 connect( newBtn, SIGNAL(clicked()), SLOT(addNewChar()) );
350 vb->addWidget( newBtn ); 350 vb->addWidget( newBtn );
351 351
352 addBtn = new QPushButton( tr("Add"), this ); 352 addBtn = new QPushButton( tr("Add"), this );
353 connect( addBtn, SIGNAL(clicked()), SLOT(addChar()) ); 353 connect( addBtn, SIGNAL(clicked()), SLOT(addChar()) );
354 vb->addWidget( addBtn ); 354 vb->addWidget( addBtn );
355 355
356 removeBtn = new QPushButton( tr("Remove"), this ); 356 removeBtn = new QPushButton( tr("Remove"), this );
diff --git a/inputmethods/multikey/keyboard.cpp b/inputmethods/multikey/keyboard.cpp
index aec0ad3..4f4f25f 100644
--- a/inputmethods/multikey/keyboard.cpp
+++ b/inputmethods/multikey/keyboard.cpp
@@ -86,26 +86,26 @@ Keyboard::Keyboard(QWidget* parent, const char* _name, WFlags f) :
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
102Keyboard::~Keyboard() { 102Keyboard::~Keyboard() {
103 103
104 if ( configdlg ) { 104 if ( configdlg ) {
105 delete configdlg; 105 delete configdlg;
106 configdlg = 0; 106 configdlg = 0;
107 } 107 }
108 108
109} 109}
110 110
111/* Keyboard::resizeEvent {{{1 */ 111/* Keyboard::resizeEvent {{{1 */