[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdenetwork/ksirc/KSTicker
From: Andrew Stanley-Jones <asj () cban ! com>
Date: 2003-02-19 16:48:11
[Download RAW message or body]
CVS commit by asj:
This adds font saving back into the ticker, someone ripped it out.
M +9 -7 ksticker.cpp 1.38
--- kdenetwork/ksirc/KSTicker/ksticker.cpp #1.37:1.38
@@ -34,5 +34,6 @@ KSTicker::KSTicker(QWidget * parent, con
bAtEnd = FALSE;
- ourFont = QFont("Courier");
+ setFont(conf->readFontEntry("Font", &ksopts->defaultFont));
+ ourFont = font(); //QFont("Courier");
setFont(ourFont);
setMinimumSize(100, 10);
@@ -83,5 +84,4 @@ KSTicker::KSTicker(QWidget * parent, con
bg = ksopts->backgroundColor;
fg = ksopts->textColor;
- setFont(ksopts->defaultFont);
}
@@ -412,8 +412,5 @@ void KSTicker::fontSelector()
int result = KFontDialog::getFont( ourFont, true );
if ( result == KFontDialog::Accepted ) {
- setFont(ourFont);
- setFixedHeight((fontMetrics().height()+fontMetrics().descent()*2)*pHeight);
- resize(fontMetrics().width("X")*chars,
- (fontMetrics().height()+fontMetrics().descent())*pHeight);
+ updateFont(ourFont);
}
}
@@ -445,4 +442,9 @@ void KSTicker::updateFont(const QFont &f
resize(fontMetrics().width("X")*chars,
(fontMetrics().height()+fontMetrics().descent())*pHeight);
+ KConfig *conf = kapp->config();
+ conf->setGroup("KSTicker");
+ conf->writeEntry("Font", font);
+ conf->sync();
+
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic