OSDN Git Service

refactoring...
authorikemo <ikemo@56b19765-1e22-0410-a548-a0f45d66c51a>
Tue, 3 Jun 2003 15:18:43 +0000 (15:18 +0000)
committerikemo <ikemo@56b19765-1e22-0410-a548-a0f45d66c51a>
Tue, 3 Jun 2003 15:18:43 +0000 (15:18 +0000)
git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/kita/kita/trunk@318 56b19765-1e22-0410-a548-a0f45d66c51a

kita/src/kita.cpp
kita/src/pref.cpp
kita/src/pref.h

index fa7dc9a..587aa6d 100644 (file)
@@ -325,7 +325,8 @@ void KitaMainWindow::optionsPreferences()
   // popup some sort of preference dialog, here
   KitaPreferences dlg;
 
-  connect(&dlg, SIGNAL(signalFontChanged(QFont&)), SLOT(setFont(QFont&)));
+  connect(&dlg, SIGNAL( fontChanged( const QFont& ) ),
+                SLOT( setFont( const QFont& ) ) );
   if (dlg.exec()) {
     // redo your settings
   }
index c946a78..6a34b0f 100644 (file)
@@ -34,10 +34,11 @@ KitaPreferences::KitaPreferences()
 //    frame = addPage(i18n("Second Page"), i18n("Page Two Options"));
 //    m_pageTwo = new KitaPrefPageTwo(frame);
 
-    connect(m_fontPage, SIGNAL(signalFontChanged(QFont&)), SIGNAL(signalFontChanged(QFont&)));
+    connect( m_fontPage, SIGNAL( fontChanged( const QFont& ) ),
+                         SIGNAL( fontChanged( const QFont& ) ) );
 }
 
-KitaFontPrefPage::KitaFontPrefPage(QWidget *parent)
+KitaFontPrefPage::KitaFontPrefPage( QWidget *parent )
     : KitaFontPrefBase(parent)
 {
   fontButton->setText(KitaConfig::font().family());
@@ -52,11 +53,11 @@ void KitaFontPrefPage::slotFontButtonClicked()
   if( KFontDialog::getFont(font, false, this) == QDialog::Accepted ) {
     fontButton->setText(font.family());
     fontButton->setFont(font);
-    emit signalFontChanged(font);
+    emit fontChanged(font);
   }
 }
 
-KitaPrefPageTwo::KitaPrefPageTwo(QWidget *parent)
+KitaPrefPageTwo::KitaPrefPageTwo( QWidget *parent )
     : QFrame(parent)
 {
     QHBoxLayout *layout = new QHBoxLayout(this);
index 01de747..202d6c6 100644 (file)
@@ -22,32 +22,38 @@ class KitaPrefPageTwo;
 class KitaPreferences : public KDialogBase
 {
     Q_OBJECT
+
 public:
     KitaPreferences();
 
 private:
     KitaFontPrefPage *m_fontPage;
     KitaPrefPageTwo *m_pageTwo;
+
 signals:
-  void signalFontChanged(QFont&);
+  void fontChanged( const QFont& );
 };
 
 class KitaFontPrefPage : public KitaFontPrefBase
 {
     Q_OBJECT
+
 public:
-    KitaFontPrefPage(QWidget *parent = 0);
+    KitaFontPrefPage( QWidget *parent = 0 );
+
 public slots:
   void slotFontButtonClicked();
+
 signals:
-  void signalFontChanged(QFont&);
+  void fontChanged( const QFont& );
 };
 
 class KitaPrefPageTwo : public QFrame
 {
     Q_OBJECT
+
 public:
-    KitaPrefPageTwo(QWidget *parent = 0);
+    KitaPrefPageTwo( QWidget *parent = 0 );
 };
 
 #endif // _KITAPREF_H_