Ladybird: Implement a GTK 4 chrome :^)
This is an alternative to https://github.com/SerenityOS/serenity/pull/22260
Import Sergey's ladybird-gtk4 repository as one commit.
There are two notable omissions from the master branch of ladybird-gtk4:
- JS console. The infrastructure in LibWebView that the JS console native widget was removed in the last month. This widget sadly has to be redesigned.
- Translations. At a later date they can be imported. However, they are a bit controversial among the current Serenity maintainers, so let's leave them out for the initial PR.
As it's a bit difficult to get an up to date GTK4 developer environment setup on stock Ubuntu LTS, there are two Flatpak-based solutions described in the GTK/README.md: flatpak-builder (command line tool) and GNOME Builder (IDE).
Time for some screenies!
GNOME Builder:
Using the Flatpak:
Adwaita tab overview:
Zoom:
Importing upstream as one commit seems alright, but maybe changes from upstream should be in separate commits?
Importing upstream as one commit seems alright, but maybe changes from upstream should be in separate commits?
That's a good point. I'll re-apply my changes from upstream on top of a squash-merged version of #22260 with the addition of the license headers. That way that commit will pass CI. Then the transformation from upstream (downstream?) will be like so:
- Filter-branch (move to Ladybird/GTK) + clang-format + add license headers
- Remove files we do not intend to merge into SerenityOS/serenity at this time (translation folder, JS Console class, LibSoup integration, custom WebContent main.cpp)
- Integrate with Ladybird CMake build + clean up files so that serenity-enabled warnings go away.
Depending on the mess created, I might squash 2. and 3. together :shrug:
I'll close this for now, perhaps there is a path to a GTK chrome some time in the future.