←back to thread

345 points splitbrain | 6 comments | | HN request time: 0s | source | bottom
Show context
OsrsNeedsf2P ◴[] No.41837682[source]
I love how simple this is- Barely 100 lines or C++ (ignoring comments). That's one thing that makes me prefer X11 over Wayland.
replies(8): >>41837906 #>>41838181 #>>41838339 #>>41838393 #>>41838489 #>>41838500 #>>41838693 #>>41844644 #
1. tapoxi ◴[] No.41838489[source]
In Wayland you just start a capture with the xdg-desktop-portal API and it notifies the user and let them select the area to capture.
replies(1): >>41838564 #
2. gchamonlive ◴[] No.41838564[source]
Yes, but I believe op was refering to how interacting with all things Wayland seems to be more involved than with x11. I'm not sure this is indeed like this, I have zero experience in developing for Wayland, but I think this is what op meant.
replies(2): >>41838611 #>>41839837 #
3. tapoxi ◴[] No.41838611[source]
From a quick "how do I implement this in Python" with ChatGPT it seems to be about 30 lines, since most of the heavy lifting is done for you by the API.
replies(2): >>41839123 #>>41842491 #
4. Zetaphor ◴[] No.41839123{3}[source]
As someone who uses LLM's regularly to assist in code creation, take that output with a huge grain of salt until you've actually tested it. Especially as it relates to Wayland, I've pulled my hair out trying to get an LLM to assist with very similar tasks to this.
5. yndoendo ◴[] No.41839837[source]
Wayland is more focused on security. That onion layer right there will increase the complexity of usage. X11 doesn't have the extra abstractions to limit and prevent intrusive interactions with the desktop.

Example of this would be where "runas /user:smith application.exe" is simple but does not work when a Windows Service is required to run an application as the user signed in. One must use Window's API to pull in the account's token and use more API to execute "application.exe". UltraVNC is a great source to see all the extras needed.

6. p_l ◴[] No.41842491{3}[source]
It means you got to tickle the banana, good luck making sure that the gorilla holding it is fine with that.