m_popupBackgroundColor( KitaConfig::defaultPopupBackgroundColor() ),
m_listFont( KitaConfig::defaultListFont() ),
m_threadFont( KitaConfig::defaultThreadFont() ),
+ m_popupFont( KitaConfig::defaultPopupFont() ),
// m_boardListURL
// m_nameCompletion
m_useStyleSheet( KitaConfig::defaultUseStyleSheet() ),
QColor m_popupBackgroundColor;
QFont m_listFont;
QFont m_threadFont;
+ QFont m_popupFont;
QString m_boardListURL;
KCompletion m_nameCompletion;
bool m_useStyleSheet;
static void setThreadFont( QFont font ) { getInstance() ->m_threadFont = font; }
static QFont defaultThreadFont() { return QFont(); }
+ static QFont& popupFont() { return getInstance() ->m_popupFont; }
+ static void setPopupFont( QFont font ) { getInstance() ->m_popupFont = font; }
+ static QFont defaultPopupFont() { return QFont(); }
+
static void setBoardListURL( QString url ) { getInstance() ->m_boardListURL = url; }
static QString& boardListURL() { return getInstance() ->m_boardListURL; }
static KCompletion* nameCompletion() { return & ( getInstance() ->m_nameCompletion ); }
connect( threadFontButton, SIGNAL( clicked() ),
SLOT( slotThreadFontButtonClicked() ) );
+ connect( popupFontButton, SIGNAL( clicked() ),
+ SLOT( slotPopupFontButtonClicked() ) );
+
Kita::SignalCollection* signalCollection = Kita::SignalCollection::getInstance();
connect( this, SIGNAL( setFontOfHTMLPart() ),
signalCollection, SIGNAL( setFontOfHTMLPart() ) );
}
m_threadFontchanged = FALSE;
+ QFont popupFont = popupFontButton->font();
+ KitaConfig::setPopupFont( popupFont );
+
// color
if ( m_threadColorChanged ) {
KitaConfig::setThreadColor( threadColorButton->color() );
threadFontButton->setFont( font );
m_threadFontchanged = TRUE;
+ font = KitaConfig::defaultPopupFont();
+ popupFontButton->setText( font.family() + " " + QString::number( font.pointSize() ) );
+ popupFontButton->setFont( font );
+
// color
threadColorButton->setColor( KitaConfig::defaultThreadColor() );
threadBackgroundColorButton->setColor( KitaConfig::defaultThreadBackgroundColor() );
QFont threadFont = KitaConfig::threadFont();
threadFontButton->setText( threadFont.family() + " " + QString::number( threadFont.pointSize() ) );
threadFontButton->setFont( threadFont );
+
+ QFont popupFont = KitaConfig::popupFont();
+ popupFontButton->setText( popupFont.family() + " " + QString::number( popupFont.pointSize() ) );
+ popupFontButton->setFont( popupFont );
}
void FacePrefPage::slotThreadFontButtonClicked()
}
}
+void FacePrefPage::slotPopupFontButtonClicked()
+{
+ QFont font = popupFontButton->font();
+
+ if ( KFontDialog::getFont( font, false, this ) == QDialog::Accepted ) {
+ popupFontButton->setText( font.family() + " " + QString::number( font.pointSize() ) );
+ popupFontButton->setFont( font );
+ emit changed();
+ }
+}
+
void FacePrefPage::slotColorChanged()
{
m_threadColorChanged = TRUE;