[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#289468: strace shows strange font XFLD



Hello,

I wrote:
> Which is something like
> -misc-fixed-medium-r-normal-*-13-120-75-75-c-120-iso10646-1
>
> (this avgWdth-120 variant is suited for Japanese display,
> while its avgWdth-70 or -80 variants would indeed make good default
> konsole fonts)

I know replying to oneself is considered impolite, but maybe this is
interesting: the venerable xterm uses
-Misc-Fixed-Medium-R-SemiCondensed--13-120-75-75-C-60-ISO8859-1

as its default font. So one could force konsole to specify SemiCondensed
 (with QFont::Stretch/QFont::SemiCondensed) or one could set the AvgWdth
 (don't know how/if Qt enables setting this).

Since I assume unconditionally setting SemiCondensed is not quite right
either, I'm waiting for someone else to do a patch.

You could also try this attached untested (!) patch against konsole.cpp in
kdebase source package (setting SemiCondensed everywhere). And report whether
it works for you.

-Malte
--- konsole.cpp.old	2005-01-19 21:19:24.000000000 +0100
+++ konsole.cpp	2005-01-19 21:21:52.000000000 +0100
@@ -1510,6 +1510,7 @@
       // (1) set menu items and Konsole members
       QFont tmpFont("fixed");
       tmpFont.setFixedPitch(true);
+      tmpFont.setStretch(QFont::SemiCondensed);
       tmpFont.setStyleHint(QFont::TypeWriter);
       defaultFont = config->readFontEntry("defaultfont", &tmpFont);
 
@@ -1764,6 +1765,7 @@
     QFont f;
     f.setRawName( fonts[fontno] );
     f.setFixedPitch(true);
+    f.setStretch(QFont::SemiCondensed);
     f.setStyleHint(QFont::TypeWriter);
     if ( !f.exactMatch() && fontno != DEFAULTFONT)
     {
@@ -1779,6 +1781,7 @@
     QFont f;
     f.setFamily("fixed");
     f.setFixedPitch(true);
+    f.setStretch(QFont::SemiCondensed);
     f.setStyleHint(QFont::TypeWriter);
     f.setPixelSize(QString(fonts[fontno]).toInt());
     te->setVTFont(f);

Reply to: