1
0
mirror of https://github.com/chylex/IntelliJ-IdeaVim.git synced 2025-05-09 18:34:06 +02:00
Commit Graph

8233 Commits

Author SHA1 Message Date
Alex Plate
2e8548cb25
Update gradle wrapper 2025-02-24 12:13:26 +02:00
Alex Plate
1d25927676
[TC] Upgrade the version of IJ for some build 2025-02-24 11:16:08 +02:00
Alex Plate
42d80f6866
Add write action in several places 2025-02-21 19:32:47 +02:00
Alex Plate
c9189ed7cb
Commands don't start the read and write actions automatically. See the explanation in the previous commit messages.
Related to the implementation of VIM-3376
2025-02-21 19:11:28 +02:00
Alex Plate
fedefea0aa
Remove the write action in several places 2025-02-21 18:56:52 +02:00
Alex Plate
437fa9a1a0
Remove the root write and read actions
Historically, IdeaVim was starting read or write action based on command type. However, this is incorrect because of several reasons:
- The command of different type may perform a write/read action
- The write lock with a lot of code inside does cause application freezes
- Since a large branching of code happens inside the write action, there is a chance of read action request, resulting in the deadlock

Also, now this prevents from implementing a proper execution of VIM-3376.
2025-02-21 18:44:51 +02:00
Alex Plate
0511ee277f
Remove the requirement for the write action in macros
It's not clear why the write action was needed. Probably, it was a mistake and it supposed to be a check for EDT. However, since the check for EDT exists right in the constructor of the potemkin progress, let's remove it at all.
2025-02-21 17:40:40 +02:00
Alex Plate
0b2bda529f
Upgrade the minimal supported version to 243 2025-02-21 16:59:28 +02:00
Alex Plate
fe91744356
Mention 2024.3.3 in gradle script 2025-02-21 13:40:31 +02:00
Alex Plate
45d92c1981
Use the read action for neovim tests in other place 2025-02-21 13:33:53 +02:00
Alex Plate
58de834832
Use the read action for neovim tests 2025-02-21 13:17:37 +02:00
Alex Plate
8d89847d4b
Add tests for 2024.3.3 2025-02-21 13:15:43 +02:00
Alex Plate
bf78445ac6
Add links to intellij platform community space 2025-02-21 13:11:59 +02:00
Alex Plate
3866565e51
Remove IdeaVimTestCase and replace it with VimTestCase 2025-02-21 13:03:23 +02:00
Alex Plate
564ab7d75e
Remove EDT and write action from the VimTestCase 2025-02-21 09:54:12 +02:00
Matt Ellis
24c0d31f14 Updated comment and defaults for word end action
The `ge` motion incorrectly had `stopAtEmptyLine` set to false, but `ge` always stops at empty lines. This option is only applicable for forward motion, so is ignored by the implementation of `findPreviousWordEndOne`.
2025-02-21 09:53:11 +02:00
Matt Ellis
43a2bd98db Reduce multiple implementations to one 2025-02-21 09:53:11 +02:00
Matt Ellis
c4f56c40fd Rename findWordUnderCursor to findWordObject
Starting to distinguish between the other findWordUnderCursor implementations!
2025-02-21 09:53:11 +02:00
Matt Ellis
1b4b66dbb1 Minor refactoring 2025-02-21 09:53:11 +02:00
Matt Ellis
4787a5e22a Rewrite backwards search for word under cursor 2025-02-21 09:53:11 +02:00
Matt Ellis
d2b85cbb10 Merge inner and outer motion implementations 2025-02-21 09:53:11 +02:00
Matt Ellis
0428c2aeff Rewrite inner motion to match outer motion
The implementations are so similar and can now be refactored/simplified
2025-02-21 09:53:11 +02:00
Matt Ellis
1a8789b50c Rewrite next/previous word motions and objects 2025-02-21 09:53:11 +02:00
Matt Ellis
b5937e885d Rewrite displayLocationInfo to avoid findNextWord
Simplifies and fixes counting words, especially when selection intersects words. Also moves implementation to engine and adds more tests.
2025-02-21 09:53:11 +02:00
Matt Ellis
8eef802ac7 Add notes on possible refactoring 2025-02-21 09:53:11 +02:00
Matt Ellis
cad6afdc9d Rewrite word end motions and word objects 2025-02-21 09:53:11 +02:00
Matt Ellis
54ef691a98 Add tests for outer word motions and blank lines 2025-02-21 09:53:11 +02:00
Matt Ellis
426c2fd006 Handle blank and empty lines for text objects
Fixes VIM-1642
2025-02-21 09:53:11 +02:00
Matt Ellis
f25c56b545 Refactor checks for including following whitespace 2025-02-21 09:53:11 +02:00
Matt Ellis
960eb50d8c Fix incorrectly selected new line char with viw 2025-02-21 09:53:11 +02:00
Matt Ellis
18b4b76ebf Select trailing whitespace with viw
Inner word/WORD motions will select trailing whitespace at the end of a line without wrapping
2025-02-21 09:53:11 +02:00
Matt Ellis
d9e575d4a2 Select leading whitespace with viw
Inner word/WORD motions will select leading whitespace at the start of a line without wrapping
2025-02-21 09:53:11 +02:00
Matt Ellis
1769804c8a Select leading whitespace with vaw
Outer word/WORD motions will select leading whitespace at the start of a line
2025-02-21 09:53:11 +02:00
Matt Ellis
81e094ac8f Select trailing whitespace with vaw
Outer word/WORD motions will select trailing whitespace at the end of a line
2025-02-21 09:53:11 +02:00
Matt Ellis
4240c429ba Select preceding whitespace if no following (vaw)
Outer word/WORD text objects should select following whitespace, unless there isn't any, and then it should select preceding whitespace.
2025-02-21 09:53:11 +02:00
Matt Ellis
76f7d81129 Minor code cleanup. No logic changes 2025-02-21 09:53:11 +02:00
Matt Ellis
2da77f0f11 Add tests for existing word/WORD text objects 2025-02-21 09:53:11 +02:00
Matt Ellis
580764b30c Match empty line as word/WORD
Unless moving to end of word/WORD, in which case, skip all whitespace to get to end of the next set of word/WORD characters.

Fixes VIM-1650
2025-02-21 09:53:11 +02:00
Matt Ellis
afd69eef95 Fix end of file edge case deleting previous word
Adds extra tests to confirm that deleting previous word in Insert mode was already working as expected (relates to VIM-1650)

Also fixes an edge case for a test that was marked as behaving differently to Vim, but was actually showing buggy behaviour due to its unorthodox caret placement. It looked like the caret was placed at the end of the line, but it was actually placed _passed_ the last character in the file. Adding extra text below the caret placement would cause the action to behave as expected, and the test would then match Vim behaviour. However, it is possible to get this caret position in the editor and in Vim, with `virtualedit=onemore`, and the IdeaVim implementation was wrong. The test has been updated to provide the correct scenario, and the implementation has been fixed.
2025-02-21 09:53:11 +02:00
Matt Ellis
be1cc67566 Fix previous word end motion at start of file 2025-02-21 09:53:11 +02:00
Matt Ellis
b534708a99 Rename file to show it contains several actions 2025-02-21 09:53:11 +02:00
Matt Ellis
4bc75e0a9b Add tests for existing word/WORD motion behaviour 2025-02-21 09:53:11 +02:00
Alex Plate
fa4c89e134
Add two more interesting facts to the IdeaVim facts about Vim 2025-02-20 19:27:32 +02:00
Matt Ellis
5740372df9 Add err_teapot function 2025-02-20 19:21:31 +02:00
Matt Ellis
06791b9378 Add float2nr function 2025-02-20 19:21:31 +02:00
Matt Ellis
91e927c913 Add fmod function 2025-02-20 19:21:31 +02:00
Matt Ellis
9a5c558060 Add float classification functions 2025-02-20 19:21:31 +02:00
Matt Ellis
d1127a5238 Add power functions 2025-02-20 19:21:31 +02:00
Matt Ellis
613a8b5792 Add exponential functions 2025-02-20 19:21:31 +02:00
Matt Ellis
6f63371e9b Add rounding functions 2025-02-20 19:21:31 +02:00