After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 680659 - Does not apply the scaling factor consistently
Does not apply the scaling factor consistently
Status: RESOLVED NOTGNOME
Product: epiphany
Classification: Core
Component: General
3.4.x (obsolete)
Other Linux
: Normal normal
: ---
Assigned To: Epiphany Maintainers
Epiphany Maintainers
: 703337 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2012-07-26 15:04 UTC by Alexander E. Patrakov
Modified: 2015-06-24 21:41 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch that fixes the bug (5.33 KB, patch)
2013-08-06 15:26 UTC, Alexander E. Patrakov
none Details | Review
Patch that fixes the bug (5.42 KB, patch)
2014-07-27 12:24 UTC, Alexander E. Patrakov
none Details | Review

Description Alexander E. Patrakov 2012-07-26 15:04:17 UTC
To reproduce:

Run gnome-tweak-tool, set the text scaling factor to 1.4 (required on laptops with Retina-like display to get a usable font size).

Open Epiphany, go to google, search for lions.

Actual result: some fonts (e.g. those in main search results with font size specified in pt) are correctly scaled, some (in the sidebar, with font sizes specified in px) are not, and the images are not scaled at all.

Expected result: a web page with usable font sizes and consistent layout. E.g., you can scale everything (including images and fonts whose size is specified in px) by the text scaling factor. This is what Chromium does, except that it ignores the system-wide scaling factor completely and uses its own configurable scaling factor.
Comment 1 Alexander E. Patrakov 2012-07-26 15:07:41 UTC
In fact, you already can get the "expected" rendering in Epiphany if you set the text scaling factor to 1.0 using gnome-tweak-tool, search for lions and press Ctrl++ twice. But other applications on this laptop need the scaling factor of 1.4, so this is not a solution.
Comment 2 Alexander E. Patrakov 2013-08-06 15:26:04 UTC
Created attachment 250986 [details] [review]
Patch that fixes the bug

I am at GUADEC again, and I have a crude patch against this bug. The idea is to undo the DPI accounting via font size normalization and redo it using zoom levels. E.g., with 144 DPI, when Epiphany thinks it should have the 1.0 zoom factor, webkit's zoom is actually set to 1.5. A similar adjustment is performed when Epiphany wants to read the current zoom factor.

The patch works fine on my Sony laptop, but I think I have missed some (possibly unneeded) initialization. If I add debug output to track values passed to and returned from the virtual zoom functions, I see some requests that get the virtual zoom before setting it. Webkit returns 1.0, and this gets scaled down. No visible effects (?), though, as that zoom factor is immediately overridden.
Comment 3 Alexander E. Patrakov 2013-09-03 07:07:55 UTC
Dear developers, why are you still ignoring a bug with a patch that almost fixes it? The only unfixed case is the "this tab caused Epiphany to crash" message, and I need your help to figure out where to set the default zoom to catch this case.
Comment 4 Claudio Saavedra 2013-09-03 07:26:48 UTC
Because we're busy? Please don't rant in bugzilla.
Comment 5 Alexander E. Patrakov 2014-01-24 14:26:04 UTC
Could anyone please look at the patch and help me find a place in Epiphany source where I should add the initialization of the default zoom for error pages? The issue is unfixed for 2.5 years, and Epiphany is now the only application in GNOME that is incompatible with the "text scaling factor" accessibility option.
Comment 6 Alexander E. Patrakov 2014-01-24 14:28:15 UTC
Oops, 1.5 years.
Comment 7 Alexander E. Patrakov 2014-07-27 12:24:17 UTC
Created attachment 281812 [details] [review]
Patch that fixes the bug

Updated the patch to epiphany-3.12.1, but the same "incomplete" objection applies.
Comment 8 Alexander E. Patrakov 2014-07-27 13:17:30 UTC
The same issue applies to gnome-online-accounts when one neewd to enter their Google password. It would be really nice to have this fixed in one central location (Webkit) instead of duplicating this patch logic across all applications that embed Webkit.
Comment 9 Alexander E. Patrakov 2014-07-27 13:55:41 UTC
Based on the discussion with Owen Taylor, we have concluded that, with recent cairo, both get_screen_dpi() and gtk_widget_get_scale_factor() need to be taken into account. I have not tested the effect.
Comment 10 Michael Catanzaro 2015-02-26 20:45:02 UTC
*** Bug 703337 has been marked as a duplicate of this bug. ***
Comment 11 Michael Catanzaro 2015-06-24 21:41:27 UTC
I agree that this is a problem, but I don't want to take this patch because it's just a workaround. This needs to be fixed in WebKit so that other applications benefit too.