Re: Printing in CVS HEAD.

From: Tomas Frydrych <tf_at_o-hand.com>
Date: Tue Oct 10 2006 - 11:09:29 CEST

Martin Sevior wrote:
> On Mon, 2006-10-09 at 10:54 +0100, Tomas Frydrych wrote:
>> msevior@physics.unimelb.edu.au wrote:
>>> Hi Tomas,
>>> Congrats on all your work to get printing going with the pango
>>> graphics class.
>>>
>>> It now basically works.
>>>
>>> However I'm seeing substantial non-WYSIWYG behaviour. A document of 3
>>> pages plus 2 lines on page 4 while on screen becomes 3 pages (less 2
>>> lines) in print preview.
>>>
>>> Do you have an idea what is happenning here? How do you plan to to fix it?
>> This is the problem I described in an earlier mail to the list; the
>> GnomePrint Pango backend obtains font metrics for hardcoded resolution
>> of 72dpi; Pango-xft backend uses whatever the X server is running with
>> (96dpi on my machine), and the font metrics obtained for the two
>> resolutions do not match. This is really a GnomePrint bug/API issue, and
>> should be addressed in GP, but that needs some GnomePrint knowledge
>> which I do not have. I have emailed Jody a while back, but had no reply
>> as yet.
>>
>
> I'm cross posting this to Jody directly the gnumeric list. Can we just
> grep through the gnome-print code, hunt down all the 72.0 assumptions
> and replace them with a definable resolution?

There are about 20 of these places, but none of these appear to deal
with text coords. I suspect it could be quite simple to fix for someone
who knows where to look. I will try to find some time to look more into
this at the w/e, unless someone beats me to it, of course.

> I can't see why we gnome-print needs 72.0 to be hard-coded. Maybe
> someone else can tell us?

The internal GP unit is 1/72 of an inch, so when font metrics is
acquired at 72dpi it can be used as is; I think that is the logic behind
it. It assumes that hinting can be turned off, which is not the case
when trying to reproduce screen output on a printer.

Tomas
Received on Tue Oct 10 11:10:18 2006

This archive was generated by hypermail 2.1.8 : Tue Oct 10 2006 - 11:10:18 CEST