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

Support native Wayland with pgtk emacs #449

Closed
MatthewZMD opened this issue Nov 26, 2020 · 7 comments
Closed

Support native Wayland with pgtk emacs #449

MatthewZMD opened this issue Nov 26, 2020 · 7 comments
Labels
help wanted Extra attention is needed

Comments

@MatthewZMD
Copy link
Member

This is a continuation of the discussion from akirakyle/emacs-webkit#10 about EAF supporting native Wayland so it works with pgtk emacs.

Currently, EAF works with Wayland through XWayland, since EAF uses QWindow::setParent, which uses xcb in its source code, and does not work natively (using emacs --with-pgtk).

It is also reported that

I just realized another issue that EAF would need to overcome to work on wayland, but I can't think of any way it can be solved as it seems to go against wayland's design. EAF currently uses the x11 XID that Emacs reports in the window-id frame-parameter. AFAIK there is no equivalent to an XID on wayland as applications shouldn't really be able to identify and tell the compositor to affect another app's windows (yay security?!). Thus emacs --with-pgtk reports the pointer to the GtkWindow in window-id. I don't think there's anything useful Qt could do with this Gtk pointer.

@manateelazycat
Copy link
Member

Has add todo list, close issue.

@VitalyAnkh
Copy link

Are there any updates for this issue?
Why not make this a tracking issue for EAF wayland support? I'm yearning for the wayland support for I'm using pgtk emacs and stuck for this.

@manateelazycat
Copy link
Member

Are there any updates for this issue?
Why not make this a tracking issue for EAF wayland support? I'm yearning for the wayland support for I'm using pgtk emacs and stuck for this.

its in todolist, I don't think this issue can fix in short time

@manateelazycat
Copy link
Member

af392dc

I haven't used the pgtk version of Emacs. The above patch is a patch that I wrote blindly based on the EAF principle.

This patch means that when EAF finds that Emacs is in the Wayland native (also known as the pgtk version) environment, it will use the same strategy as macOS: "Show the EAF window when Emacs is focused, and hide the EAF window when Emacs loses focus. "Although it is not as perfect as multi-process reparent in X11 and XWayland environments, it should be no problem for daily use.

Welcome to try it, and welcome feedback.

@manateelazycat
Copy link
Member

EAF has support Wayland native 8df41d0

@MatthewZMD
Copy link
Member Author

Related #1019

@manateelazycat
Copy link
Member

Support by 29a5e56

If you are using Wayland environment, you need to execute the command cp -r emacs-application-framework/gnome-shell/eaf-wayland@emacs-eaf.org ~/.local/share/gnome-shell/extensions and activate the Gnome-Shell plugin eaf-wayland@emacs-eaf.org in Gnome3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants