Elektrine lite

← Feed

@piusbird@tilde.zone

Post #2683322

2025-09-03 20:19 UTC

Today i learned a Fun fact about x11/gtk, there are three clipboards Called PRIMARY, CLIPBOARD, and SECONDARY. PRIMARY takes the traditional unix behavior of containing anything that is selected in the current window, CLIPBOARD is the one that contains the stuff you've explicitly put there, and SECONDARY is just kinda there. Some software plays with it emacs for one. Except that PRIMARY can contain cut/copied text, sometimes, but will almost never contain images/multimedia. This three clipboard set up has been the way things are done. In linuxland since the release of QT3/Emacs 21 That was in 2001. Where is this documented you might ask.. Surely in the gtk docs, or the qt docs... Nope. The gtk docs only reference a freedesktop spec. That's store in a now deleted CVS repo.. Luckily someone put it into the wiki, which i was able to find with some google fu. They said being a terminally online free software hacker person would be FUN, and Exciting. Archeology was never really my speed though. :)

Replies (1)

  • @acdw@tilde.zone 2025-09-03 20:35

    @piusbird@tilde.zone what does emacs use SECONDARY for? or any other programs? I remember seeing references to it but no information

    Open ##3201548