Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: bracketed-paste & gnome-terminal

Missed this one ...

On Mar 14, 12:57pm, Danek Duvall wrote:
} I see something similar when running zsh from M-x shell in emacs (something
} another user pointed me at):
}     $ ^[[?2004h
}     ^[[?2004l
} Everything's fine when it pastes, presumably because emacs' terminal
} emulation doesn't support bracketed paste.

Emacs terminal emulation always behaves as if bracketed-paste were in
effect, because it's not attempting to do live interaction with the
program running in the buffer -- that is, you do all your editing in
the emacs buffer without anything being sent to the shell, and then
when you finally press enter (or equivalent binding) it all gets
transmitted at once.

So emacs has no reason to recognize escapes that differentiate a paste
from any other kind of input.

} Is there any way around either of these problems, other than
} explicitly unsetting zle_bracketed_paste when detecting that you're
} running inside an emacs terminal or gnome-terminal?

No, not that I can think of.

These are among the reasons that I think bracketed-paste ought to have
been something you have to explicitly turn ON, rather than something
you have to turn off, but consensus went the other way.

Barton E. Schaefer

Messages sorted by: Reverse Date, Date, Thread, Author