summaryrefslogtreecommitdiff
path: root/src/normal.cc
diff options
context:
space:
mode:
authorMaxime Coste <mawww@kakoune.org>2018-10-01 11:25:53 +1000
committerMaxime Coste <mawww@kakoune.org>2018-10-01 11:25:53 +1000
commit551021d6e5360c48c0d08da6464a2ee4081bb3d8 (patch)
tree2cd6a3751dafa2c7ad34d6d84d12e0556a4b6f93 /src/normal.cc
parent150ee050776f058cbd2ba451d8cb8e12bca73eaa (diff)
parent2d44712766081a0b3b4f71ac77f73e973e724b02 (diff)
Merge remote-tracking branch 'lenormf/backward-match'
Diffstat (limited to 'src/normal.cc')
-rw-r--r--src/normal.cc8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/normal.cc b/src/normal.cc
index eb71ce4a..7a1533ee 100644
--- a/src/normal.cc
+++ b/src/normal.cc
@@ -2185,7 +2185,7 @@ static const HashMap<Key, NormalCmd, MemoryDomain::Undefined, KeymapBackend> key
{ {';'}, {"reduce selections to their cursor", clear_selections} },
{ {alt(';')}, {"swap selections cursor and anchor", flip_selections} },
{ {alt(':')}, {"ensure selection cursor is after anchor", ensure_forward} },
- { {alt('m')}, {"merge consecutive selections", merge_consecutive} },
+ { {alt('_')}, {"merge consecutive selections", merge_consecutive} },
{ {'w'}, {"select to next word start", repeated<&select<SelectMode::Replace, select_to_next_word<Word>>>} },
{ {'e'}, {"select to next word end", repeated<select<SelectMode::Replace, select_to_next_word_end<Word>>>} },
@@ -2215,8 +2215,10 @@ static const HashMap<Key, NormalCmd, MemoryDomain::Undefined, KeymapBackend> key
{ {alt('x')}, {"extend selections to whole lines", select<SelectMode::Replace, select_lines>} },
{ {alt('X')}, {"crop selections to whole lines", select<SelectMode::Replace, trim_partial_lines>} },
- { {'m'}, {"select to matching character", select<SelectMode::Replace, select_matching>} },
- { {'M'}, {"extend to matching character", select<SelectMode::Extend, select_matching>} },
+ { {'m'}, {"select to matching character", select<SelectMode::Replace, select_matching<true>>} },
+ { {alt('m')}, {"backward select to matching character", select<SelectMode::Replace, select_matching<false>>} },
+ { {'M'}, {"extend to matching character", select<SelectMode::Extend, select_matching<true>>} },
+ { {alt('M')}, {"backward extend to matching character", select<SelectMode::Extend, select_matching<false>>} },
{ {'/'}, {"select next given regex match", search<SelectMode::Replace, MatchDirection::Forward>} },
{ {'?'}, {"extend with next given regex match", search<SelectMode::Extend, MatchDirection::Forward>} },