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

Wayland: Copy and paste issue #15198

Open
2 tasks done
Expore-it-all opened this issue Jul 4, 2024 · 8 comments
Open
2 tasks done

Wayland: Copy and paste issue #15198

Expore-it-all opened this issue Jul 4, 2024 · 8 comments
Labels
Help wanted Help wanted by testers and devs OS: Linux Packaging: flatpak flatpak related Status: Confirmed The issue was confirmed by others Status: Duplicate for potential duplicates Status: Solution proposed The issue has a solution proposed Type: Bug This issue or PR is related to a bug

Comments

@Expore-it-all
Copy link

Is there an existing issue for this?

  • I have searched the existing issues

Problem description

This is my first time posting an issue on Git Hub for this project, if I have missed anything please let me know.
Hi all, I have been using Freecad on Linux and after creating a body I wanted to copy and paste it like I have been able to do so on windows. but I have found that I am getting an error.

Here is the error I am seeing for it whenever I try to copy and paste through the context menu or shortcut keys.

20:13:43  (qt.qpa.clipboard) QXcbClipboard::setMimeData: Cannot set X11 selection owner

I can copy and paste text normally but trying to do so on a body causes this. I have a hunch it is because of Wayland and XWaylandBridge Issues, though Im not 100% sure on this.
I have attached a video of this in action. I tried both context and shortcuts to copy but it still happens.

Full version info

OS: KDE neon 6.0 (KDE/plasma)
Word size of FreeCAD: 64-bit
Version: 0.21.2.33771 (Git) AppImage
Build type: Release
Branch: (HEAD detached at 0.21.2)
Hash: b9bfa5c5507506e4515816414cd27f4851d00489
Python 3.10.13, Qt 5.15.8, Coin 4.0.0, Vtk 9.2.6, OCC 7.6.3
Locale: English/United States (en_US)
Installed mods: 
  * Dracula 0.0.5

Subproject(s) affected?

Core

Anything else?

2024-06-25.20-22-55.mp4

Code of Conduct

  • I agree to follow this project's Code of Conduct
@Expore-it-all
Copy link
Author

After some more looking I have found that there is also another Issue related to XWaylandBridge and Copy and Pasting
#10251
Only difference is this is the AppImage Format not flatpack.

@maxwxyz maxwxyz added Status: Duplicate for potential duplicates OS: Linux Packaging: flatpak flatpak related Help wanted Help wanted by testers and devs labels Jul 5, 2024
@krushia
Copy link

krushia commented Jul 6, 2024

Begin rant.

This is a Wayland limitation. Wayland only "supports" (this is generous wording) the primary X copy buffer by design, which it uses for wl_clipboard. Here we have an error that is about the selection buffer, which Wayland has no support for at all.

Usually when a project "fixes" this, they also break middle-click paste for people on X11 (CherryTree is one example). This makes me sad. Properly supporting Wayland's weirdness can be quite involved; see for example rustdesk/rustdesk#5900.

End rant.

Simply rebuilding the Flatpak will probably solve it.

@Expore-it-all
Copy link
Author

I wish I knew more about coding in the Linux Environment so I could help with this, but my knowledge is quite limited in that aspect. Thanks for letting me know about the issues about it.

@luzpaz
Copy link
Contributor

luzpaz commented Jul 22, 2024

Any care to let the FC flatpak packager in on this discussion ?

@djkato
Copy link

djkato commented Aug 25, 2024

Please at least in the meantime add an option to "duplicate" under the right click menu while this is broken. Duplicating sketches/bodies etc shouldn't be broken because of the systems clipboard manager. Imo this should be possible inside FreeCAD regardless.(SS from this weeks weekly build)
image

This comment has been minimized.

@github-actions github-actions bot added the Status: Stale Stale and might be closed automatically. label Dec 7, 2024
@tarman3
Copy link

tarman3 commented Dec 7, 2024

Still relevant in AppImage

