Skip to content

[audit] Nvim 0.13 repurposes the unmapped default Q for multicursor, not macro replay #335

Description

@stanfish06

What

Nvim HEAD's runtime/doc/news.txt (BREAKING CHANGES > EDITOR) documents:

Q adds a |multicursor| instead of replaying the last recorded register. To get the old behavior:

vim.keymap.set('n', 'Q', function()
  local reg = vim.fn.reg_recorded()
  return reg == '' and '' or ('@' .. reg)
end, { expr = true })

Under the new EDITOR > NEW FEATURES section, multicursor is also toggled by <C-LeftMouse> and q= (follow mode), cleared with CTRL-L, restored with gQ, and [count]Q places a cursor at every search match.

Where

  • Q is not mapped anywhere in this repo (grep -rn '"Q"' across lua/ and init.lua returns nothing), so Nvim's builtin default applies directly — this config gets the new multicursor behavior for free (and loses old-style macro replay) the moment it runs on Nvim 0.13.
  • No conflicts with existing keymaps: sneaks.vim (plugin_config.lua) owns f/F/t/T, mini.move uses Alt+hjkl, <leader> is space — Q, q=, CTRL-L, gQ are all free.

Why it matters

Q replaying the last recorded macro (qa...q, then Q to repeat) is long-standing, widely-used vim muscle memory. This is a silent, judgment-call behavior change: some workflows benefit from native multicursor (no plugin needed — mini.nvim doesn't currently provide multicursor and no [idea] issue asks for one), others will be surprised their Q macro-repeat habit stopped working.

This is a genuine nightly-only change (0.13 unreleased, tracked at neovim/neovim#41449) — worth a decision now so it isn't a surprise on upgrade, consistent with how #330 already tracks the sibling :restart behavior change from the same release cycle.

Recommended action

Pick one (both are one-line additions to lua/config/options.lua, near the other single-key remaps like H/L):

  1. Keep old Q macro-replay behavior — add the snippet from the news entry above.
  2. Embrace native multicursor — no code needed, just be aware Q / q= / CTRL-L / gQ / [count]Q now exist and update the -- usage tips comment block in init.lua (around line 126, next to the existing vim-motion tips) so the behavior isn't a surprise.
  3. Do both — remap Q back to macro-replay and pick a different mnemonic for multicursor toggle.

No action needed until upgrading past 0.12.5 to a 0.13 nightly/release.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions