hoehrmann / CutyCapt

A Qt WebKit Web Page Rendering Capture Utility
http://cutycapt.sourceforge.net/
99 stars 49 forks source link

Font size radically different on Windows compared to running on Mac or Linux #14

Open hakanai opened 10 years ago

hakanai commented 10 years ago

If you make a simple HTML file with any font size (not just the default font size, from what I have seen), CutyCapt running on Mac OS X will generate output which looks more or less like what you would expect, but CutyCapt running on Windows will generate output with tiny text.

Side-by-side screenshot:

screen shot 2014-08-29 at 12 25 16 pm

I tried overriding this at the user stylesheet by setting font-size:10pt, which makes the font smaller. If I set font-size:18pt, the font comes out roughly the same size as the OSX result, but 18pt should be much bigger than that, so I think that the font-size being specified in points is being misinterpreted as some other unit.

hakanai commented 9 years ago

Now that I have set enough of the user agent stylesheet to be relatively confident that the same thing is being printed, the behaviour I have under Mac and under Linux (in this case, CentOS, but not sure if it matters) is the same.

Windows alone seems to print much smaller text. If you set your font size higher, the text becomes smaller, which is pretty ironic. (Also, if you set your font size lower, the text becomes larger.)

I thought maybe Qt was incorrectly setting that "zoom factor" thing based on the OS, but don't have the knowledge of Qt required to investigate.