Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[HOWTO]New freetype subpixel font rendering for lcd monitors
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2, 3 ... 6, 7, 8 ... 28, 29, 30  Next  
This topic is locked: you cannot edit posts or make replies.    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
PaulBredbury
Watchman
Watchman


Joined: 14 Jul 2005
Posts: 7310

PostPosted: Wed Feb 28, 2007 8:51 am    Post subject: Reply with quote

Here's my ~/.fonts.conf, which displays bold well:
Code:
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
   <!-- Info at http://gentoo-wiki.com/HOWTO_Xorg_and_Fonts -->

   <!-- Replace Courier with a better-looking font -->
   <match target="pattern" name="family">
      <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 target="pattern" name="family">
      <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 -->
   <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>true</bool></edit>
      <edit name="hintstyle" mode="assign"><const>hintnone</const></edit>
   </match>

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

</fontconfig>
Back to top
View user's profile Send private message
anli
Tux's lil' helper
Tux's lil' helper


Joined: 08 Sep 2006
Posts: 80

PostPosted: Wed Feb 28, 2007 9:04 am    Post subject: Reply with quote

boniek wrote:
.. Some font families seem to not play well with newspr...

Can you list few fonts (mono and prop, unicoded) known to play well? :D
Thanks in advance!
Back to top
View user's profile Send private message
na641
Apprentice
Apprentice


Joined: 27 Jun 2002
Posts: 169
Location: Eugene, OR

PostPosted: Wed Feb 28, 2007 9:52 am    Post subject: Reply with quote

boniek wrote:
This is how it looks for me:

HandelGotD:
https://boniek.homelinux.org/~boniek/desktop/handelgotd_full.png
https://boniek.homelinux.org/~boniek/desktop/handelgotd_slight.png

They look equally bad to me :). Some font families seem to not play well with newspr. Looks like HandelGotD is one of them (another example would be DejaVu faimly).

Consolas:
https://boniek.homelinux.org/~boniek/desktop/full.png
https://boniek.homelinux.org/~boniek/desktop/slight.png
https://boniek.homelinux.org/~boniek/desktop/full_nobold.png
https://boniek.homelinux.org/~boniek/desktop/full_nobold_verasans.png

Personally I prefer full hinting, bitstream vera sans with bold disabled in terminal emulator ;) .
Bold fonts are Achilles' heel of freetype (they are just too bold). I don't know of any way to remedy this. Personally I just avoid bold fonts whenever I can.


Could you tell me what font you use for your window titles (in the console screenshots)?
Back to top
View user's profile Send private message
boniek
Guru
Guru


Joined: 26 Mar 2005
Posts: 373

PostPosted: Wed Feb 28, 2007 1:03 pm    Post subject: Reply with quote

na641 wrote:
Could you tell me what font you use for your window titles (in the console screenshots)?

It's good, old Sans Bold 8pt.
anli wrote:
Can you list few fonts (mono and prop, unicoded) known to play well? :D
Thanks in advance!

I didn't try a lot of fonts really. Just pick what looks best for you. Bitstream and Sans family are my personal favorites.
Look [here] for some samples.
PaulBredbury wrote:
Here's my ~/.fonts.conf, which displays bold well:
Code:
...

More of a workaround than a solution. It disables hinting (and newspr as well) for bold fonts. Do they look better? Thats highly subjective (as everything else here) ;)
_________________
[HOWTO]New freetype subpixel font rendering for lcd monitors
Back to top
View user's profile Send private message
m.s.w
Apprentice
Apprentice


Joined: 19 Sep 2004
Posts: 190
Location: Kraków, Poland

PostPosted: Wed Feb 28, 2007 7:36 pm    Post subject: Reply with quote

I have to ask: where did you get "Bitstream Vera Roman" and other types from?
I have installed ttf-bitstream-vera ebuild, but there is no such a font....


m.s.w
_________________
Mark Twain said it best:
"If you have to swallow a frog, don't stare at it too long!"
Back to top
View user's profile Send private message
boniek
Guru
Guru


Joined: 26 Mar 2005
Posts: 373

PostPosted: Wed Feb 28, 2007 7:49 pm    Post subject: Reply with quote

