-
-
Notifications
You must be signed in to change notification settings - Fork 880
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Blank page in foliate book reader on monitor scales above 1 on Hyprland 0.41.2 and 0.42.0; works fine on all scales in Sway #7341
Comments
|
There was an update in 'egl-wayland' 1.16 which fixed a QT6 Webengine bug |
Status:On 1822707 aquamarine 0.4.2_r222.g65dd97b-1, foliate 3.1.1-1, gtk4 1:4.16.3-1 (with GSK_RENDERER=ngl), webkitgtk-6.0 2.46.1-4, nvidia 560.35.03-6, egl-wayland 4:1.1.16-1, mesa 1:24.2.4-1 The behavior is the same - scale 1 works fine, same GBM error on scales above 1 and empty window. (weird scaling of nested sway in hyprland was caused by #7499) |
Tried to hunt it down, in vm, using 1 Jun 2024 box. "Broken" here means scales above 1 reproduce the issue (blank page). 0.40.0 is broken - hyprwayland-scanner first introduced I think, it's safe to say, it never worked properly with scales above 1. I also tested older versions of sway and wlroots: sway 1.9 wlroots 0.17.1 works Another note: Foliate 2.6.4 that uses gtk3 3.24.41 and webkit2gtk 2.42.5 works on any scale, but works like a slideshow on large books, so I assume it has some fallback to software render internally that just didn't get ported to gtk4. I didn't investigate it further, as the performance is unusable anyway, and gpu render clearly can work (sway) on gtk4 too without any performance issues. |
Possibly related to the order of the app getting the I can make epiphany (and other gtk4 apps) work on gtk 4.16.1 without On scales above 1 it works only with On scale 1 it starts to work with On plasma-desktop 6.1.5 scale 1.25 (in qemu, virtio) on gtk 4.16.1 without |
maybe this is a bug in whatever toolkit it uses then? hyprland's fsv1 impl is correct and within the spec. |
Hard to tell. But here is WAYLAND_DEBUG=1 foliate 3.1.1 (gtk 4.16.1) from different wayland compositors with different backends.
Here, only hyprland at scale 1.25 has this issue. You might be right, and it's perfectly within spec, and it's just the case of people looking at popular implementations and copying, and, as the result, them becoming de facto spec the apps and toolkits are tested against. It might be something else is wrong, and scales above 1 just trigger the logic that ultimately leads to some other buggy code, with the scaling doing its part correctly. Idk. Looking at the logs, what jumps out to me (as someone who doesn't know anything about how wayland compositor should be designed), is that plasma, mutter, sway and niri have something like this (scale 1.25)
(scale 1)
And one time each. While hyprland has it 3 times (scale 1)
(scale 1.25)
with preferred_buffer_scale somewhere way after. Also, notice that it first starts with 120. This seems weird, but I don't know how much it matters. |
yeah we do this and it shouldnt matter |
Regression?
No
System Info and Version
System/Version info
Description
Foliate (installed from arch repos) is a book reader that uses
webkitgtk-6.0
to render text.Horrifying, I know. But it's the only one that didn't lag in large books, didn't look like ass, didn't randomly disrespect formatting, didn't try run my library by importing my books to some location without me asking it to do so, had actual GUI and not a meme-tier latin-only hotkeys, etc.On scale 1 it works fine, without errors.
On anything above one you'll get this:
And a blank white page instead of your book.
I can observe this behavior on both wlroots (0.41.2) and aquamarine (hyprland 3b4aabe, aquamarine 9312aa2).
Happens regardless if nvidia specific environment variables are set.
Now, if you look at foliate repo, there are issues about blank pages. johnfactotum/foliate#1107, johnfactotum/foliate#1115, johnfactotum/foliate#1271, with some advice (bad if you don't like slideshow scroll) how to "fix" it -
WEBKIT_DISABLE_DMABUF_RENDERER=1
So why make issue here?
Well, because it works on sway 1.9 with wlroots0.17 from arch repos on all scales.
I don't use nix, so because of the need for outdated dependencies I can't easily check when it started happening or if scales above 1 were always broken.I certainly didn't use 1.25 I use now from the beginning of the fractional scaling support, so my comment on one of those issues might just be flatpak disrespecting scaling and working solely for that reason.Even on sway+wlroots from 3 years ago it works fine on all scales, hyprland has this issue as early as 0.23beta, and probably always had. #7341 (comment)
Other WebKitGTK-6.0 apps
epiphany
(gnome web) has the same error on scales above 1, but manages to render the page properly. Might be some internal fallback that's just absent in foliate, idk.newsflash
also works on scales above 1, but the whole interface is slightly blurry, which is strange, it's not xwayland. No GBM error.gfeeds
works, interface as normal. No GBM error.setzer
seems to work, but with interface slightly blurry like newsflash. No GBM error.Again, I don't know if they just have some internal fallback - the performance is not horrible. But that's just simple webpages, not a million words long books.
But what curious is why sway works. Sway or wlroots, that don't support (proprietary) nvidia, so any nvidia specific fallback on their side is unlikely.
How to reproduce
Install
foliate
from arch repos (no flatpak/snap sandbox to interfere with anything) and use any.epub
book.Hyprland:
monitor = ,preferred,auto,1.25
, (same for the scale 2)foliate book.epub
and observe the blank page and an error mentioned abovemonitor = ,preferred,auto,1
foliate book.epub
again and observe properly rendered book pageSway:
If needed, copy default config to user config directory, since we will be editing it.
output
statement withoutput * scale 1
, press Super+Shift+C to reload configfoliate book.epub
- page is displayed properly1.25
, press Super+Shift+C to reload configfoliate book.epub
- page is still displayed properly2
, press Super+Shift+C to reload configfoliate book.epub
- page is still displayed properlyCrash reports, logs, images, videos
Screenshots
On 3b4aabe
epiphany-scale-1.25
epiphany-scale-1
foliate-scale-1
foliate-scale-1.25
foliate-scale-2
0.41.2
foliate-scale-1
foliate-scale-2
sway 1.9 + wlroots 0.17
epiphany-aka-gnome-web-scale-1
foliate-scale-1
foliate-scale-1.25
foliate-scale-2
The text was updated successfully, but these errors were encountered: