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
[sokol_app] basic X11 clipboard #998
base: master
Are you sure you want to change the base?
Conversation
Implement clibpard feature using Xlib. This is a basic version which only supports utf8 target and the clibpoard selection. (not the selection + middle click workflow). Simplified adaptation of glfw in https://github.com/glfw/glfw/blob/master/src/x11_window.c
That looks reasonably simple :) Somehow and suddenly there's a wave of PRs coming in, it might be a couple of days before I have time to properly look at the PR. In the meantime, have a look at the failed CI build please: https://github.com/floooh/sokol/actions/runs/8015098805/job/21903872711?pr=998 Unused variable warnings should be supressed with (the CI builds have extremely picky warning settings) PS: also somehow, there's X11 code that leaked into the Android and iOS builds (search for Android: https://github.com/floooh/sokol/actions/runs/8015098802/job/21903872342?pr=998 iOS: https://github.com/floooh/sokol/actions/runs/8015098802/job/21903873030?pr=998 You can test locally whether the Linux version compiles with the strict CI warning settings by running |
PPS:
I don't have clang-format setup yet, you should mainly check that the opening But please don't run a formatter over the code, that tends to bury the actual changes in formatting noise. |
77a51b9
to
228b073
Compare
Updated. Hopefully all failure are gone.
All good, thanks in the first place for considering them. |
FYI I'll start testing this PR next, but not sure yet if I'll get around to merge today or tomorrow. |
Thanks for testing! Hum, I need to investigate, both direction are definitely working on my machine. (Fedora 38, Gnome running on X11). |
Interesting that it works on your side, can you describe step by step how you cut/copy out of an sokol-app application into the system? Maybe I messed something up or encountered an edge case. |
Ctrl+X/Ctrl+C from the |
BTW, I did not abandon this PR, but I am lacking time to test on a ubuntu machine to debug currently. My attempt to use a virtual machine was not successfull so far. |
Implement clibpard feature using Xlib. This is a basic version which only supports utf8 target and the clibpoard selection. (not the selection + middle click workflow).
Simplified adaptation of glfw in https://github.com/glfw/glfw/blob/master/src/x11_window.c