summaryrefslogtreecommitdiff
path: root/inputmethods
Unidiff
Diffstat (limited to 'inputmethods') (more/less context) (ignore whitespace changes)
-rw-r--r--inputmethods/handwriting/qimpenchar.h2
-rw-r--r--inputmethods/handwriting/qimpenprofile.cpp3
-rw-r--r--inputmethods/handwriting/qimpensetup.cpp17
-rw-r--r--inputmethods/handwriting/qimpensetup.h1
4 files changed, 19 insertions, 4 deletions
diff --git a/inputmethods/handwriting/qimpenchar.h b/inputmethods/handwriting/qimpenchar.h
index e4e7645..92ee2c1 100644
--- a/inputmethods/handwriting/qimpenchar.h
+++ b/inputmethods/handwriting/qimpenchar.h
@@ -117,7 +117,7 @@ public:
117 void addChar( QIMPenChar *ch ); 117 void addChar( QIMPenChar *ch );
118 void removeChar( QIMPenChar *ch ); 118 void removeChar( QIMPenChar *ch );
119 QIMPenChar *at( int i ); 119 QIMPenChar *at( int i );
120 void setHidden ( const bool &b ) { phidden = &b; } 120 void setHidden ( const bool &b ) { phidden = b; }
121 bool hidden() const { return phidden; } 121 bool hidden() const { return phidden; }
122 122
123 unsigned maximumStrokes() const { return maxStrokes; } 123 unsigned maximumStrokes() const { return maxStrokes; }
diff --git a/inputmethods/handwriting/qimpenprofile.cpp b/inputmethods/handwriting/qimpenprofile.cpp
index b1a6592..67343c3 100644
--- a/inputmethods/handwriting/qimpenprofile.cpp
+++ b/inputmethods/handwriting/qimpenprofile.cpp
@@ -142,6 +142,7 @@ void QIMPenProfile::loadData()
142 if ( !cs->isEmpty() ) { 142 if ( !cs->isEmpty() ) {
143 cs->setTitle( cs->title().upper() ); 143 cs->setTitle( cs->title().upper() );
144 cs->setType( QIMPenCharSet::Upper ); 144 cs->setType( QIMPenCharSet::Upper );
145 cs->setDescription( "Hidden uppercase" );
145 cs->setHidden ( true ); 146 cs->setHidden ( true );
146 QIMPenCharIterator it( cs->characters() ); 147 QIMPenCharIterator it( cs->characters() );
147 for ( ; it.current(); ++it ) { 148 for ( ; it.current(); ++it ) {
@@ -159,6 +160,8 @@ void QIMPenProfile::loadData()
159 cs = new QIMPenCharSet( baseDir + "qimpen/" + s ); 160 cs = new QIMPenCharSet( baseDir + "qimpen/" + s );
160 cs->load( Global::applicationFileName("qimpen",s), QIMPenCharSet::User ); 161 cs->load( Global::applicationFileName("qimpen",s), QIMPenCharSet::User );
161 if ( !cs->isEmpty() ) { 162 if ( !cs->isEmpty() ) {
163 if ( mono () )
164 cs->setDescription( "Latin Characters" );
162 if ( combining ) 165 if ( combining )
163 combining->addCombined( cs ); 166 combining->addCombined( cs );
164 sets.append( cs ); 167 sets.append( cs );
diff --git a/inputmethods/handwriting/qimpensetup.cpp b/inputmethods/handwriting/qimpensetup.cpp
index d1297a9..3f4841d 100644
--- a/inputmethods/handwriting/qimpensetup.cpp
+++ b/inputmethods/handwriting/qimpensetup.cpp
@@ -326,7 +326,7 @@ QIMPenEdit::QIMPenEdit( QIMPenProfile *p, QWidget *parent,
326 326
327 charSetCombo = new QComboBox( this ); 327 charSetCombo = new QComboBox( this );
328 gl->addMultiCellWidget( charSetCombo, 0, 0, 0, 1 ); 328 gl->addMultiCellWidget( charSetCombo, 0, 0, 0, 1 );
329 connect( charSetCombo, SIGNAL(activated(int)), SLOT(selectCharSet(int))); 329 connect( charSetCombo, SIGNAL(activated(int)), SLOT(selectCharSetVisible(int)));
330 QIMPenCharSetIterator it( profile->charSets() ); 330 QIMPenCharSetIterator it( profile->charSets() );
331 for ( ; it.current(); ++it ) { 331 for ( ; it.current(); ++it ) {
332 charSetCombo->insertItem( it.current()->description() ); 332 charSetCombo->insertItem( it.current()->description() );
@@ -388,7 +388,7 @@ QIMPenEdit::QIMPenEdit( QIMPenProfile *p, QWidget *parent,
388 connect( pb, SIGNAL(clicked()), SLOT(reject()) ); 388 connect( pb, SIGNAL(clicked()), SLOT(reject()) );
389 hb->addWidget( pb ); 389 hb->addWidget( pb );
390#endif 390#endif
391 selectCharSet( 0 ); 391 selectCharSetVisible( 0 );
392 charList->setFocus(); 392 charList->setFocus();
393 393
394 resize( minimumSize() ); 394 resize( minimumSize() );
@@ -404,7 +404,7 @@ void QIMPenEdit::setProfile( QIMPenProfile *p )
404 if ( ! it.current()->hidden() ) 404 if ( ! it.current()->hidden() )
405 charSetCombo->insertItem( it.current()->description() ); 405 charSetCombo->insertItem( it.current()->description() );
406 } 406 }
407 selectCharSet( 0 ); 407 selectCharSetVisible( 0 );
408 charList->setFocus(); 408 charList->setFocus();
409 enableButtons(); 409 enableButtons();
410} 410}
@@ -549,6 +549,17 @@ void QIMPenEdit::selectChar( int i )
549 inputChar->clear(); 549 inputChar->clear();
550} 550}
551 551
552void QIMPenEdit::selectCharSetVisible( int c )
553{
554 int i = 0;
555 QIMPenCharSetIterator it( profile->charSets() );
556 for ( ; it.current(); ++it, i++ ) {
557 if ( charSetCombo->text( c ) == it.current()->description() ) {
558 selectCharSet( i );
559 }
560 }
561}
562
552void QIMPenEdit::selectCharSet( int i ) 563void QIMPenEdit::selectCharSet( int i )
553{ 564{
554 if ( currentSet ) 565 if ( currentSet )
diff --git a/inputmethods/handwriting/qimpensetup.h b/inputmethods/handwriting/qimpensetup.h
index 5d3064b..93b981b 100644
--- a/inputmethods/handwriting/qimpensetup.h
+++ b/inputmethods/handwriting/qimpensetup.h
@@ -100,6 +100,7 @@ protected slots:
100 void clearChar(); 100 void clearChar();
101 void selectChar( int ); 101 void selectChar( int );
102 void selectCharSet( int ); 102 void selectCharSet( int );
103 void selectCharSetVisible( int );
103 void addChar(); 104 void addChar();
104 void addNewChar(); 105 void addNewChar();
105 void removeChar(); 106 void removeChar();