Micah Cowan wrote:
I wrote:
Therefore, there would seem to be no harm whatsoever in detecting screen
as an xterm-mouse-code-capable terminal, and sending the mouse-mode
sequence ("xterm" protocol, since AFAIK screen provides no way to detect
the underlying xterm version). If the underlying terminal claims to be
xterm or rxvt, then the user will automatically get the benefit of mouse
support without trouble; otherwise, screen will simply ignore the
sequence and no harm is done to other terminals (such as unrecognized
sequence-emitters, or DEC-mouse-only terminals).

Attached is a proposed patch that effects the change I'm requesting. I
would love to get some feedback/further discussion based on it. They say
"code talks", and so here is my concrete expression. :)



Shouldn't it rather use the 'ttymouse' option? IIUC, that option is supposed to be set to either "xterm" or "xterm2" at startup if the terminal is known to support xterm mouse codes. This is done as a result of sending the t_RV code and receiving an answer for it, which happens after the first file has been loaded and all -c commands have been processed: probably just before or just after the VimEnter event. IOW, you cannot test them in your vimrc or even in a global plugin (they are sourced too early). At the VimEnter event might be late enough but I haven't tested it.


Best regards,
Tony.
--
A billion here, a couple of billion there -- first thing you know it
adds up to be real money.
                -- Senator Everett McKinley Dirksen

Reply via email to