pub struct TermTuiKeyBindings {Show 28 fields
pub enter_copy_mode: KeyEvent,
pub copy_selection: KeyEvent,
pub copy_exit: KeyEvent,
pub copy_exit_alt: KeyEvent,
pub copy_move_up: KeyEvent,
pub copy_move_up_alt: KeyEvent,
pub copy_move_down: KeyEvent,
pub copy_move_down_alt: KeyEvent,
pub copy_move_left: KeyEvent,
pub copy_move_left_alt: KeyEvent,
pub copy_move_right: KeyEvent,
pub copy_move_right_alt: KeyEvent,
pub copy_line_start: KeyEvent,
pub copy_line_start_alt: KeyEvent,
pub copy_line_end: KeyEvent,
pub copy_line_end_alt: KeyEvent,
pub copy_page_up: KeyEvent,
pub copy_page_up_alt: KeyEvent,
pub copy_page_down: KeyEvent,
pub copy_page_down_alt: KeyEvent,
pub copy_top: KeyEvent,
pub copy_bottom: KeyEvent,
pub copy_word_left: KeyEvent,
pub copy_word_right: KeyEvent,
pub copy_start_selection: KeyEvent,
pub copy_start_selection_alt: KeyEvent,
pub copy_and_exit: KeyEvent,
pub copy_and_exit_alt: KeyEvent,
}Expand description
Customizable keybindings for TermTui
This struct holds all keybindings that can be customized.
Each field is a KeyEvent that specifies the key combination.
Fields§
§enter_copy_mode: KeyEventEnter copy mode (default: Ctrl+X)
copy_selection: KeyEventCopy selection to clipboard (default: Ctrl+Shift+C)
copy_exit: KeyEventExit copy mode (default: Esc)
copy_exit_alt: KeyEventAlternative exit copy mode (default: q)
copy_move_up: KeyEventMove cursor up in copy mode (default: k or Up)
copy_move_up_alt: KeyEventAlternative move up (default: Up arrow)
copy_move_down: KeyEventMove cursor down in copy mode (default: j or Down)
copy_move_down_alt: KeyEventAlternative move down (default: Down arrow)
copy_move_left: KeyEventMove cursor left in copy mode (default: h or Left)
copy_move_left_alt: KeyEventAlternative move left (default: Left arrow)
copy_move_right: KeyEventMove cursor right in copy mode (default: l or Right)
copy_move_right_alt: KeyEventAlternative move right (default: Right arrow)
copy_line_start: KeyEventMove to line start (default: 0 or Home)
copy_line_start_alt: KeyEventAlternative line start (default: Home)
copy_line_end: KeyEventMove to line end (default: $ or End)
copy_line_end_alt: KeyEventAlternative line end (default: End)
copy_page_up: KeyEventPage up (default: u or PageUp)
copy_page_up_alt: KeyEventAlternative page up (default: PageUp)
copy_page_down: KeyEventPage down (default: d or PageDown)
copy_page_down_alt: KeyEventAlternative page down (default: PageDown)
copy_top: KeyEventGo to top (default: g)
copy_bottom: KeyEventGo to bottom (default: G)
copy_word_left: KeyEventMove word left (default: b)
copy_word_right: KeyEventMove word right (default: w)
copy_start_selection: KeyEventStart/toggle selection (default: v or Space)
copy_start_selection_alt: KeyEventAlternative start selection (default: Space)
copy_and_exit: KeyEventCopy and exit (default: y or Enter)
copy_and_exit_alt: KeyEventAlternative copy and exit (default: Enter)
Implementations§
Source§impl TermTuiKeyBindings
impl TermTuiKeyBindings
Sourcepub fn key_matches(key: &KeyEvent, binding: &KeyEvent) -> bool
pub fn key_matches(key: &KeyEvent, binding: &KeyEvent) -> bool
Check if a key event matches a keybinding (ignoring state field differences)
Source§impl TermTuiKeyBindings
impl TermTuiKeyBindings
Sourcepub fn key_to_display_string(key: &KeyEvent) -> String
pub fn key_to_display_string(key: &KeyEvent) -> String
Convert a KeyEvent to a display string for showing in UI
Trait Implementations§
Source§impl Clone for TermTuiKeyBindings
impl Clone for TermTuiKeyBindings
Source§fn clone(&self) -> TermTuiKeyBindings
fn clone(&self) -> TermTuiKeyBindings
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for TermTuiKeyBindings
impl Debug for TermTuiKeyBindings
Auto Trait Implementations§
impl Freeze for TermTuiKeyBindings
impl RefUnwindSafe for TermTuiKeyBindings
impl Send for TermTuiKeyBindings
impl Sync for TermTuiKeyBindings
impl Unpin for TermTuiKeyBindings
impl UnwindSafe for TermTuiKeyBindings
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
ReadEndian::read_from_little_endian().