[prev in list] [next in list] [prev in thread] [next in thread] 

List:       konq-bugs
Subject:    Bug#45782: TTF fonts not rendering correctly in KDE
From:       Vadim Plessky <lucy-ples () mtu-net ! ru>
Date:       2002-07-31 12:53:30
[Download RAW message or body]

On Wednesday 31 July 2002 4:13 am, Nathaniel Gray wrote:
> On Tuesday 30 July 2002 05:28 am, Vadim Plessky wrote:
> > On Friday 26 July 2002 11:10 pm, Nathaniel Gray wrote:
> > > It's an ugly font, but that's not the point.  The point is that it's
> > > rendering *differently* in KDE windows than non-KDE windows.  Compare
> > > the loops in the 'e' and the 'g'.  In KDE windows they've collapsed,
> > > but in the xfontsel and gfontsel windows they're fine.
> > 
> > it's ok, as KDE uses QT and Qt3 uses Xft for font selection and
> > anti-aliasing. GNOME1 doesn't have AA. Mozilla doesn't have AA, too
> > (excpet spcila builds for Xft2)
> > You get different results with different libraries.
> 
> I see.  I thought they all used the same library for rasterization.

They use *the same library* but with different library calls/parameters. :-)
In fact, you can render glyph using FT 2.0.9:
* AA-enabled/-disabled
* Hinting: enabled/disabled
* auto-hinting: enabled/disabled

Plus, you can enabled sub-pixel decimation (sub-pixel rendering) with help of Xft...
If you want to play with all those options: download ft2demos from www.freetype.org.
launch 'ftview', and invoke different rendering methods using keyboard.
Not very interactive, but works.


> 
> > > > Which version of FreeType do you have?
> > > > Check
> > > > #rpm -q freetype2
> > > 
> > > [n8gray@golux n8gray]$ rpm -q freetype2
> > > freetype2-2.0.4-1mdk
> > 
> > please upgrade to freetype2-2.0.9 (or newer, if available)!
> 
> That helped a lot.  I guess 2.0.4 wasn't working very well.

ok!
In fact, I have test separate install of LM 8.0 and FT-2.0.3, with Bytecode \
Interpreter enabled.  And it works fine (for TrueType fonts)!

BTW: FT 2.1.3 will be released in a few days, her eis extract from David Turner's \
                announce:
-------------------------------------------------------------------------
II. New release:

      I'd like to make a 2.1.3 release pretty quickly, since the current code
      contains noticeable improvements to both the Postscript and auto hinters :-)

      However, there are still a few things to fix to prevent nasty color fringes
      to appear with LCD-optimised text rendering under XFree86 4.2

      Another important point is the so-called "FT_Set_Hint_Mode" API. I've come
      to the conclusion that something like the following would be a good thing:

          typedef enum
          {
            FT_HINT_TARGET_MONO    = (1 << 0),  /* bit flags */
            FT_HINT_MODE_ANTIALIAS = (1 << 1),
            FT_HINT_MODE_OUTLINE   = (1 << 2)
          };
-------------------------------------------------------------------------
 
Complete mail canbe found at:
http://www.freetype.org/pipermail/devel/2002-July/003757.html

> 
> > > > Besides, I recommend you to turn AA On - as this will eliminate
> > > > terrible jagged edge effect presented on your s/s.
> > > 
> > > I tried AA and found that it made things look worse overall.
> > 
> > This basically means that you don't have scalable fonts installed
> > (TrueType, PostScript Type1)
> 
> Nope, the problem was the old version of freetype.  It rendered scalable
> fonts really badly and anti-aliasing just made it worse.  Anti-aliasing
> looks *tons* better now.

super!

> 
> I've still got a problem, though.  I can't figure out why some fonts are
> being anti-aliased and others aren't.  Arial gets AA even at small point
> sizes but Times New Roman is never AA.  Where do I configure these things? 
> I'm using the freetype module in X, by the way, instead of the default
> Mandrake setup with xfs.

/etc/X11/XftConfig

I attached my XftConfig to this mail, you can delete my custom dir "..." folders from \
the file, but take the rest  (I deleted some not-good font aliases from Mandrake's \
default XftConfig)

Also stay tuned to KDE mailing lists, may be I will annnounce some fonts soon ;-)

> 
> Thanks,
> -n8

-- 

Vadim Plessky
http://kde2.newmail.ru  (English)
33 Window Decorations and 6 Widget Styles for KDE
http://kde2.newmail.ru/kde_themes.html
KDE mini-Themes
http://kde2.newmail.ru/themes/


["XftConfig" (text/plain)]

#
# XftConfig
#
# Use with Type1 and TrueType fonts
# 
# sub-pixel anti-aliasing
match edit rgba=bgr;

# Note that each application scans all these directories
# during startup, so you may want to disable some to
# get better speed.

# Windows fonts - Vadim Plessky
dir "/usr/X11R6/lib/X11/fonts/WinFonts"
# Asian fonts from MS (gulimche, MingLiU, etc.)
# dir "/usr/X11R6/lib/X11/fonts/Asian"
# my (V.P.) PFB fonts
dir "/usr/X11R6/lib/X11/fonts/pfb"
# TTF fonts from Paragraph
dir "/usr/X11R6/lib/X11/fonts/parattf"
# fonts from Adobe Type Manager
dir "/usr/X11R6/lib/X11/fonts/ATM"
# miscelaneous TTF fonbts (Else Ware, Bitstream, etc.)
dir "/usr/X11R6/lib/X11/fonts/ttfmisc"
# Tilde AG
dir "/usr/X11R6/lib/X11/fonts/ttfmisc2"
#
# Standard XFree86 Type 1 fonts
dir "/usr/X11R6/lib/X11/fonts/Type1"
# TTF fonts
dir "/usr/X11R6/lib/X11/fonts/TrueType"
dir "/usr/X11R6/lib/X11/fonts/TTF"
# User installed fonts
dir "/usr/X11R6/lib/X11/fonts/drakfont"
dir "/opt/ttfonts"
# URW fonts
dir "/usr/share/fonts/default/Type1"
# Localized Truetype fonts
dir "/usr/share/fonts/ttf/western"
dir "/usr/share/fonts/ttf/big5"
dir "/usr/share/fonts/ttf/gb2312"
dir "/usr/share/fonts/ttf/japanese"
dir "/usr/share/fonts/ttf/korean"
dir "/usr/share/fonts/ttf/armenian"
# temporary disabled to unload extra names from KWord menu
# dir "/usr/share/fonts/ttf/decoratives"
dir "/usr/share/fonts/ttf/thai"
# don't yet exist, but i hope to include some day a package for them (Pablo)
dir "/usr/share/fonts/ttf/cyrillic"
dir "/usr/share/fonts/ttf/viet"
dir "/usr/share/fonts/ttf/ethiopic"
dir "/usr/share/fonts/ttf/georgian"
dir "/usr/share/fonts/ttf/arabic"
dir "/usr/share/fonts/ttf/hebrew"
dir "/usr/share/fonts/ttf/unicode"
# Sun JDK fonts
dir "/usr/java/jdk1.3/jre/lib/fonts"
# Sun OpenOffice, location depends on install
dir "/usr/openoffice60/share/fonts/type1"
dir "/usr/local/openoffice60/share/fonts/type1"
dir "~/openoffice60/share/fonts/type1"
# OpenOffice fonts from ttfonts*rpm
dir "/usr/share/fonts/default/TrueType"
# AbiSuite comes with URW fonts as well
dir "/usr/share/abisuite/AbiSuite/fonts"

#
# alias 'fixed' for 'mono'
#
match any family == "fixed"		edit family =+ "mono";

#
# Check users config file
#
includeif	"~/.xftconfig"

#
# Substitute TrueType fonts for Type1 versions
#
#match any family == "Times"		edit family =+ "Times New Roman";
#match any family == "Helvetica"		edit family =+ "Verdana";
#match any family == "Courier"		edit family =+ "Courier New";

#
# Use TrueType fonts for defaults
#
#match any family == "serif" 		edit family += "Times New Roman";
#match any family == "sans" 		edit family += "Arial";
#match any family == "sans" 		edit family += "Verdana";

#
# Use monotype.com (andale) face where possible
#
match 
	any family == "mono" 
	all slant == roman 
	all weight < bold
edit
	family += "monotype.com";
#
# otherwise, use courier
#
#match any family == "mono"		edit family += "Courier New";
#match any family == "mono"		edit family += "Courier";

#
# Alias between XLFD families and font file family name, prefer local fonts
#
#match any family == "Charter"		edit family += "Bitstream Charter";
#match any family == "Bitstream Charter" edit family =+ "Charter";

#match any family == "Lucidux Serif"	edit family += "LuciduxSerif";
#match any family == "LuciduxSerif"	edit family =+ "Lucidux Serif";

#match any family == "Lucidux Sans"	edit family += "LuciduxSans";
#match any family == "LuciduxSans"	edit family =+ "Lucidux Sans";

#match any family == "Lucidux Mono"	edit family += "LuciduxMono";
#match any family == "LuciduxMono"	edit family =+ "Lucidux Mono";
    
#
# TrueType font aliases
#
#match any family == "Comic Sans"	edit family += "Comic Sans MS";
#match any family == "Comic Sans MS"	edit family =+ "Comic Sans";
#match any family == "Trebuchet" 	edit family += "Trebuchet MS";
#match any family == "Trebuchet MS" 	edit family =+ "Trebuchet";
#match any family == "Monotype" 		edit family =+ "Monotype.com";
#match any family == "Andale Mono"	edit family += "Monotype.com";
#match any family == "Monotype.com"	edit family =+ "Andale Mono";

# modifications from Laurent Culioli
match
        any family == "webdings"
        edit antialias = false;
        encoding += "glyphs-fontspecific";
match
        any family == "wingdings"
        edit antialias = false;
        encoding += "glyphs-fontspecific";

# extra aliases -- pablo

# a nice default for sans serif (same as used in yudit)
#match any family == "sans"  	edit family =+ "Arial";
#match any family == "sans"  	edit family =+ "MS Gothic";
#match any family == "sans"  	edit family =+ "Gulim";
#match any family == "sans"  	edit family =+ "Baekmuk unigulir";
#match any family == "sans"  	edit family =+ "Lucida Sans Unicode";
#match any family == "sans"  	edit family =+ "Tahoma";
#match any family == "sans"  	edit family =+ "BPG UTF8 M";
#match any family == "sans"  	edit family =+ "GF Zemen Unicode";
#match any family == "sans"  	edit family =+ "MS Mincho";
#match any family == "sans"  	edit family =+ "Pigiarniq";
#match any family == "sans"  	edit family =+ "Urdu Naqsh Nastalique";
#match any family == "sans"  	edit family =+ "Ballymun RO";
# a nice monospaced one
match any family == "mono"		edit family =+ "Lucida Console";
# korean
match any family == "Gulim"  	edit family =+ "Baekmuk unigulir";
match any family == "Batang"  	edit family =+ "Ubatang";
match any family == "sans"  	edit family =+ "Gulim";
match any family == "serif"  	edit family =+ "Batang";
match any family == "mono"  	edit family =+ "Gulim";
# chinese gb2312
match any family == "Kaiti"  	edit family =+ "AR PL KaitiM GB";
match any family == "Sungti"  	edit family =+ "AR PL SungtiL GB";
match any family == "sans"  	edit family =+ "Sungti";
match any family == "serif"  	edit family =+ "Sungti";
# chinese big5
match any family == "Kaiti"  	edit family =+ "AR PL KaitiM Big5";
match any family == "Mingti"  	edit family =+ "AR PL Mingti2L Big5";
match any family == "sans"  	edit family =+ "Mingti";
match any family == "serif"  	edit family =+ "Mingti";
# thai
match any family == "sans"  	edit family =+ "Norasi";
match any family == "serif"  	edit family =+ "Norasi";
# armenian
match any family == "Helvetica" edit family =+ "ArmNet Helvetica";
match any family == "sans"  	edit family =+ "ArmNet Helvetica";
match any family == "serif"  	edit family =+ "ArmNet Helvetica";
# indic
match any family == "Raghindi" 	edit family =+ "Raghu";
match any family == "sans"  	edit family =+ "Raghindi";
match any family == "serif"  	edit family =+ "Raghindi";

#
# If the Microsoft Web Fonts are not installed, we have to find a 
# replacement
#

# these come with Sun JDK 1.3
#match any family == "Verdana"		edit family =+ "Lucida Sans";
#match any family == "Times New Roman"	edit family =+ "Lucida Bright";
#match any family == "Courier New"	edit family =+ "Lucida Sans Typewriter";

# OpenOffice 6
#match any family == "Verdana"		edit family =+ "Lucida Sans Tur";
#match any family == "Times New Roman"	edit family =+ "Lucida Bright Tur";
#match any family == "Courier New"	edit family =+ "Lucida Sans Typewriter Tur";

# ttfonts from RH7
#match any family == "Verdana"		edit family =+ "Helmet";

# URW fonts 
#match any family == "Verdana"		edit family =+ "Nimbus Sans L";
#match any family == "Times New Roman"	edit family =+ "Nimbus Roman No9 L";
#match any family == "Courier New"	edit family =+ "Nimbus Mono L";

# western fonts
#match any family == "Verdana"		edit family =+ "Blue Highway";

# XFree86 default fonts
#match any family == "Verdana"   	edit family =+ "LuciduxSans";
#match any family == "Times New Roman"  	edit family =+ "LuciduxSerif";


# last ressort defaults
#match any family == "Courier"		edit family =+ "mono";

#match any family == "Helvetica"  	edit family =+ "sans";
#match any family == "Arial"  	edit family =+ "sans";

#match any family == "serif"  	edit family =+ "sans";
#match any family == "Times"  	edit family =+ "serif";


(Complete bug history is available at http://bugs.kde.org/db/45/45782.html)
_______________________________________________
Konq-bugs mailing list
Konq-bugs@mail.kde.org
http://mail.kde.org/mailman/listinfo/konq-bugs

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic