pub enum KeyCode {
}Expand description
Key codes for keyboard input.
This is a simplified subset of crossterm’s KeyCode, designed
for the needs of agentic CLIs.
Variants§
Char(char)
A printable character.
F(u8)
Function key (F1-F12).
Backspace
Backspace key.
Enter
Enter/Return key.
Left
Left arrow.
Right
Right arrow.
Up
Up arrow.
Down
Down arrow.
Home
Home key.
End
End key.
PageUp
Page Up.
PageDown
Page Down.
Tab
Tab key.
BackTab
Backtab (Shift+Tab).
Delete
Delete key.
Insert
Insert key.
Esc
Escape key.
Null
Null (Ctrl+Space on some terminals).
Trait Implementations§
impl Copy for KeyCode
impl Eq for KeyCode
impl StructuralPartialEq for KeyCode
Auto Trait Implementations§
impl Freeze for KeyCode
impl RefUnwindSafe for KeyCode
impl Send for KeyCode
impl Sync for KeyCode
impl Unpin for KeyCode
impl UnwindSafe for KeyCode
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more