macvim-dev / macvim-dev/macvim

Add ability to map <TAB> and <C-I> separately like XTerm or iTerm2 have done

Open
#1,052 3 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Input Vim Parity
Dominant language
Vim Script
Stars
7.9k
Forks
691
PR merge metrics
No merged PRs in 30d

Description

Is your feature request about something that is currently impossible or hard to do? Please describe the problem.
Currently we can't remap for example <TAB> and <C-I> separately, they both always do the same thing.

Describe the solution you'd like
Would be nice if these, and other control keys (<CR> and <C-M>, <BS> and <C-H> etc.), could be mapped separately.

Additional context
<TAB> and <C-I> can already be mapped separately in a Vim 8.2 running XTerm using modifyOtherKeys https://invisible-island.net/xterm/modified-keys.html or in iTerm2 when 'Control sequences can enable modifyOtherKeys mode' has been enabled from Preferences -> Profiles -> Keys.

One can easily test if the keys get registered separately with:

nnoremap <C-I> :echom "Ctrl-I was pressed"<CR>
nnoremap <TAB> :echom "Tab was pressed"<CR>

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the mapping behavior with the two nnoremap commands from the issue, then read the XTerm modifyOtherKeys documentation and compare it with MacVim's keyboard input handling. The work is done when and , along with analogous control-key pairs, can trigger separate mappings and the example commands report distinct messages.

Written by the indexing model from the issue text.

Assessment

Tech stack
macos, vim
Domain
desktop
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.