-rw-r--r-- | inputmethods/handwriting/qimpensetup.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/inputmethods/handwriting/qimpensetup.cpp b/inputmethods/handwriting/qimpensetup.cpp index 10c136d..2441102 100644 --- a/inputmethods/handwriting/qimpensetup.cpp +++ b/inputmethods/handwriting/qimpensetup.cpp @@ -94,5 +94,6 @@ QIMPenSetup::QIMPenSetup( QIMPenProfile *p, QWidget *parent, QVBoxLayout *vb = new QVBoxLayout( this ); -#if 0 +#define MULTIPROFILE +#ifdef MULTIPROFILE profileList.setAutoDelete( true ); QHBoxLayout *hb = new QHBoxLayout( vb ); @@ -104,8 +105,9 @@ QIMPenSetup::QIMPenSetup( QIMPenProfile *p, QWidget *parent, this, SLOT(selectProfile(const QString &)) ); hb->addWidget( profileCombo ); - loadProfiles(); #else profileList.append( profile ); #endif + + qWarning("profiles: %d", profileList.count()); QTabWidget *tw = new QTabWidget( this ); @@ -131,4 +133,8 @@ QIMPenSetup::QIMPenSetup( QIMPenProfile *p, QWidget *parent, edit = new QIMPenEdit( p, tw ); tw->addTab( edit, tr("Customize") ); +#ifdef MULTIPROFILE + loadProfiles(); +#endif + } @@ -146,4 +152,5 @@ void QIMPenSetup::loadProfiles() profileCombo->setCurrentItem( profileCombo->count()-1 ); profile = p; + edit->setProfile( profile ); } } @@ -564,4 +571,5 @@ void QIMPenEdit::addChar() // User characters override all matching system characters. // Copy and mark deleted identical system characters. + QIMPenCharIterator it(currentSet->characters() ); QIMPenChar *sc = 0; |