macvim-dev / macvim-dev/macvim
GUI keyboard repeat rate suffers with many long lines
Nobody has claimed this yet.
- Dominant language
- Vim Script
- Stars
- 7.9k
- Forks
- 691
- PR merge metrics
- No merged PRs in 30d
Description
Steps to reproduce
- Open MacVim (
mvim --clean) - Create a line 80 characters long (
80ii<Esc>) - Go to beginning of line (
0) - Hold down 'l' and time how long it takes to get to the end of the line (for me, about 3 seconds)
- Delete this line (
dd) - Create a line 700 characters long (
700ii<Esc>) - Make 90 copies of this line (
yy90p) - Go to column one, row one (
1G0) - Hold down
land time how long it takes to get to column 80 (for me, about 6 seconds)
(This affects insert repeat rate as well as cursor motion.)
(Also, I don't think this was a problem before the recent update to 9.0, but I could be wrong.)
Expected behaviour
The repeat rate shouldn't be affected by the data in the buffer.
Version of Vim and architecture
VIM - Vi IMproved 9.0 (2022 Jun 28, compiled Jul 25 2022 08:23:03) macOS version - x86_64 Included patches: 1-65
Environment
MacOS 11.6.4
MacVim GUI
How MacVim was installed
Internal update; originally installed from download
Logs and stack traces
No response
Vim configuration where issue is reproducable
No response
Issue has been tested with given configuration
- by running MacVim.app from GUI macOS interface
- by running vim/gvim/etc installed by MacVim
- by running other versions of vim (e.g. /usr/bin/vim)
Issue has been tested with no configuration
- by running
mvim --clean(orgvim, supplied by MacVim distribution) - by running
vim --clean(in terminal, supplied by MacVim distribution) - by running
vim --clean(in terminal, other suppliers, e.g. /usr/bin/vim)
Other conditions
- The both Homebrew packages "vim" and "macvim" are installed
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the slowdown in MacVim with mvim --clean, using the short and repeated long-line steps from the report, and compare GUI behavior with the listed clean terminal Vim runs. Trace the GUI keyboard-repeat and cursor-motion path; done means repeat speed no longer depends on buffer contents for the reported cases.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- macos, vim
- Domain
- desktop, performance
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100