Re: font size and point->pixel conversion

Hi Joaquin, if I multiply by 72./96. it actually works, but how do I retrieve the dpi for the more general case? (In a portable way)
Thank you!

Joaquin Cuenca Abela wrote:

Adrian wrote:
Hi! I am having a little problem with the font sizes. Before using pango (gtk-1, or GdkFont for that matter), I could match exactly the font size to the postscript font size, so if a font was 12pt on my pixmap, and 12pt on the ps file, they would look exactly the same.

Probably due to the different default dpi between X core fonts and
FontConfig. You should retrieve the dpi (now it's 96 by default) and use it
to convert from points to pixels.


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