m.s.w wrote:
I have to ask: where did you get "Bitstream Vera Roman" and other types from?
I have installed ttf-bitstream-vera ebuild, but there is no such a font....


m.s.w

It's Bitstream Vera Sans Roman from media-fonts/ttf-bitstream-vera (with X useflag turned on).
_________________
[HOWTO]New freetype subpixel font rendering for lcd monitors
Back to top
View user's profile Send private message
vinboy
n00b
n00b


Joined: 18 Jun 2006
Posts: 69

PostPosted: Fri Mar 02, 2007 3:25 pm    Post subject: Reply with quote

great
Back to top
View user's profile Send private message
IvanMajhen
Guru
Guru


Joined: 10 Jun 2006
Posts: 392
Location: Croatia

PostPosted: Fri Mar 02, 2007 11:32 pm    Post subject: Reply with quote

Boniek, is your interface font color black, or did you changed it to some lighter black?
If my fonts are for example #343434 they look much better. I'm using corefonts. Bitstream fonts doesn't look right for me, specialy in web.
Back to top
View user's profile Send private message
na641
Apprentice
Apprentice


Joined: 27 Jun 2002
Posts: 169
Location: Eugene, OR

PostPosted: Sat Mar 03, 2007 6:50 pm    Post subject: Reply with quote

Hey Boniek, just thought you should know there is a new version of cairo in portage, version 1.3.16 which is greater than the 1.3.14 version in the overlay.
Back to top
View user's profile Send private message
devsk
Advocate
Advocate


Joined: 24 Oct 2003
Posts: 2995
Location: Bay Area, CA

PostPosted: Sat Mar 03, 2007 6:58 pm    Post subject: Reply with quote

one very basic question: is the overlay still required to enjoy the new font rendering on LCDs? Are there some patches in overlay which are not in freetype-2.3.1 and cairo-1.3.16 in portage, and which affect the look of fonts.
Back to top
View user's profile Send private message
roderick
l33t
l33t


Joined: 11 Jul 2005
Posts: 908
Location: St. John's, NL CANADA

PostPosted: Sun Mar 04, 2007 1:52 am    Post subject: Reply with quote

Was updated (by yours truly) about 7 hours ago :)

Re-sync your xeffects overlay to get the update to Cairo 1.3.16.

Cheers,

Rod.
_________________
If God were a pickle, I'd still say "no pickle on my burger".
http://roderick-greening.blogspot.com/
Back to top
View user's profile Send private message
boniek
Guru
Guru


Joined: 26 Mar 2005
Posts: 373

PostPosted: Sun Mar 04, 2007 2:00 am    Post subject: Reply with quote

na641 wrote:
Hey Boniek, just thought you should know there is a new version of cairo in portage, version 1.3.16 which is greater than the 1.3.14 version in the overlay.

It's at 1.3.16 thanks to roderick ;)
devsk wrote:
one very basic question: is the overlay still required to enjoy the new font rendering on LCDs? Are there some patches in overlay which are not in freetype-2.3.1 and cairo-1.3.16 in portage, and which affect the look of fonts.

You still need overlay for cairo and libXft as they need to be patched for all this to work.
IvanMajhen wrote:
Boniek, is your interface font color black, or did you changed it to some lighter black?
If my fonts are for example #343434 they look much better. I'm using corefonts. Bitstream fonts doesn't look right for me, specialy in web.

That's how fonts look under Gnome for me (freetype applies a bit of gamma correction thats why they are not pitch black - I like this effect very much).
_________________
[HOWTO]New freetype subpixel font rendering for lcd monitors
Back to top
View user's profile Send private message
na641
Apprentice
Apprentice


Joined: 27 Jun 2002
Posts: 169
Location: Eugene, OR

PostPosted: Sun Mar 04, 2007 2:40 am    Post subject: Reply with quote

roderick wrote:
Was updated (by yours truly) about 7 hours ago :)

Re-sync your xeffects overlay to get the update to Cairo 1.3.16.

Cheers,

Rod.


Thanks once again for the update.
Back to top
View user's profile Send private message
roderick
l33t
l33t


Joined: 11 Jul 2005
Posts: 908
Location: St. John's, NL CANADA

