mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 03:07:36 +00:00
LibVT: Implement Bracketed Paste Mode
This mode allow us to escape any data that was not directly typed by the user. `vim` currently uses this. If we implement it in the shell, we could prevent newlines from being injected into the shell by pasting text or dragging files into it (see #7276).
This commit is contained in:
parent
ee24f2eb2d
commit
708f835477
4 changed files with 53 additions and 12 deletions
|
@ -105,6 +105,10 @@ void Terminal::alter_mode(bool should_set, Parameters params, Intermediates inte
|
|||
m_client.set_cursor_style(None);
|
||||
}
|
||||
break;
|
||||
case 2004:
|
||||
dbgln_if(TERMINAL_DEBUG, "Setting bracketed mode enabled={}", should_set);
|
||||
m_needs_bracketed_paste = should_set;
|
||||
break;
|
||||
default:
|
||||
dbgln("Terminal::alter_mode: Unimplemented private mode {} (should_set={})", mode, should_set);
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue