mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-16 16:56:09 +03:00
@ -2920,6 +2920,12 @@ pub fn performBindingAction(self: *Surface, action: input.Binding.Action) !bool
|
|||||||
try self.io_thread.wakeup.notify();
|
try self.io_thread.wakeup.notify();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
.reset => {
|
||||||
|
self.renderer_state.mutex.lock();
|
||||||
|
defer self.renderer_state.mutex.unlock();
|
||||||
|
self.renderer_state.terminal.fullReset(self.alloc);
|
||||||
|
},
|
||||||
|
|
||||||
.copy_to_clipboard => {
|
.copy_to_clipboard => {
|
||||||
// We can read from the renderer state without holding
|
// We can read from the renderer state without holding
|
||||||
// the lock because only we will write to this field.
|
// the lock because only we will write to this field.
|
||||||
|
@ -143,6 +143,15 @@ pub const Action = union(enum) {
|
|||||||
/// (`application`) or disabled (`normal`).
|
/// (`application`) or disabled (`normal`).
|
||||||
cursor_key: CursorKey,
|
cursor_key: CursorKey,
|
||||||
|
|
||||||
|
/// Reset the terminal. This can fix a lot of issues when a running
|
||||||
|
/// program puts the terminal into a broken state. This is equivalent to
|
||||||
|
/// when you type "reset" and press enter.
|
||||||
|
///
|
||||||
|
/// If you do this while in a TUI program such as vim, this may break
|
||||||
|
/// the program. If you do this while in a shell, you may have to press
|
||||||
|
/// enter after to get a new prompt.
|
||||||
|
reset: void,
|
||||||
|
|
||||||
/// Copy and paste.
|
/// Copy and paste.
|
||||||
copy_to_clipboard: void,
|
copy_to_clipboard: void,
|
||||||
paste_from_clipboard: void,
|
paste_from_clipboard: void,
|
||||||
|
Reference in New Issue
Block a user