I'm trying to make emacs work well inside mintty/mosh. I'd like mintty to send an alternate escape sequence for "C-Backspace" than the default (which is "C-_"). There is an xterm sequence for this -- "\e[>4;1m" -- which sets the "modifyOtherKeys" resource. Emacs sends that sequence on startup. When using ssh for remoting, the sequence is passed to the client side, mintty sees it, and implements the desired behavior.
The mosh terminal emulator appears to discard the sequence. There is no matching function in terminal/terminalfunctions.cc defined for it, so the dispatch process hits the "unknown function" condition in terminal/terminaldispatcher.cc@226 (Dispatcher::dispatch()). As an experiment, I've added a terminal function for "\e[>4;1m" and confirmed that it sees the sequence when emacs sends it. I'm stuck on what to do next. It looks like I need to add something to Terminal::DrawState, then in Display::new_frame() look for that member and call frame.append("\e[>4;1m"); That's how the "mouse_reporting_mode" and similar settings are handled. But this might bring up a bigger question: How should the mosh terminal emulator interact with the client side terminal emulator? I can add support for this specific sequence, but maybe something more general is warranted. Any advice?
_______________________________________________ mosh-devel mailing list mosh-devel@mit.edu http://mailman.mit.edu/mailman/listinfo/mosh-devel