ttcdt / mp-5.x

The Minimum Profit Text Editor
The Unlicense
23 stars 4 forks source link

x11 clipboard #6

Open rofl0r opened 3 years ago

rofl0r commented 3 years ago

hi, on a typical linux desktop there are 2 different clipboards:

currently mp-5 only supports the former, not the latter so i can't e.g. select text in mp-5 gtk version and paste it via middle click into xterm.

ttcdt commented 3 years ago

hi the ctrl-c+ctrl-v thing in x11 is called the clipboard, the one that copies & pastes is named the 'selection'. Even there are primary and secondary selections (i dont know of anything that uses the secondary)

mp on gtk uses the clipboard because implementing the selection is more complicated and reliable. with the clipbaord you only set and put its content but with the selection you have to attend to several signals and such. it also has problems with pasting unicode characters higher that U+ffff (IIRC)

older versions of mp used the selection but didnt work very well.

cheers, tiny

10/11/20 16:49, rofl0r:

hi, on a typical linux desktop there are 2 different clipboards:

  • the CTRL-c CTRL-v one used by e.g. GTK apps (i'm not sure what's the correct name of it)
  • the X11 one which copies any selected text, can be pasted via middle-mouse button click.

currently mp-5 only supports the former, not the latter so i can't e.g. select text in mp-5 gtk version and paste it via middle click into xterm.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/ttcdt/mp-5.x/issues/6, or unsubscribe https://github.com/notifications/unsubscribe-auth/AP4PJ2IGXJASTARZR2DPA7TSPFOIRANCNFSM4TQ2O6PA.