Skip to main content

is_undo_input

Function is_undo_input 

Source
pub fn is_undo_input(key: &KeyEvent) -> bool
Expand description

Whether key is the undo chord TextArea::input binds: lowercase ‘z’ with Ctrl or Cmd. Uppercase ‘Z’ (redo) is intentionally excluded, which keeps this guard disjoint from the redo arm regardless of order.

Single source for the binding: input()’s undo arm consumes this predicate, and hosts that react to undo (e.g. retiring an undo hint) call it too, so the chord and its observers cannot drift.