Commit Graph
10448 Commits
Author SHA1 Message Date
claude[bot]andClaude Opus 5 3ffad30aa0 Prepare What's New for the upcoming release
The tbr page was still a byte-for-byte copy of the 2.45.0 release notes,
so its content is replaced with the features and fixes currently under
To Be Released: the YankRing extension, modeless selection, the
current-search-match highlight, :stopinsert, command-line sethandler and
the macOS key repeat setting, plus the polish & fixes list.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-18 08:59:45 +02:00
claude[bot]andClaude Opus 5 e8d698fd7b Update changelog: reformat-on-paste, NL in commands, :normal in autocmd
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-18 05:27:03 +00:00
1grzyb1 e66a3915a9 Put caret at end of line when pasting without reformat 2026-08-17 11:28:27 +02:00
1grzyb1 5415080cf0 Restore mode from normal command after autocmd 2026-08-17 11:28:27 +02:00
1grzyb1 e53149ab16 VIM-2536 NL characters in commands
normal lost the newline and everything after it when the argument came from an :execute string (:exe "normal! iX\<CR>Y" typed only X), because \<CR> was parsed into a line feed instead of a carriage return and a line feed ends the ex command line; fixed by making \<CR> produce 0x0D, recognising <NL> as the <C-J> key, and having :execute hand line feeds to the parser as carriage returns for commands like :normal that take the rest of the line.
2026-08-17 10:12:14 +02:00
1grzyb1 9ab5026633 VIM-2370 respect none reformat option when pasting 2026-08-17 09:16:01 +02:00
claude[bot]andClaude Opus 5 7662fdf3d0 Update changelog: backspace in Replace mode
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-15 05:22:29 +00:00
1grzyb1 1e3fa122f2 VIM-2074 Fix backspace in replace mode
We didn't take into account appended and overwrote charachters in replace mode. Due to that we didn't correctly restored charachtes when backspacing
2026-08-14 12:56:20 +02:00
claude[bot]andClaude Opus 5 96a98e1d35 Update changelog: :stopinsert command
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-14 05:47:25 +00:00
1grzyb1 dd4d9b5a8a publish whatsnew pages on gh pages 2026-08-13 10:16:34 +02:00
1grzyb1 4e86a2d10b VIM-4307 Don't use table everywhere in settings tables
With VimEverywhere enabled, TableEverywhere left its navigation shortcuts registered on a table while focus moved into that table's own cell editor, so shifted keys such as `G` and `$` were consumed as selectLastRow/selectLastColumn instead of being typed (e.g. the Name field of the Environment Variables dialog) - the dispatcher now stands down whenever a cell editor is active, and leaving a table always unregisters the shortcuts and restores `autoStartsEdit`
2026-08-13 09:53:45 +02:00
1grzyb1 37ae9735e9 VIM-1565 implement stopinsert command
stopinsert leaves insert mode. usefull in addition to autocmd
2026-08-13 08:42:19 +02:00
claude[bot]andClaude Opus 5 76f125d6a4 Update changelog: linewise paste overwriting the * register during reindent
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-13 05:49:30 +00:00
dependabot[bot] 017254780d Bump org.junit.jupiter:junit-jupiter from 6.1.2 to 6.1.3
Bumps [org.junit.jupiter:junit-jupiter](https://github.com/junit-team/junit-framework) from 6.1.2 to 6.1.3.
- [Release notes](https://github.com/junit-team/junit-framework/releases)
- [Commits](https://github.com/junit-team/junit-framework/compare/r6.1.2...r6.1.3)

---
updated-dependencies:
- dependency-name: org.junit.jupiter:junit-jupiter
  dependency-version: 6.1.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-08-12 15:41:24 +00:00
dependabot[bot] 702d9bb519 Bump com.dorongold.task-tree from 4.0.1 to 4.0.2
Bumps com.dorongold.task-tree from 4.0.1 to 4.0.2.

---
updated-dependencies:
- dependency-name: com.dorongold.task-tree
  dependency-version: 4.0.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-08-12 15:41:06 +00:00
dependabot[bot] c66b380c4d Bump org.junit:junit-bom from 6.1.2 to 6.1.3
Bumps [org.junit:junit-bom](https://github.com/junit-team/junit-framework) from 6.1.2 to 6.1.3.
- [Release notes](https://github.com/junit-team/junit-framework/releases)
- [Commits](https://github.com/junit-team/junit-framework/compare/r6.1.2...r6.1.3)

---
updated-dependencies:
- dependency-name: org.junit:junit-bom
  dependency-version: 6.1.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-08-12 15:41:04 +00:00
dependabot[bot] 240e1367e5 Bump com.google.devtools.ksp:symbol-processing-api from 2.3.10 to 2.3.11
Bumps [com.google.devtools.ksp:symbol-processing-api](https://github.com/google/ksp) from 2.3.10 to 2.3.11.
- [Release notes](https://github.com/google/ksp/releases)
- [Commits](https://github.com/google/ksp/compare/2.3.10...2.3.11)

---
updated-dependencies:
- dependency-name: com.google.devtools.ksp:symbol-processing-api
  dependency-version: 2.3.11
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-08-12 15:40:12 +00:00
grzybek 71f7e2d3ea VIM-4272 Don't update systemSelection during indent
when we selected text during indentation after paste it selected part of text which in combination with unnamed resulted in duplicated/broken paste
2026-08-12 10:01:52 +02:00
claude[bot]andClaude Opus 5 163f695a5d Update changelog: register type recovery for stripped PRIMARY
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-12 05:48:19 +00:00
grzybek 6e7a45a9e0 VIM-4272 recover the register type when PRIMARY comes back stripped
When the selection is no longer ours but still holds our text minus the tail something reformatted away, the type now comes from what we published instead of being guessed from the text.
2026-08-11 12:21:42 +02:00
1grzyb1 580b504b8c Publish eap every 2 weeks
We want to pubilsh eap more often to gather feedback before publishing release
2026-08-11 11:10:53 +02:00
claude[bot]andClaude Opus 5 403ef65417 Update changelog: linewise yank in the * register on Linux
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-11 05:40:53 +00:00
grzybek 181f5681db VIM-4272 use published PRIMARY content when we own the selection
On Linux with clipboard=unnamed the `*` register is backed by the system PRIMARY selection, which stores text only, so its type was re-guessed from the text on every read. The selection can come back with trailing whitespace stripped, so a line-wise "foo   \n" reads back as "foo" and gets downgraded to character-wise. We now reuse the text and type we published while we still own the selection, and only read and guess once another app claims it.
2026-08-10 11:07:16 +02:00
claude[bot]andClaude Opus 5 28080122cd Update changelog: current search match highlight, macOS key repeat setting
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-08 05:35:13 +00:00
1grzyb1 30aad65713 Run output panel assertions on EDT
There might be race condition where other thread was removing views underneath so it's safer to make those assertions on EDT
2026-08-07 12:44:09 +02:00
1grzyb1 f00a11c448 VIM-893 Allow to change key repeat in settings
We didn't allow to change keyrepeat on macos after initial set on startup
2026-08-07 10:44:49 +02:00
1grzyb1 c00d9b89ff VIM-2694 different current highlight from hlsearch
we need to style highlight from incsearch set on currently selected match to distinguish them from all highlights made by hlsearch
2026-08-07 10:19:27 +02:00
claude[bot]andClaude Opus 5 d041d28069 Update changelog: modeless selection for the 'mouse' option
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-07 05:47:57 +00:00
1grzyb1 d74857ebf6 VIM-4275 implement modeless selection for the 'mouse' option
'mouse' should stop Vim from interpreting the mouse rather than disable the mouse, so we now consume only the plain left-button press over text. the platform's single hook for suppressing caret placement - and build Vim's modeless selection ourselves, leaving the context menu, gutter clicks and modifier gestures
  to the IDE
2026-08-06 11:29:48 +02:00
1grzyb1 5bd9613d03 VIM-301 Document yank ring extension 2026-08-06 08:36:23 +02:00
claude[bot]andClaude Opus 5 9687d86a22 Update changelog: YankRing extension, motion and regex fixes
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-06 06:19:26 +00:00
dependabot[bot] e77c78327b Bump io.ktor:ktor-serialization-kotlinx-json from 3.5.1 to 3.5.2
Bumps [io.ktor:ktor-serialization-kotlinx-json](https://github.com/ktorio/ktor) from 3.5.1 to 3.5.2.
- [Release notes](https://github.com/ktorio/ktor/releases)
- [Changelog](https://github.com/ktorio/ktor/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ktorio/ktor/compare/3.5.1...3.5.2)

---
updated-dependencies:
- dependency-name: io.ktor:ktor-serialization-kotlinx-json
  dependency-version: 3.5.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-08-05 15:40:06 +00:00
Alex Plate c95d6fc065 Fix(VIM-4292): apply the motion range adjustments to operatorfunc too
MotionGroup.getMotionRange2 is a copy of VimMotionGroupBase.getMotionRange
that OperatorAction uses for g@, so every operatorfunc based operator - the
Commentary and Surround extensions, and any <Plug> operator - missed the two
range fixes of this branch. `gc}` commented one line more than `d}` deleted,
and `g@w` on the last character of the file did nothing.

Port the ':help exclusive' end adjustment and the end of file clamp, and
cover both with tests that exercise g@.

Also fixes the count for the inner quote text objects: Vim guards the
adjustment with "count < 2" in current_quote(), so any count of 2 or more
includes the quotes, not just exactly 2 (VIM-4163).
2026-08-05 16:28:35 +03:00
Alex Plate bf0cc381fe Fix(VIM-4163): support the count of 2 for the inner quote text objects
:help v_iquote - "Special case: With a count of 2 the quotes are included,
but no extra white space as with a"/a'/a`".

The count was passed to the text object handlers and then dropped, so `2i"`
behaved exactly like `i"` and left the quotes behind.
2026-08-05 16:28:35 +03:00
Alex Plate 93aba9b5b6 Fix(VIM-2878): support the n flag of substitute
:help :s_flags - "n: Report the number of matches, do not actually
substitute". The flag was accepted and then ignored, so `:%s/a/b/n`
performed the substitution instead of counting.

The matches are counted the same way that they would be substituted, so
without the 'g' flag only the first match of each line counts, and the 'c'
flag is ignored.
2026-08-05 16:28:35 +03:00
Alex Plate 428d104670 Fix(VIM-4300): reuse the last pattern for a substitute with a backslash delimiter
The undocumented vi feature that the code already describes - ":s\/sub/"
and ":s\?sub?" reuse the last search pattern, ":s\&sub&" reuses the last
substitute pattern - never worked. The branch that parses the backslash
delimiter left the pattern as the empty string instead of clearing it, so
the block that reuses the last pattern was skipped and the empty string was
compiled as a regex, failing with E383.

The two error messages of that block were also the wrong way round: a
missing search pattern is E35 and a missing substitute pattern is E33, as
they already are in Address.
2026-08-05 16:28:35 +03:00
Alex Plate f54fc1efaa Fix(VIM-4298): try every way a look behind can match
A look behind matches when its pattern ends exactly where the look behind
started. The simulation of the assertion returned as soon as it reached the
accept state, and the caller then compared that one result against the
current index, so the alternatives that were still on the stack were thrown
away.

With `\%(a\|ab\)\@<=c` on "abc" the shorter alternative was found first,
ended at the wrong index, and the whole start position was rejected, so the
positive assertion did not match and the negative one wrongly did.

The simulation now takes an optional target index. Reaching the accept state
at another index no longer stops it, so every way the pattern can match is
tried. Only the look behind passes a target index, so nothing else changes.
2026-08-05 16:28:35 +03:00
Alex Plate fc0a878ed4 Fix(VIM-4296): undo the captures of a branch that the regex engine backtracks out of
The backtracking simulation applied the captures of every state it visited
directly to the shared capture group collection and never undid them, so
what a failed branch captured leaked into the branch that did match.

For \zs, that moved the start of the match: `a\zsc\|ab` matched "b" instead
of "ab", because the first branch set the start of the match before failing.

Fix(VIM-4297): the same leak through \ze force ended the match. `a\zec\|ab`
matched "a" instead of "ab", because the force ended flag of the failed
branch made the end capture of the matching branch be ignored.

The capture group collection can now take and restore a snapshot of itself,
and counts its own changes. Each frame of the simulation stack remembers
that count, and every capture pushes a snapshot, so popping a frame can undo
everything that the branches explored since have captured. The stack is
shared with the nested simulations of assertions, and an assertion that does
not contribute to the match undoes its captures too.
2026-08-05 16:28:35 +03:00
Alex Plate a6e50b4fc3 Fix(VIM-4299): ignoring case should not apply to a character class
Vim applies 'ignorecase' and \c to the individual characters and to the
ranges of a collection, but never to a character class, so \c[[:upper:]]
does not match a lowercase character.

The matcher tested the class against both the lowercase and the uppercase
variant of the character, which made \c[[:upper:]] match every letter.
2026-08-05 16:28:34 +03:00
Alex Plate 9247c3d5ee Fix(VIM-4295): a" should treat a tab as trailing white space
:help aquote - any trailing white space is included, unless there is none,
then leading white space is included. Vim's in_quote uses vim_iswhite, which
matches a space or a tab, but IdeaVim only looked for a space.

With a tab after the closing quote, `da"` found no trailing white space and
fell back to including the leading space, deleting the wrong text.

Char.isWhitespace() is deliberately not used, because it also matches a new
line, which would let the scan leave the line.
2026-08-05 16:28:34 +03:00
Alex Plate 174891852c Fix(VIM-4294): sentence motion should not stop on the phantom last line
For a file that ends with a new line, the IDE shows an extra empty last
line. Vim has no such line - the new line is just the last line's EOL.

findSentenceStart() treated that line as a paragraph boundary and returned
its offset, which is the size of the file, so `)` on the last sentence put
the caret on a position that does not exist in Vim, and `d)` deleted the
trailing new line along with the sentence.

Clamp the paragraph offset to the last character of the file. The clamp is
applied in findSentenceStart() rather than in findNextParagraph(), because
findSentenceEnd() relies on comparing its result against the file size when
the last sentence has no terminating punctuation.
2026-08-05 16:28:34 +03:00
Alex Plate 15c2f2ed86 Fix(VIM-4291): classify characters above Latin-1 by character class
'iskeyword' only applies to Latin-1 characters. Vim classifies everything
above with a fixed table of character classes and treats a character as a
word character when its class is greater than punctuation (vim_iswordc_buf
and utf_class_buf in mbyte.c).

IdeaVim treated every character above U+00FF as a keyword character, so word
motions never stopped at non-ASCII punctuation: `w` on "foo—bar" skipped the
whole run, and `2e` on "です。next" jumped past the ideographic full stop.

Port Vim's table of blank and punctuation intervals. 'isfname' keeps
treating every multibyte character as a filename character, which is what
vim_isfilec does.
2026-08-05 16:28:34 +03:00
Alex Plate 5febc337f9 Fix(VIM-4290): apply a pending operator when a word motion fails at the end of the file
Vim's forward word motions fail at the end of the file, but `nv_wordcmd`
only reports the failure when no operator is pending. With an operator, the
operator is applied from the caret to the end of the file, so `dw` on the
last character of the file deletes that character.

IdeaVim returned Motion.Error in both cases, and getMotionRange() aborted
the operator, so `dw`, `dW` and `de` on the last character of the file did
nothing at all.

Forward word motions now opt in to clamping the failed motion to the end of
the file, which getMotionRange() (only ever called with a pending operator)
applies. Plain `w` in normal mode still beeps, and the backward motions `b`,
`ge` and `gE` are unchanged - Vim beeps for those even with an operator.
2026-08-05 16:28:34 +03:00
Alex Plate 1dcd4394e7 Fix(VIM-4292): apply Vim's exclusive motion adjustment for an end in column 1
:help exclusive - when an exclusive motion ends in column 1, its end moves
to the end of the previous line and the motion becomes inclusive. Only the
second half of the rule (the motion becomes linewise when the start is at or
before the first non-blank) was implemented, in the delete and yank
operators.

Without the first half, d} from the middle of a paragraph deleted the new
line of the last line of the paragraph too, merging away the blank line that
separates the paragraphs, and y} yanked a trailing new line that Vim does
not yank.

The operators recognise the linewise half of the rule by the end of the
range being in column 1, so the end is only adjusted when the start is not
in the indent, which is exactly when Vim makes the motion inclusive instead
of linewise.

Backward motions are left alone. Vim opts the affected ones out explicitly,
e.g. <BS> and h wrapping to the previous line set CA_NO_ADJ_OP_END.
2026-08-05 16:28:33 +03:00
Alex Plate eed1805e57 Fix(VIM-4293): y} and d} at the first character of the file should be linewise
anyNonWhitespace() coerced the end of its backward scan to 0, so at offset 0
the range 0..0 inspected the character *under* the caret instead of being
empty. The caller then believed there was non-blank text before the range
start and skipped Vim's charwise-to-linewise promotion for exclusive
motions, but only at the very first character of the file.

Dropping the coercion leaves an empty 0..-1 range, matching what already
happens at every other line-start offset.
2026-08-05 16:28:33 +03:00
Alex Plate c9bc8b31dc Fix(VIM-4289): WORD motions should not split at script boundaries
A WORD is a sequence of non-blank characters, separated with white space
(:help WORD). Vim's cls() returns the same class for every non-blank
character when cls_bigword is set, so a change of Unicode script must not
end a WORD.

charType() consulted the Hiragana/Katakana/CJK Unicode blocks before the
punctuationAsLetters (bigWord) flag, so W, E, B and dW stopped at the
boundary between scripts: E on "abcあいう def" landed on 'c' instead of 'う'.

Short-circuit on punctuationAsLetters before the script checks. The script
classes still apply to small-word motions, which is where they belong.
2026-08-05 15:58:01 +03:00
1grzyb1 26ec5a57a0 VIM-301 disable yank ring 2026-08-05 12:36:37 +02:00
1grzyb1 78a44b5aee VIM-301 Configure max history 2026-08-05 12:36:37 +02:00
1grzyb1 a305e9cc09 VIM-301 Include all paste commands 2026-08-05 12:36:37 +02:00
1grzyb1 65db163134 VIM-301 Add YRReplace command 2026-08-05 12:36:37 +02:00