18

I'm having some trouble reading vim's documentation on the terminal because I can't follow the links that are given.

I quote:

Jump to a subject: Position the cursor on a tag (e.g. |bars|) and hit CTRL-].

The problem is that i'm using a spanish keyboard where the "+" and the "]" are on the same button so when I hit CTRL-], I make a zoom.

Can I map the CTRL-] to any other keys somehow or is there any other option?

7
  • Did you try anything? E.g. nnoremap <leader>h <c-]>
    – VanLaser
    Oct 28, 2015 at 20:13
  • 2
    I use the following mapping: nnoremap <buffer> <cr> <c-]> in ~/.vim/after/ftplugin/help.vim. Oct 28, 2015 at 21:25
  • I've placed the mappings in my ~/.vimrc file and it still doesn't work
    – Wylex
    Oct 29, 2015 at 12:42
  • 1
    Maybe CTRL-Shift-]?
    – blm
    Oct 29, 2015 at 16:52
  • It works fine. Thanks, I can jump now from tag to tag easily. @blm
    – Wylex
    Oct 29, 2015 at 17:39

3 Answers 3

9

One option (if you don't mind a bit of typing) is to type :tag tagname and press enter. This is exactly equivalent to Ctrl-] according to :help CTRL-].

If you use this, please note that you can use tab completion just as when typing :help topic commands, and you can use Ctrl-D to list the possible autocompletions of what you've typed so far.

I admit this isn't much of an alternative, but it's worth knowing.

0
8

Another option is using clicking on the tag, if set mouse=a is on.

1
  • 2
    It does work but I'd prefer not having to use the mouse.
    – Wylex
    Oct 29, 2015 at 12:38
3

For those having french AZERTY keyboard, try

CTRL + $ ($,£,¤ key)

4
  • 2
    > For those having french AZERTY keyboard, try > CTRL + $ ($,£,¤ key) How come??
    – Abd
    Jun 16, 2019 at 21:16
  • 1
    @Abd I think he refers to the position where ] is located on a QWERTY keyboard.
    – herve
    Apr 14, 2023 at 9:34
  • Yes this is the real reason ! At the time I remember trying random combinations on my keyboard to find this... Apr 14, 2023 at 15:22
  • For me on an AZERTY Apple keyboard, the $ and £/backtick keys are different. CTRL+$ did nothing, but CTRL+£ was the winner. Thanks for this, I never understood why the default shortcut was not working and how to get around this. Jul 9, 2023 at 10:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.