Subject: Re: bug#17648: 24.4.50; regression: emacsclient under screen (1) slow for some values of TERM

From: Daniel Colascione <[email-masked]>
Date: Sat, 31 May 2014 18:26:25 -0700

On 05/31/2014 06:25 PM, Daniel Colascione wrote:
> On 05/31/2014 06:23 PM, Stefan Monnier wrote:
>>> almost instantaneously shows the scratch buffer (or some other
>>> last used buffer), then for 2 secs nothing happens, then the
>>> window shows the buffer which corresponds to some-file-name and
>>> one is able to work with it.
>>
>>> This happens for some values of TERM.
>>
>> Can you describe as precisely as possible the text-terminal you're
>> using, and tell us what C-h l says right after this 2s delay?
>>
>>> I did a git bisect on the repo and this produced:
>> [...]
>>>     2014-04-17  Daniel Colascione  <[email-masked]>
>>>         Add support for bracketed paste mode; add infrastructure for
>>>         managing terminal mode enabling and disabling automatically.
>>
>> Dan, it looks like the magic sequence to enable bracketed paste mode
>> will need to use some version checking code :-(
>> Can you take a look at it?
> 
> Sure --- but I'm not sure why the result varies depending on the value
> of TERM. Aren't we sending the same sequence regardless? Jim's recent
> complaint about another two second delay seems related. I feel like the
> terminal-echo recognition must be wrong somehow.

Also, that change also made term/screen.el use term/xterm.el. It's not
the bracketed paste stuff per se that's causing the problem, but the
terminal echo stuff.