Skip to content

X11 socket to fallback to x11#75

Open
thegreatGreenstar wants to merge 9 commits intoflathub:masterfrom
thegreatGreenstar:x11-to-fallback
Open

X11 socket to fallback to x11#75
thegreatGreenstar wants to merge 9 commits intoflathub:masterfrom
thegreatGreenstar:x11-to-fallback

Conversation

@thegreatGreenstar
Copy link
Copy Markdown

Currently Vesktop gains access to both Wayland and x11 at the same time, which should not be the case.
Our default behavior SHOULD be to use Wayland only by default then fallback to x11 if it's the only present session.

From my own testing I have found better compatibility with voice calls including screenshare in such using this method and we boost user security.

Furthermore, we become more compliant to what is recommended within Flatpak's own sandbox permissions: https://docs.flatpak.org/en/latest/sandbox-permissions.html#standard-permissions

Finally: We no longer have to deal with XWayland issues. A similar issue covers this with: godotengine/godot-proposals#11583 (comment)

As a side benefit, I believe this will improve how secure Vesktop appears against some Flathub application managers, as we can reduce the "uses a legacy windowing system" warning.

To account for our changed default permissions, Wayland sector must be tweaked. This accounts for applications moving over to Wayland by default.
@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Test build enqueued.

@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Started test build.

For us to avoid a cursed mixture of Wayland and XWayland.
@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Test build enqueued.

@flathubbot
Copy link
Copy Markdown
Contributor

Test build was cancelled.

Help
  • bot, build - Restart the test build
  • bot, ping admins - Contact Flathub admins

@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Started test build.

@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Test build enqueued.

@flathubbot
Copy link
Copy Markdown
Contributor

Test build was cancelled.

Help
  • bot, build - Restart the test build
  • bot, ping admins - Contact Flathub admins

@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Started test build.

@flathubbot
Copy link
Copy Markdown
Contributor

Test build succeeded. To test this build, install it from the testing repository:

flatpak install --user https://dl.flathub.org/build-repo/263008/dev.vencord.Vesktop.flatpakref

Built for aarch64 and x86_64 architectures.

@thegreatGreenstar
Copy link
Copy Markdown
Author

From a feature standpoint we also support VRR and HDR better which although not really super huge for VRR in this type of application IS a great benefit with HDR. This is because x11 and thus XWayland are incapable of HDR.

@thegreatGreenstar
Copy link
Copy Markdown
Author

We also avoid issues with the whole "allow system to scale applications" vs allowing applications to scale themself.
X11 applications are legacy, we are not.

@thegreatGreenstar

This comment was marked as off-topic.

@thegreatGreenstar

This comment was marked as off-topic.

@thegreatGreenstar
Copy link
Copy Markdown
Author

We also can match Electron behavior of default Wayland by doing this with fallback to X11
https://www.electronjs.org/blog/electron-38-0#removed-electron_ozone_platform_hint-environment-variable

I realized I got off topic in previous 2 comments so marked them as such, they should be created as a new issue upstream if such doesn't exist

@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Test build enqueued.

@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Started test build.

If anything is broken in testing against it it's these flags, but I believe there should be no issues. In a moment I'll try a a test against this and if input still works in login screen I'll mark reply to this indicating such.
@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Test build enqueued.

@flathubbot
Copy link
Copy Markdown
Contributor

Test build was cancelled.

Help
  • bot, build - Restart the test build
  • bot, ping admins - Contact Flathub admins

@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Started test build.

Regarding the "to use wayland instead"
@flathubbot
Copy link
Copy Markdown
Contributor

Test build succeeded. To test this build, install it from the testing repository:

flatpak install --user https://dl.flathub.org/build-repo/263017/dev.vencord.Vesktop.flatpakref

Built for aarch64 and x86_64 architectures.

@thegreatGreenstar
Copy link
Copy Markdown
Author

thegreatGreenstar commented Mar 8, 2026

Reply to #75 (comment)

Yep, testing this it works in full on my system. We should be able to merge this.

@thegreatGreenstar
Copy link
Copy Markdown
Author

@Vendicated Since you were the one to do stuff with Wayland and x11 initially, thought you might want to check this.
From my testing it works in full and any previous blockers and defaults of stuff like Electron have been fixed so we can switch over to Wayland default on Wayland sessions.

Now an if statement is used to be more accurate against the session and how application is running against it, if we're using native x11 it says so while if using X11 against Wayland via Xwayland it says so too.
@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Test build enqueued.

@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Started test build.

@flathubbot
Copy link
Copy Markdown
Contributor

Test build succeeded. To test this build, install it from the testing repository:

flatpak install --user https://dl.flathub.org/build-repo/265235/dev.vencord.Vesktop.flatpakref

Built for aarch64 and x86_64 architectures.

Just made em more accurate and surefire.  As in some cases we could have no socket granted if Wayland were we to only have x11-fallback.
@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Test build enqueued.

@flathubbot
Copy link
Copy Markdown
Contributor

🚧 Started test build.

@flathubbot
Copy link
Copy Markdown
Contributor

Test build succeeded. To test this build, install it from the testing repository:

flatpak install --user https://dl.flathub.org/build-repo/265240/dev.vencord.Vesktop.flatpakref

Built for aarch64 and x86_64 architectures.

@thegreatGreenstar
Copy link
Copy Markdown
Author

Relevant electron post: https://www.electronjs.org/blog/tech-talk-wayland

@thegreatGreenstar thegreatGreenstar mentioned this pull request Apr 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants