@@ -8,95 +8,6 @@ use std::{
88 ops::{Deref, DerefMut},
99};
1010
11−// Kakoune-inspired:
12−// mode = {
13−// normal = {
14−// q = record_macro
15−// w = (next) word
16−// W = next WORD
17−// e = end of word
18−// E = end of WORD
19−// r = replace
20−// R = replace with yanked
21−// t = 'till char
22−// y = yank
23−// u = undo
24−// U = redo
25−// i = insert
26−// I = INSERT (start of line)
27−// o = open below (insert on new line below)
28−// O = open above (insert on new line above)
29−// p = paste (before cursor)
30−// P = PASTE (after cursor)
31−// ` =
32−// [ = select to text object start (alt = select whole object)
33−// ] = select to text object end
34−// { = extend to inner object start
35−// } = extend to inner object end
36−// a = append
37−// A = APPEND (end of line)
38−// s = split
39−// S = select
40−// d = delete()
41−// f = find_char()
42−// g = goto (gg, G, gc, gd, etc)
43−//
44−// h = move_char_left(n) || arrow-left = move_char_left(n)
45−// j = move_line_down(n) || arrow-down = move_line_down(n)
46−// k = move_line_up(n) || arrow_up = move_line_up(n)
47−// l = move_char_right(n) || arrow-right = move_char_right(n)
48−// : = command line
49−// ; = collapse selection to cursor
50−// " = use register
51−// ` = convert case? (to lower) (alt = swap case)
52−// ~ = convert to upper case
53−// . = repeat last command
54−// \ = disable hook?
55−// / = search
56−// > = indent
57−// < = deindent
58−// % = select whole buffer (in vim = jump to matching bracket)
59−// * = search pattern in selection
60−// ( = rotate main selection backward
61−// ) = rotate main selection forward
62−// - = trim selections? (alt = merge contiguous sel together)
63−// @ = convert tabs to spaces
64−// & = align cursor
65−// ? = extend to next given regex match (alt = to prev)
66−//
67−// in kakoune these are alt-h alt-l / gh gl
68−// select from curs to begin end / move curs to begin end
69−// 0 = start of line
70−// ^ = start of line(first non blank char) || Home = start of line(first non blank char)
71−// $ = end of line || End = end of line
72−//
73−// z = save selections
74−// Z = restore selections
75−// x = select line
76−// X = extend line
77−// c = change selected text
78−// C = copy selection?
79−// v = view menu (viewport manipulation)
80−// b = select to previous word start
81−// B = select to previous WORD start
82−//
83−//
84−//
85−//
86−//
87−//
88−// = = align?
89−// + =
90−// }
91−//
92−// gd = goto definition
93−// gr = goto reference
94−// [d = previous diagnostic
95−// d] = next diagnostic
96−// [D = first diagnostic
97−// D] = last diagnostic
98−// }
99−
10011#[macro_export]
10112macro_rules! key {
10213 ($key:ident) => {