atlas-engineer / nyxt

Nyxt - the hacker's browser.
https://nyxt-browser.com/
9.64k stars 404 forks source link

Render Dark/Transparent/Blurred Screen When Loading Instead of White Flash #3407

Open brosasaki opened 4 weeks ago

brosasaki commented 4 weeks ago

Purpose of request: To make browsing more comfortable and user-friendly, especially when browsing dark pages.

Describe your proposed change: When the browser re-renders the page, display a black or transparent frame instead of a white one. Even better, indicate the "re-rendering" status with a blurred display of the last rendered frame.

Why do you believe this to be an improvement? Currently, the screen flashes white whenever the user moves back to Nyxt from another app(maybe only on low-resource systems?), changes pages, or waits for a new buffer to render. This leads to an unpleasant “flashbang” effect, especially when browsing dark sites. A blur effect or even just a dark screen instead would be more pleasing. (as an aside, being able to render transparent and/or blurred UI elements would give nyxt a leg up against firefox, which is short in that regard).

Additional context/User story: I like my pages in dark mode, and whenever I browse around or switch tasks I get flashbanged :(

Screenshots/Mock ups: Close your eyes and concentrate a bit and I think you’ll see something pretty cool :)


Pre-Build Checklist:

aadcg commented 4 weeks ago

I'm not sure I understand the issue you're raising.

Currently, the screen flashes white whenever the user moves back to Nyxt from another app(maybe only on low-resource systems?)

Given this piece of information, isn't it caused by your desktop environment or window manager?

brosasaki commented 4 weeks ago

I don’t think so, because no other app does this. What I mean is specifically the “web view” part of the GUI is white while Nyxt does whatever it’s doing; the status/message bar remains as it is. The view also turns white when switching to a new buffer. I’m not entirely sure what causes it on a technical level, I am running it in a VM with 4GiB ram so maybe that has something to do with it?

aadcg commented 1 week ago

@brosasaki I see.

The "white flash" is managed by the renderer so a solution would have to be found within WebKitGTK.

P.S. - Out of curiosity, I tried to tweak it on Firefox and after trying several suggestions, the results weren't satisfactory.