[prev in list] [next in list] [prev in thread] [next in thread]
List: konsole-devel
Subject: [PATCH] using KGlobalSettings::fixedFont() (Was: [Konsole-devel] Fwd: Re: Line spacing in qt-copy)
From: Waldo Bastian <bastian () kde ! org>
Date: 2002-03-20 1:15:08
[Download RAW message or body]
See patch. Originally by Takumi ASAKI <asataku@osk3.3web.ne.jp>
On Tuesday 19 March 2002 01:59 pm, Waldo Bastian wrote:
> Coolness, now that the linespacing is fixed I would like to default the
> konsole font to KGlobalSettings::fixedFont() instead of "fixed".
>
> See http://lists.kde.org/?l=konsole-devel&m=101473418314459&w=2
>
> I'll send an up to date patch shortly.
>
> Cheers,
> Waldo
--
bastian@kde.org | SuSE Labs KDE Developer | bastian@suse.com
["konsole_font.patch" (text/x-diff)]
Index: konsole.cpp
===================================================================
RCS file: /home/kde/kdebase/konsole/konsole/konsole.cpp,v
retrieving revision 1.258
diff -u -p -r1.258 konsole.cpp
--- konsole.cpp 2002/03/19 16:43:18 1.258
+++ konsole.cpp 2002/03/20 01:14:05
@@ -95,6 +95,7 @@ Time to start a requirement list.
#include <klineeditdlg.h>
#include <kdebug.h>
#include <kipc.h>
+#include <kglobalsettings.h>
#include <dcopclient.h>
#include <klocale.h>
@@ -860,7 +861,7 @@ void Konsole::readProperties(KConfig* co
// Options that should be applied to all sessions /////////////
// (1) set menu items and Konsole members
- QFont tmpFont("fixed");
+ QFont tmpFont( KGlobalSettings::fixedFont() );
defaultFont = config->readFontEntry("defaultfont", &tmpFont);
setFont(QMIN(config->readUnsignedNumEntry("font",3),TOPFONT));
@@ -1081,7 +1082,7 @@ void Konsole::setFont(int fontno)
}
else
{
- f.setFamily("fixed");
+ f = KGlobalSettings::fixedFont();
f.setFixedPitch(true);
f.setPixelSize(QString(fonts[fontno]).toInt());
}
Index: konsole_part.cpp
===================================================================
RCS file: /home/kde/kdebase/konsole/konsole/konsole_part.cpp,v
retrieving revision 1.47
diff -u -p -r1.47 konsole_part.cpp
--- konsole_part.cpp 2002/03/19 17:19:55 1.47
+++ konsole_part.cpp 2002/03/20 01:14:06
@@ -449,7 +449,7 @@ void konsolePart::readProperties()
m_histSize = config->readNumEntry("history",DEFAULT_HISTORY_SIZE);
s_word_seps= config->readEntry("wordseps",":@-./_~");
- QFont tmpFont("fixed");
+ QFont tmpFont( KGlobalSettings::fixedFont() );
defaultFont = config->readFontEntry("defaultfont", &tmpFont);
setFont(QMIN(config->readUnsignedNumEntry("font",3),TOPFONT));
@@ -565,7 +565,7 @@ void konsolePart::setFont(int fontno)
if (fonts[fontno][0] == '-')
f.setRawName( fonts[fontno] );
else {
- f.setFamily("fixed");
+ f = KGlobalSettings::fixedFont();
f.setFixedPitch(true);
f.setPixelSize(QString(fonts[fontno]).toInt());
}
_______________________________________________
konsole-devel mailing list
konsole-devel@mail.kde.org
http://mail.kde.org/mailman/listinfo/konsole-devel
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic