Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Problematic font rendering
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
Paapaa
l33t
l33t


Joined: 14 Aug 2005
Posts: 955
Location: Finland

PostPosted: Tue Jun 05, 2007 8:33 pm    Post subject: Problematic font rendering Reply with quote

Please see this page:

http://www.codemonkey.org.uk/projects/cpufreq/

For some reason the capital N-letters are broken. The diagonal line looks too thick. This also applies to capital 'M' and 'A'. This doesn't happen in Windows XP. I have corefonts installed. Are you guys having the same problem?
Back to top
View user's profile Send private message
Ehnvis
Guru
Guru


Joined: 13 Jun 2006
Posts: 305
Location: /dev/random

PostPosted: Wed Jun 06, 2007 6:29 am    Post subject: Reply with quote

Yeah I've got the same problem. Had a look on their css file
Code:
body {
   font-family:"Trebuchet MS",Trebuchet,Verdana,arial,Sans-Serif;
   margin:0px 0px 20px 0px;
   background:#cab9b0;
}

And I think the problem has something to do with the Trebuchet font but I might be wrong.
_________________
HP NC 4010, Pentium-M 725 1.6GHz w/ 1Gb RAM, 60Gb Hitachi Travelstar.
Running Gentoo-2.6.21-r4 (again as 2.6.22 kernels hogs CPU), all but SD reader works fine.
Back to top
View user's profile Send private message
PaulBredbury
Watchman
Watchman


Joined: 14 Jul 2005
Posts: 7310

PostPosted: Wed Jun 06, 2007 8:15 am    Post subject: Reply with quote

Looks fine to me, using xeffects. Try viewing "Trebuchet MS" with fontpage.

I have:
Code:
# ll /usr/share/fonts/corefonts/trebuc*
-rw-r--r-- 1 root root 123828 2007-04-10 15:25 /usr/share/fonts/corefonts/trebucbd.ttf
-rw-r--r-- 1 root root 131188 2007-04-10 15:25 /usr/share/fonts/corefonts/trebucbi.ttf
-rw-r--r-- 1 root root 139288 2007-04-10 15:25 /usr/share/fonts/corefonts/trebucit.ttf
-rw-r--r-- 1 root root 126796 2007-04-10 15:25 /usr/share/fonts/corefonts/trebuc.ttf


However, the corefonts directory is not specified in my xorg.conf. These are used in preference (copied from a Windows XP installation):
Code:
# ll /usr/share/fonts/local/trebuc*
-rw-r--r-- 1 root root 123096 2007-04-29 23:35 /usr/share/fonts/local/trebucbd.ttf
-rw-r--r-- 1 root root 131188 2007-04-29 23:35 /usr/share/fonts/local/trebucbi.ttf
-rw-r--r-- 1 root root 139288 2007-04-29 23:35 /usr/share/fonts/local/trebucit.ttf
-rw-r--r-- 1 root root 134108 2007-04-29 23:35 /usr/share/fonts/local/trebuc.ttf
Back to top
View user's profile Send private message
Paapaa
l33t
l33t


Joined: 14 Aug 2005
Posts: 955
Location: Finland

PostPosted: Wed Jun 06, 2007 9:56 am    Post subject: Reply with quote

PaulBredbury wrote:
Looks fine to me, using xeffects. Try viewing "Trebuchet MS" with fontpage.

I have:
Code:
# ll /usr/share/fonts/corefonts/trebuc*
-rw-r--r-- 1 root root 123828 2007-04-10 15:25 /usr/share/fonts/corefonts/trebucbd.ttf
-rw-r--r-- 1 root root 131188 2007-04-10 15:25 /usr/share/fonts/corefonts/trebucbi.ttf
-rw-r--r-- 1 root root 139288 2007-04-10 15:25 /usr/share/fonts/corefonts/trebucit.ttf
-rw-r--r-- 1 root root 126796 2007-04-10 15:25 /usr/share/fonts/corefonts/trebuc.ttf


However, the corefonts directory is not specified in my xorg.conf. These are used in preference (copied from a Windows XP installation):
Code:
# ll /usr/share/fonts/local/trebuc*
-rw-r--r-- 1 root root 123096 2007-04-29 23:35 /usr/share/fonts/local/trebucbd.ttf
-rw-r--r-- 1 root root 131188 2007-04-29 23:35 /usr/share/fonts/local/trebucbi.ttf
-rw-r--r-- 1 root root 139288 2007-04-29 23:35 /usr/share/fonts/local/trebucit.ttf
-rw-r--r-- 1 root root 134108 2007-04-29 23:35 /usr/share/fonts/local/trebuc.ttf


Could you try without the fonts copied from your XP and with the former fonts (ie. corefonts specified in .conf and the other removed)? Just to make sure the fonts are the reason.
Back to top
View user's profile Send private message
PaulBredbury
Watchman
Watchman


Joined: 14 Jul 2005
Posts: 7310

PostPosted: Wed Jun 06, 2007 10:30 am    Post subject: Reply with quote

Yeah, the corefonts "Trebuchet MS" font still looks fine on that webpage and in fontpage. Try looking at it in fontpage.

My relevant versions:

media-libs/fontconfig-2.4.2 (from Portage)
x11-libs/libXft-2.1.12 (from xeffects overlay)
x11-libs/cairo-1.4.6 (from xeffects overlay)

BTW, there's no need to quote the entirety of what I just said - it just fills the page with duplicate text.
Back to top
View user's profile Send private message
Paapaa
l33t
l33t


Joined: 14 Aug 2005
Posts: 955
Location: Finland

PostPosted: Wed Jun 06, 2007 10:21 pm    Post subject: Reply with quote

PaulBredbury wrote:
Yeah, the corefonts "Trebuchet MS" font still looks fine on that webpage and in fontpage. Try looking at it in fontpage.


I did and the N's look bad. Do you have similar ~/.fonts.conf:

Code:
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
 <match target="font" >
  <edit mode="assign" name="rgba" >     <const>rgb</const> </edit>
  <edit mode="assign" name="hinting" >  <bool>true</bool>  </edit>
  <edit mode="assign" name="antialias"> <bool>true</bool> </edit>
  <edit mode="assign" name="autohint" > <bool>false</bool> </edit>
  <edit mode="assign" name="hintstyle"> <const>hintfull</const> </edit>
 </match>
</fontconfig>


I'm using same versions except I have Cairo 1.4.4. I also have Freetype 2.3.4-r2 with -bindist USE flag so I should be using the high quality renderer.

PaulBredbury wrote:
BTW, there's no need to quote the entirety of what I just said - it just fills the page with duplicate text.


I know, sorry for that, but I was in hurry and didn't bother to edit... :lol:
Back to top
View user's profile Send private message
PaulBredbury
Watchman
Watchman


Joined: 14 Jul 2005
Posts: 7310

PostPosted: Wed Jun 06, 2007 11:57 pm    Post subject: Reply with quote

My USE flags:
Code:
$ emerge -pv fontconfig libXft cairo
[ebuild   R   ] media-libs/fontconfig-2.4.2  USE="xml -doc" 0 kB
[ebuild   R   ] x11-libs/libXft-2.1.12  USE="newspr -debug" 0 kB [1]
[ebuild   R   ] x11-libs/cairo-1.4.6  USE="X glitz newspr svg -debug -directfb -doc -xcb"


My ~/.fonts.conf
Code:
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>

   <!-- Info:
   http://forums.gentoo.org/viewtopic-t-511382.html
   http://gentoo-wiki.com/HOWTO_Xorg_and_Fonts
   http://wiki.archlinux.org/index.php/XOrg_Font_Configuration
   -->

   <!-- Reject bitmap fonts in favour of Truetype, Postscript, etc. -->
   <selectfont>
      <rejectfont>
         <pattern>
            <patelt name="scalable">
               <bool>false</bool>
            </patelt>
         </pattern>
      </rejectfont>
   </selectfont>



   <!-- Replace Courier with a better-looking font -->
   <match name="family" target="pattern">
      <test name="family" qual="any">
         <string>Courier</string>
      </test>
      <edit name="family" mode="assign">
         <!-- Other choices - Andale Mono, Courier New, Luxi Mono, Bitstream Vera Sans Mono -->
         <string>Bitstream Vera Sans Mono</string>
      </edit>
   </match>

   <!-- Replace Courier New with a better-looking font -->
   <match name="family" target="pattern">
      <test name="family" qual="any">
         <string>Courier New</string>
      </test>
      <edit name="family" mode="assign">
         <!-- Other choices - Andale Mono, Courier New, Luxi Mono, Bitstream Vera Sans Mono -->
         <string>Bitstream Vera Sans Mono</string>
      </edit>
   </match>


   <!-- hintnone, hintslight, hintmedium, hintfull -->
   <!-- Keep autohint off -->
   <match target="font">
      <edit name="rgba" mode="assign"><const>rgb</const></edit>
      <edit name="autohint" mode="assign"><bool>false</bool></edit>
      <edit name="antialias" mode="assign"><bool>true</bool></edit>
      <edit name="hinting" mode="assign"><bool>true</bool></edit>
      <edit name="hintstyle" mode="assign"><const>hintslight</const></edit>
   </match>


   <!-- Disable hinting for bold fonts -->
   <match target="font">
      <test name="weight" compare="more"><const>medium</const></test>
      <edit name="autohint" mode="assign"><bool>false</bool></edit>
      <edit name="hinting" mode="assign"><bool>false</bool></edit>
   </match>

</fontconfig>
Back to top
View user's profile Send private message
sonicbhoc
Veteran
Veteran


Joined: 24 Oct 2005
Posts: 1805
Location: In front of the computer screen

PostPosted: Thu Jun 07, 2007 12:28 am    Post subject: Reply with quote

NICE!

But I changed hintstyle to hintfull. I like hintfull better. :wink:

Although hintslight makes it look more Vista-ish.

EDIT: Actually, the hintslight setting is rubbing off on me... But I think I'll be changing the font replacements to the Deja-Vu fontset, just to see how that turns out.

EDIT 2: Hintmedium and using DejaVu Fonts made my system look prettier than it's ever looked! Thank you so much for the fonts.conf!

By the way, when you have the fonts the way you like them, you can copy them to /etc/fonts/conf.avail/local.conf

I think putting them in /etc/fonts/conf.d/local.conf will have the same effect but I didn't try it.
_________________
I'm too lazy to keep this stupid signature up to date, so here's something more interesting:
My friend Hetdegon can draw if you ask me.
Now using PClinuxOS on my laptop and Gentoo on my desktop and new laptop.
Back to top
View user's profile Send private message
Paapaa
l33t
l33t


Joined: 14 Aug 2005
Posts: 955
Location: Finland

PostPosted: Thu Jun 07, 2007 12:07 pm    Post subject: Reply with quote

PaulBredbury wrote:
My USE flags:
[ebuild R ] x11-libs/libXft-2.1.12 USE="newspr -debug" 0 kB [1]
[ebuild R ] x11-libs/cairo-1.4.6 USE="X glitz newspr svg -debug -directfb -doc -xcb"[/code]


Hmm, what is the "newspr" USE flag? It is not present in my libXft-2.1.12 which is not from an overlay. Maybe that causes the differences? .fonts.conf didn't have any effect.

PS. IMO "hintslight" looks bad. At least on my system "hintfull" gives superior results.
Back to top
View user's profile Send private message
PaulBredbury
Watchman
Watchman


Joined: 14 Jul 2005
Posts: 7310

PostPosted: Thu Jun 07, 2007 12:13 pm    Post subject: Reply with quote

Go read the xeffects thread I linked to earlier - it explains.
Back to top
View user's profile Send private message
Paapaa
l33t
l33t


Joined: 14 Aug 2005
Posts: 955
Location: Finland

PostPosted: Thu Jun 07, 2007 12:17 pm    Post subject: Reply with quote

I wonder why the newspr is not in official ebuilds?
Back to top
View user's profile Send private message
Vlad.Sharp
Guru
Guru


Joined: 08 Dec 2004
Posts: 337
Location: Cambridgeshire, UK

PostPosted: Thu Jun 07, 2007 1:18 pm    Post subject: Reply with quote

The captial N, M and A look bolder than they should (when they are not html strong). I'm using xeffects, ~x86, newspr and XP fonts. Full RGB Hinting enabled, with 96x96 dpi. Haven't touched any font configuration files myself, just let KDE/Xfce do it.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum