bug#74833: 31.0.50; Copy to OS clipboard doesn't work in macOS Terminal.app with xterm-mouse-mode enabled
Eli Zaretskii <[email protected]>
| Newsgroups | gmane.emacs.bugs |
|---|---|
| Message-ID | <[email protected]> |
> From: Philip Kaludercic <[email protected]> > Cc: Eli Zaretskii <[email protected]>, [email protected], > [email protected], [email protected], [email protected], > [email protected], Sean Whitton <[email protected]> > Date: Sun, 16 Aug 2026 17:27:57 +0000 > > Jared Finder <[email protected]> writes: > > > On 2026-08-15 23:21, Philip Kaludercic wrote: > >> Jared Finder <[email protected]> writes: > >>> On 2026-08-15 10:11, Philip Kaludercic wrote: > >>>> Jared Finder <[email protected]> writes: > >>>>> On 2026-08-15 07:13, Philip Kaludercic wrote: > >>>>>> Jared Finder <[email protected]> writes: > >>>>>> [...] > >>>>>> > >>>>>>> +(defconst xterm--auto-xt-mouse-allowed-names > >>>>>>> + (mapconcat (lambda (s) (concat "^" s "\\>")) > >>>>>>> + '("Konsole" > >>>>>>> + "WezTerm" > >>>>>>> + ;; "XTerm" ;Disabled because OSC52 support is > >>>>>>> opt-in only. > >>>>>>> + "iTerm2" ;OSC52 support has opt-in/out UI on > >>>>>>> first usage > >>>>>>> + "kitty") > >>>>>>> + "\\|") > >>>>>>> + "Regexp for terminals that automatically enable > >>>>>>> `xterm-mouse-mode' at startup. > >>>>>>> +This will get matched against the terminal's XTVERSION string. > >>>>>> Would it be possible to add VTE > >>>>>> (https://gitlab.gnome.org/GNOME/vte) > >>>>>> to > >>>>>> this list, to support GNOME's terminal and other terminal emulators > >>>>>> that > >>>>>> use the library (AFAIK that include XFCE's and MATE's terminal > >>>>>> emulator). > >>>>>> [...] > >>>>> Don't modern versions of VTE now report OSC52 from a primary DA > >>>>> query? > >>>>> Try running "echo -e '\e[c'", is 52 in the returned list? > >>>> No, it responds with > >>> That's unfortunate. > >>> What does the terminal return from an XTVERSION request? That's > >>> "echo > >>> -e '\e[>0q'". Assuming the string is unique enough, we can add it to > >>> the list. > >> Both GNOME Terminal, Console and XFCE4 terminal respond with: > >> :>|VTE(8001)^[\ > > > > Great, adding "VTE" to the list of console names inside > > xterm--auto-xt-mouse-allowed-names should be sufficient. Can someone > > with write access to the Emacs repo do that? Ideally this is also > > done on the 31 branch. > > I can push the following patch to emacs31 if Sean and/or Eli are OK with > it. I have tested it with GNOME terminal and it does enable > xterm-mouse-mode in emacs -Q -nw: Fine by me, thanks.