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

Linux: Pasting into other apps is slow #493

Open
LeonardoTemperanza opened this issue Dec 31, 2024 · 5 comments
Open

Linux: Pasting into other apps is slow #493

LeonardoTemperanza opened this issue Dec 31, 2024 · 5 comments

Comments

@LeonardoTemperanza
Copy link

Description
After copying text from Focus, the act of pasting into some other apps seems much slower than normal, while copying from other sources result in proper pasting behavior. Out of the apps I've tried only Google Chrome seems to exhibit such behavior, but I assume there might be others. I'm not sure if this is a bug in Chrome, but copying from other apps works fine so I thought this bug report might turn out useful.

To Reproduce

  1. Open Focus Editor
  2. Copy some text from inside the editor. Any amount of text will cause the same slowdown.
  3. Paste into any textbox in Google Chrome.
  4. Google Chrome will freeze for some time and a " 'Google Chrome' is not Responding " box will appear. On the other hand, copying from other sources and pasting into Chrome works fine.

Expected behavior
Pasting is as fast as it is after copying from any other source.

Context

  • OS: Ubuntu 24.10 (X11)
  • Focus Version: 0.3.7
  • Chrome version: Version 131.0.6778.204
@ileonte
Copy link
Collaborator

ileonte commented Jan 2, 2025

Can you please run the "Show Troubleshooting Information" command in Focus and paste/attach the results here?

@LeonardoTemperanza
Copy link
Author

Here it is:
troubleshoot_info.txt

@ileonte
Copy link
Collaborator

ileonte commented Jan 2, 2025

I notice that you are running a Wayland desktop (not X11), it's just that Focus is choosing to run as an X11 app for the "best user experience" (in this case for the sake of having window decorations since GNOME doesn't have support for Wayland server-side decorations). With this in mind can you please:

  1. check whether Chrome is running as a native Wayland app or is also using XWayland - go to about:gpu in Chrome, search for Ozone platform and please report the value here, it will help me in reproducing the issue
  2. check if running Focus with FOCUS_LD_BACKEND=x11 set in the environment shows the same issue - run FOCUS_LD_BACKEND=x11 /path/to/focus-linux in a terminal and repeat the copy-paste test
  3. check if running Focus as a native Wayland app has the same issue - run FOCUS_LD_BACKEND=wayland /path/to/focus-linux in a terminal and repeat the copy-paste test (note that running like this will cause the Focus window to have no title bar/resize margins; this is expected and can be ignored for this test)

@LeonardoTemperanza
Copy link
Author

LeonardoTemperanza commented Jan 2, 2025

Ah yes, my bad.

  1. The value of "Ozone platform" is "x11"
  2. With FOCUS_LD_BACKEND=x11, it seems the delay is shorter, ~2sec instead of ~10sec.
  3. With FOCUS_LD_BACKEND=wayland, if I copy twice the editor freezes indefinitely. If i copy and then paste into chrome, i get a ~5sec freeze but nothing gets pasted.

@ileonte
Copy link
Collaborator

ileonte commented Jan 3, 2025

Thank you for testing. I will try to reproduce the issue on my end.

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

No branches or pull requests

2 participants