Summary: | media-libs/freetype-2.3.4-r2 - wrong spacing with serif font | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Dylan <dshell> |
Component: | [OLD] Library | Assignee: | Gentoo Fonts Team <fonts> |
Status: | RESOLVED WORKSFORME | ||
Severity: | normal | ||
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
URL: | http://img517.imageshack.us/my.php?image=fontsmkv1.png | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- |
Description
Dylan
2007-09-16 18:25:35 UTC
Maybe if you posted freetype version and relevant config files, someone could help. Sorry but we cannot guess. Freetype version 2.3.4-r2, the config files follow (and are exactly as in the HOWTO with the BCI recommendations). Either BCI gives significantly better output, but has this tracking glitch. ------------------------------------------------------- /etc/fonts/local.conf reads: <?xml version="1.0"?> <!DOCTYPE fontconfig SYSTEM "fonts.dtd"> <!-- /etc/fonts/local.conf file to configure system font access --> <fontconfig> <!-- Enable sub-pixel rendering --> <!-- <match target="font"> <test qual="all" name="rgba"> <const>unknown</const> </test> <edit name="rgba" mode="assign"><const>rgb</const></edit> </match> --> <!-- Use the Autohinter --> <match target="font"> <edit name="autohint" mode="assign"><bool>false</bool></edit> </match> <!-- Disable Autohinting for bold fonts --> <match target="font"> <test name="weight" compare="more"> <const>medium</const> </test> <edit name="autohint" mode="assign"><bool>false</bool></edit> </match> <!-- Exclude/Include a range of fonts for Anti Aliasing --> <!-- <match target="font"> <test qual="any" name="size" compare="more"> <double>9</double> </test> <test qual="any" name="size" compare="less"> <double>14</double> </test> <edit name="antialias" mode="assign"> <bool>true</bool> </edit> </match> --> <!-- And/Or disable Anti Aliasing for a range on pixel-based size. Disabling this using both methods seems to fix Firefox. --> <!-- <match target="font"> <test compare="less" name="pixelsize" qual="any"> <double>20</double> </test> <edit mode="assign" name="antialias"> <bool>false</bool> </edit> </match> --> </fontconfig> ------------------------------------------------------- xorg.conf has: < cut > FontPath "/usr/share/fonts/misc:unscaled" FontPath "/usr/share/fonts/Type1" FontPath "/usr/share/fonts/TTF" FontPath "/usr/share/fonts/corefonts" FontPath "/usr/share/fonts/freefonts" FontPath "/usr/share/fonts/sharefonts" FontPath "/usr/share/fonts/terminus" FontPath "/usr/share/fonts/ttf-bitstream-vera" FontPath "/usr/share/fonts/unifont" FontPath "/usr/share/fonts/75dpi:unscaled" FontPath "/usr/share/fonts/100dpi:unscaled" FontPath "/usr/share/fonts/artwiz" < cut > Freetype version 2.3.4-r2, the config files follow (and are exactly as in the HOWTO with the BCI recommendations). Either BCI gives significantly better output, but has this tracking glitch. ------------------------------------------------------- /etc/fonts/local.conf reads: <?xml version="1.0"?> <!DOCTYPE fontconfig SYSTEM "fonts.dtd"> <!-- /etc/fonts/local.conf file to configure system font access --> <fontconfig> <!-- Enable sub-pixel rendering --> <!-- <match target="font"> <test qual="all" name="rgba"> <const>unknown</const> </test> <edit name="rgba" mode="assign"><const>rgb</const></edit> </match> --> <!-- Use the Autohinter --> <match target="font"> <edit name="autohint" mode="assign"><bool>false</bool></edit> </match> <!-- Disable Autohinting for bold fonts --> <match target="font"> <test name="weight" compare="more"> <const>medium</const> </test> <edit name="autohint" mode="assign"><bool>false</bool></edit> </match> <!-- Exclude/Include a range of fonts for Anti Aliasing --> <!-- <match target="font"> <test qual="any" name="size" compare="more"> <double>9</double> </test> <test qual="any" name="size" compare="less"> <double>14</double> </test> <edit name="antialias" mode="assign"> <bool>true</bool> </edit> </match> --> <!-- And/Or disable Anti Aliasing for a range on pixel-based size. Disabling this using both methods seems to fix Firefox. --> <!-- <match target="font"> <test compare="less" name="pixelsize" qual="any"> <double>20</double> </test> <edit mode="assign" name="antialias"> <bool>false</bool> </edit> </match> --> </fontconfig> ------------------------------------------------------- xorg.conf has: < cut > FontPath "/usr/share/fonts/misc:unscaled" FontPath "/usr/share/fonts/Type1" FontPath "/usr/share/fonts/TTF" FontPath "/usr/share/fonts/corefonts" FontPath "/usr/share/fonts/freefonts" FontPath "/usr/share/fonts/sharefonts" FontPath "/usr/share/fonts/terminus" FontPath "/usr/share/fonts/ttf-bitstream-vera" FontPath "/usr/share/fonts/unifont" FontPath "/usr/share/fonts/75dpi:unscaled" FontPath "/usr/share/fonts/100dpi:unscaled" FontPath "/usr/share/fonts/artwiz" < cut > (In reply to comment #3) > Freetype version 2.3.4-r2, the config files follow (and are exactly as in the > HOWTO with the BCI recommendations). Either BCI gives significantly better > output, but has this tracking glitch. Just as a reminder, that HOWTO is unofficial. And I don't agree with some of the stuff in it. ;) > ------------------------------------------------------- > /etc/fonts/local.conf reads: > > <?xml version="1.0"?> > <!DOCTYPE fontconfig SYSTEM "fonts.dtd"> > <!-- /etc/fonts/local.conf file to configure system font access --> > > <fontconfig> > > <!-- Enable sub-pixel rendering --> > > <!-- > <match target="font"> > <test qual="all" name="rgba"> > <const>unknown</const> > </test> > <edit name="rgba" mode="assign"><const>rgb</const></edit> > </match> > --> > I actually get better results turning off subpixel rendering, but this depends on the display. > > <!-- Use the Autohinter --> > > <match target="font"> > <edit name="autohint" mode="assign"><bool>false</bool></edit> > </match> This does the opposite of what the comment says. But if you build freetype with USE="-bindist", the autohinter isn't built anyways (which is generally a good thing). > > <!-- Disable Autohinting for bold fonts --> > > <match target="font"> > <test name="weight" compare="more"> > <const>medium</const> > </test> > <edit name="autohint" mode="assign"><bool>false</bool></edit> > </match> Redundant since you shut off the autohinter for all fonts above > > <!-- Exclude/Include a range of fonts for Anti Aliasing --> > > <!-- > > <match target="font"> > <test qual="any" name="size" compare="more"> > <double>9</double> > </test> > <test qual="any" name="size" compare="less"> > <double>14</double> > </test> > <edit name="antialias" mode="assign"> > <bool>true</bool> > </edit> > </match> > > --> > > > <!-- And/Or disable Anti Aliasing for a range on pixel-based size. > Disabling this using both methods seems to fix Firefox. --> > > <!-- > > <match target="font"> > <test compare="less" name="pixelsize" qual="any"> > <double>20</double> > </test> > <edit mode="assign" name="antialias"> > <bool>false</bool> > </edit> > </match> > > --> You have these commented out so they aren't doing anything. Maybe this was for testing? Anyways, try just something like <match target="font" > <edit mode="assign" name="antialias" > <bool>true</bool> </edit> </match> but i don't think this is where the problem lies. > </fontconfig> > ------------------------------------------------------- > > xorg.conf has: > > < cut > > > FontPath "/usr/share/fonts/misc:unscaled" > FontPath "/usr/share/fonts/Type1" > FontPath "/usr/share/fonts/TTF" > FontPath "/usr/share/fonts/corefonts" > FontPath "/usr/share/fonts/freefonts" > FontPath "/usr/share/fonts/sharefonts" > FontPath "/usr/share/fonts/terminus" > FontPath "/usr/share/fonts/ttf-bitstream-vera" > FontPath "/usr/share/fonts/unifont" > FontPath "/usr/share/fonts/75dpi:unscaled" > FontPath "/usr/share/fonts/100dpi:unscaled" > FontPath "/usr/share/fonts/artwiz" > > < cut > This won't affect firefox. Try turning on hinting with something like the following. I seem to remember running into this myself previously. <match target="font" > <edit mode="assign" name="hinting" > <bool>true</bool> </edit> </match> <match target="font" > <edit mode="assign" name="hintstyle" > <const>hintfull</const> </edit> </match> also, have you changed any of firefox's default font-related settings, in the dialog or about:config? i'm trying to reproduce this but i'm having some trouble. Firstly, thanks for looking at this. The reason I included the font.conf with all of the bits still commented out is that the first reply said I'd failed to include the config files. The point is that I used exactly the config files from the Gentoo HOWTO. Now, I've tried to make this a little easier for you to try reproduce. Maybe this will help, if I have the following local.conf (an essentially empty one) ============================================= <?xml version="1.0"?> <!DOCTYPE fontconfig SYSTEM "fonts.dtd"> <!-- /etc/fonts/local.conf file to configure system font access --> <fontconfig> </fontconfig> ============================================= Then the spacing issue goes away. It does change the mozilla firefox font however, so that even the title bar and dialog boxes have a taller/skinnier font. (Which is rather ugly.) The simplest local.conf to produce the weird spacing after the m's is: ============================================= <?xml version="1.0"?> <!DOCTYPE fontconfig SYSTEM "fonts.dtd"> <!-- /etc/fonts/local.conf file to configure system font access --> <fontconfig> <match target="font"> <edit name="autohint" mode="assign"><bool>false</bool></edit> </match> </fontconfig> ============================================= Should I attach an fc-list, or the fonts.conf, or the contents of the conf.d directory? I forgot to mention. This isn't just a firefox problem. I changed by fluxbox theme to use "serif" in the title bar. With the "blank" config there is no weird spacing, but the autohint=false config, there is the extra space with the m's. How can the font that mozilla/gtk apps use for menus change in height because autohint is explicitly turned off? hmm, i still can't seem to reproduce it. my unhelpful advice would be if disabling autohint gives you funky looking fonts, then don't disable it. :P (In reply to comment #8) > hmm, i still can't seem to reproduce it. my unhelpful advice would be if > disabling autohint gives you funky looking fonts, then don't disable it. :P > Indeed. Except there are funky looking fonts either way. One has these menu characters that are a good 2px larger than they should be, and the other is perfect but messes up the spacing after "m's". I don't understand how the font size can change with toggling autohint! |