FreeCAD 1.0.0.39109 (Git), Arch Linux (KDE/plasma/xcb)
OS: Arch Linux (KDE/plasma/xcb)
Architecture: x86_64
Version: 1.0.0.39109 (Git) Conda AppImage
Build type: Release
Branch: (HEAD detached at 1.0.0)
Hash: 2fcc5317fe3aee96ca73475986a577719fc78e20
Python 3.11.9, Qt 5.15.13, Coin 4.0.3, Vtk 9.2.6, OCC 7.7.2
Locale: English/United States (en_US)
Stylesheet/Theme/QtStyle: FreeCAD Dark.qss/FreeCAD Dark/Fusion
Installed mods: lattice2 1.0.0; CurvedShapes 1.0.13; MeshRemodel 1.10.35; freecad.gears 1.3.0; fasteners 0.5.33; sheetmetal 0.6.0; Silk 0.1.5; Curves 0.6.51
FreeCAD 1.1.0dev.39416 (Git) Conda AppImage, Arch Linux (KDE/plasma/xcb)
OS: Arch Linux (KDE/plasma/xcb)
Architecture: x86_64
Version: 1.1.0dev.39416 (Git) Conda AppImage
Build type: Release
Branch: main
Hash: f6268ffd2877dadb4440ade541e12c388a517d6e
Python 3.11.9, Qt 5.15.13, Coin 4.0.3, Vtk 9.2.6, OCC 7.7.2
Locale: English/United States (en_US)
Stylesheet/Theme/QtStyle: FreeCAD Dark.qss/FreeCAD Dark/Fusion
Installed mods: lattice2 1.0.0; CurvedShapes 1.0.13; MeshRemodel 1.10.35; freecad.gears 1.3.0; fasteners 0.5.33; sheetmetal 0.6.0; Silk 0.1.5; Curves 0.6.51

Not reproduced in

FreeCAD 1.0.0.39109 (Git) makepkg, Arch Linux (KDE/plasma/wayland)
OS: Arch Linux (KDE/plasma/wayland)
Architecture: x86_64
Version: 1.0.0.39109 (Git)
Build type: Release
Branch: makepkg
Hash: 2fcc5317fe3aee96ca73475986a577719fc78e20
Python 3.12.7, Qt 6.8.0, Coin 4.0.3, Vtk 9.3.1, OCC 7.8.1
Locale: English/United States (en_US)
Stylesheet/Theme/QtStyle: FreeCAD Dark.qss/FreeCAD Dark/
Installed mods: lattice2 1.0.0; CurvedShapes 1.0.13; MeshRemodel 1.10.35; freecad.gears 1.3.0; fasteners 0.5.33; sheetmetal 0.6.0; Silk 0.1.5; Curves 0.6.51

@maxwxyz maxwxyz added Type: Bug This issue or PR is related to a bug Status: Confirmed The issue was confirmed by others and removed Status: Stale Stale and might be closed automatically. labels Dec 7, 2024
@Makotophoto
Copy link

I would like to give some hints, since i encountered the copy/paste issue by the usage of a workaround for another problem.

My first problem was the 3d display not rendering with console message Couldn't get current GLX context.
The workaround was to add the environment variable QT_QPA_PLATFORM=xcb
This one is generating the copy/paste problem.

I solved the 2 issues by replacing this environment variable by : __GLX_VENDOR_LIBRARY_NAME=mesa __EGL_VENDOR_LIBRARY_FILENAMES=/usr/share/glvnd/egl_vendor.d/50_mesa.json (recipe found for another app getting display problems)

Using Manjaro Unstable / KDE / Wayland / Nvidia / Freecad-git (AUR)

@luzpaz luzpaz added the Status: Solution proposed The issue has a solution proposed label Dec 16, 2024
@luzpaz luzpaz changed the title Linux FreeCAD Copy and paste issue with wayland Wayland: Copy and paste issue Dec 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Help wanted Help wanted by testers and devs OS: Linux Packaging: flatpak flatpak related Status: Confirmed The issue was confirmed by others Status: Duplicate for potential duplicates Status: Solution proposed The issue has a solution proposed Type: Bug This issue or PR is related to a bug
Projects
None yet
Development

No branches or pull requests

7 participants