PostPosted: Sun Mar 04, 2007 4:13 am    Post subject: Reply with quote

na641 wrote:
Thanks once again for the update.


No problem.

I'm an update junkie, so I usually know when things need to be fixed pretty quickly.

-Rod
_________________
If God were a pickle, I'd still say "no pickle on my burger".
http://roderick-greening.blogspot.com/
Back to top
View user's profile Send private message
IvanMajhen
Guru
Guru


Joined: 10 Jun 2006
Posts: 392
Location: Croatia

PostPosted: Sun Mar 04, 2007 11:45 am    Post subject: Reply with quote

boniek wrote:

IvanMajhen wrote:
Boniek, is your interface font color black, or did you changed it to some lighter black?
If my fonts are for example #343434 they look much better. I'm using corefonts. Bitstream fonts doesn't look right for me, specialy in web.

That's how fonts look under Gnome for me (freetype applies a bit of gamma correction thats why they are not pitch black - I like this effect very much).

Hm... Don't understand. My fonts in yahoo look exactly like yours. But interface fonts are much blacker. If you didn't change interface color font, where this freetype gamma correction can be setup?
Back to top
View user's profile Send private message
boniek
Guru
Guru


Joined: 26 Mar 2005
Posts: 373

PostPosted: Sun Mar 04, 2007 6:16 pm    Post subject: Reply with quote

Which desktop environment are you using?
_________________
[HOWTO]New freetype subpixel font rendering for lcd monitors
Back to top
View user's profile Send private message
IvanMajhen
Guru
Guru


Joined: 10 Jun 2006
Posts: 392
Location: Croatia

PostPosted: Sun Mar 04, 2007 7:24 pm    Post subject: Reply with quote

I'm using KDE with QTcurve.
Here is screenshot how yahoo page looks: http://shrani.si/files/snapshot2uyzy.png.

It looks like yours, but yahoo looks good, because they don't use straight black fonts.
But for example, www.osnews.com fonts are very black: http://shrani.si/files/snapshot3uz25.png.
It would be nice if they looked like fonts in your ui.
Could you post screenshot of osnews.com, i wanna see if your fonts are black like mine, or do they look like from your ui.
I can get my ui to look like yours if i change font color (in gtk and qt apps with qtcurve).
But this doesn't apply to fonts colors in web. So if you are using that freetype gamma correction this should be
system wide, right? And where and how to change it?
Thanks
Back to top
View user's profile Send private message
boniek
Guru
Guru


Joined: 26 Mar 2005
Posts: 373

PostPosted: Mon Mar 05, 2007 3:05 pm    Post subject: Reply with quote

[Here].
Gamma correction is done by freetype - it should be system wide unless DE screws with your fonts in some way.
_________________
[HOWTO]New freetype subpixel font rendering for lcd monitors
Back to top
View user's profile Send private message
m.s.w
Apprentice
Apprentice


Joined: 19 Sep 2004
Posts: 190
Location: Kraków, Poland

PostPosted: Mon Mar 05, 2007 10:21 pm    Post subject: Reply with quote

Maybe it's OT, or irrelevant, but anyone knows how to make FF fully support nice fonts? For example here : http://www.regdeveloper.co.uk/2007/03/05/red_exadel/
I had no problems, util last update of cairo (previously I had cairo from xeffects, now regular from portage).

Regards,
m.s.w
_________________
Mark Twain said it best:
"If you have to swallow a frog, don't stare at it too long!"
Back to top
View user's profile Send private message
IvanMajhen
Guru
Guru


Joined: 10 Jun 2006
Posts: 392
Location: Croatia

PostPosted: Tue Mar 06, 2007 9:10 am    Post subject: Reply with quote

I think you have different font color in gnome. UI fonts are not black.
Problems with black (not bold, but black) font is that they are not smooth like other fonts.

I changed gamma in kde, by value when they become smooth.
They had some weird colors around it, and they look ok now.
Back to top
View user's profile Send private message
na641
Apprentice
Apprentice


Joined: 27 Jun 2002
Posts: 169
Location: Eugene, OR

PostPosted: Wed Mar 07, 2007 10:13 am    Post subject: Reply with quote

IvanMajhen wrote:
I think you have different font color in gnome. UI fonts are not black.
Problems with black (not bold, but black) font is that they are not smooth like other fonts.

I changed gamma in kde, by value when they become smooth.
They had some weird colors around it, and they look ok now.


Could you please post before and after shots to show the differences you speak of? Also, could you please give us your new optimal gamma settings? I think we would all appreciate this.

Oh well, I'm a gnome user anyway, so i'm not sure how simple it would be to change the gamma settings, if its possible at all through the gnome ui.
Back to top
View user's profile Send private message
johoe
Tux's lil' helper
Tux's lil' helper


Joined: 21 Jun 2005
Posts: 92

PostPosted: Wed Mar 07, 2007 10:50 am    Post subject: Reply with quote

I stumbled in this thread, cause I never was satisfied with the fonts on my gnome desktop. Especially freetype 2.3.1 made things even worse. So I tried your docs and I must say my fonts never looked so pretty. Many thanks for this great work!

The only thing I'm wondering is, that I really notice no difference when using "Grayscale" or "Subpixel" smoothing. So I am not using your "newspr" feature, when I set "Greyscale" smoothing - is this correct? Where are the differences, what should I use?

I am running gnome-desktop on gentoo. Setup is done as your docs suggest.

regards,
johoe
Back to top
View user's profile Send private message
boniek
Guru
Guru


Joined: 26 Mar 2005
Posts: 373

PostPosted: Wed Mar 07, 2007 4:35 pm    Post subject: Reply with quote

New subpixel rendering is used only when subpixel smoothing is selected.
[greyscale]
[subpixel]
There is subtle difference. Use what you like best.
_________________
[HOWTO]New freetype subpixel font rendering for lcd monitors
Back to top
View user's profile Send private message
IvanMajhen
Guru
Guru


Joined: 10 Jun 2006
Posts: 392
Location: Croatia

PostPosted: Thu Mar 08, 2007 10:47 am    Post subject: Reply with quote

na641 wrote:
IvanMajhen wrote:
I think you have different font color in gnome. UI fonts are not black.
Problems with black (not bold, but black) font is that they are not smooth like other fonts.

I changed gamma in kde, by value when they become smooth.
They had some weird colors around it, and they look ok now.


Could you please post before and after shots to show the differences you speak of? Also, could you please give us your new optimal gamma settings? I think we would all appreciate this.

Oh well, I'm a gnome user anyway, so i'm not sure how simple it would be to change the gamma settings, if its possible at all through the gnome ui.


Screenshot doesn't take changed gamma setting. My old screenshots are now looking good with changed gamma. This only changes monitor settings. With black fonts i had some red,green... pixels around them. They are smooth now. Gamma is 1.40. I think that this is problem with my lcd, since all movies now looks brighter (before i had to change brightness in kmplayer)
Back to top
View user's profile Send private message
boniek
Guru
Guru


Joined: 26 Mar 2005
Posts: 373

PostPosted: Fri Mar 09, 2007 4:56 pm    Post subject: Reply with quote

roderick wrote:
Ok,

Anyone here have ghostscript/cups support with media-fonts/gnu-gs-fonts-std installed?

I tried to rebuild my font cache (fc-cache) and this package causes fc-cache to hang and drive the CPU though the roof. I unmerged it and fc-cache worked fine.

The problem is it appears to be a dep of any of the ghostscript builds in portage.

If I leave it installed, I cannot run kdm as kdm_greet stalls (looks like it wants to rebuild the font cache at some point) and cpu goes to 100%.

Any ideas on why this particular font package is not liking fontconfig/freetype?

I had everything working fine until upgrade to new freetype/cairo/libxft, so I assume it's related...

Any help would be appreciated as this is driving me mad.

Seems that it is fixed in FreeType 2.3.2 (WFM at least).
_________________
[HOWTO]New freetype subpixel font rendering for lcd monitors
Back to top
View user's profile Send private message
Display posts from previous:   
This topic is locked: you cannot edit posts or make replies.    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Goto page Previous  1, 2, 3 ... 6, 7, 8 ... 28, 29, 30  Next
Page 7 of 30

 
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