From 4600b76efe80c9ba0461276412e58992d2300cae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20Andr=C3=A9=20Tanner?= Date: Fri, 13 Jan 2017 13:18:44 +0100 Subject: vis: introduce registers 0-9 and & to capture search matches These are currently only updated for `x` and `y` sam commands, whether they should be updated for other search related activities (`/`, `?`, `n`, `N`, `*`, `#` etc.) needs to be investigated. --- vis.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'vis.c') diff --git a/vis.c b/vis.c index 691c3fc..94ea2e4 100644 --- a/vis.c +++ b/vis.c @@ -37,6 +37,16 @@ const MarkDef vis_marks[] = { const RegisterDef vis_registers[] = { [VIS_REG_DEFAULT] = { '"', "Unnamed register" }, [VIS_REG_ZERO] = { '0', "Yank register" }, + [VIS_REG_1] = { '1', "1st sub-expression match" }, + [VIS_REG_2] = { '2', "2nd sub-expression match" }, + [VIS_REG_3] = { '3', "3rd sub-expression match" }, + [VIS_REG_4] = { '4', "4th sub-expression match" }, + [VIS_REG_5] = { '5', "5th sub-expression match" }, + [VIS_REG_6] = { '6', "6th sub-expression match" }, + [VIS_REG_7] = { '7', "7th sub-expression match" }, + [VIS_REG_8] = { '8', "8th sub-expression match" }, + [VIS_REG_9] = { '9', "9th sub-expression match" }, + [VIS_REG_AMPERSAND] = { '&', "Last regex match" }, [VIS_REG_BLACKHOLE] = { '_', "/dev/null register" }, [VIS_REG_CLIPBOARD] = { '*', "System clipboard register, see vis-clipboard(1)" }, [VIS_MACRO_REPEAT] = { '.', "Last inserted text" }, -- cgit v1.2.3