Skip to content
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

Global Menu: Add option to force XWayland for Yad #869

Merged
merged 3 commits into from
Jul 28, 2023

Conversation

sonic2kk
Copy link
Owner

@sonic2kk sonic2kk commented Jul 28, 2023

Adds an option to the Global Menu which allows for forcing XWayland when using Yad, by exporting GDK_BACKEND=x11. This can be useful for compatibility in some instances, if XWayland is buggy, or if some Desktop Environment settings cause issues with Yad's Wayland support. One example is KDE Plasma's "Apply Scaling Themselves" option, which really breaks Yad's sizing functionality on multi-monitor displays with various different scale factors.

The export GDK_BACKEND may cause issues in future with some programs that rely on this, for example launching a native Linux custom program which actually has good Wayland support will force it to launch with the X11 backend. If this becomes an option we'll need to investigate some alternative, such as finding a way to only set this for Yad.

TODO:

  • Update langfiles

@sonic2kk
Copy link
Owner Author

In future it may be possible to fix any issues with the GDK variable export by not exporting it and just setting it. This raises a ShellCheck warning, SC2034, which if needs be we can always suppress if not exporting fixes it. I tested and not exporting still keeps the functionality of this PR, so it is a potential future solution!

For now, it works fine.

@sonic2kk
Copy link
Owner Author

Version bumped, langfiles updated, ShellCheck is green. Ready for merge!

@sonic2kk sonic2kk merged commit b1fc19a into master Jul 28, 2023
@sonic2kk sonic2kk deleted the yad-xwayland-globalconf branch July 28, 2023 20:34
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.

1 participant