From 5fe7315df9fd11b45c3ca9e35e0f74c07533c0aa Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Mon, 18 Mar 2013 22:31:05 +0100 Subject: [PATCH] add 'r' object alias for [] (range) --- README.asciidoc | 2 +- src/main.cc | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/README.asciidoc b/README.asciidoc index 7b74a12d..630ecec3 100644 --- a/README.asciidoc +++ b/README.asciidoc @@ -168,7 +168,7 @@ object you want. * _b_, _(_ or _)_: select the enclosing parenthesis * _B_, _{_ or _}_: select the enclosing {} block - * _[_ or _]_: select the enclosing [] block + * _r_, _[_ or _]_: select the enclosing [] block * _<_ or _>_: select the enclosing <> block * _"_: select the enclosing double quoted string * _'_: select the enclosing single quoted string diff --git a/src/main.cc b/src/main.cc index 594b7d30..cc56723e 100644 --- a/src/main.cc +++ b/src/main.cc @@ -371,6 +371,7 @@ void do_select_object(Context& context) { { Key::Modifiers::None, 'B' }, std::bind(select_surrounding, _1, CodepointPair{ '{', '}' }, flags) }, { { Key::Modifiers::None, '[' }, std::bind(select_surrounding, _1, CodepointPair{ '[', ']' }, flags) }, { { Key::Modifiers::None, ']' }, std::bind(select_surrounding, _1, CodepointPair{ '[', ']' }, flags) }, + { { Key::Modifiers::None, 'r' }, std::bind(select_surrounding, _1, CodepointPair{ '[', ']' }, flags) }, { { Key::Modifiers::None, '<' }, std::bind(select_surrounding, _1, CodepointPair{ '<', '>' }, flags) }, { { Key::Modifiers::None, '>' }, std::bind(select_surrounding, _1, CodepointPair{ '<', '>' }, flags) }, { { Key::Modifiers::None, '"' }, std::bind(select_surrounding, _1, CodepointPair{ '"', '"' }, flags) },