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

8221 Commits

Author SHA1 Message Date
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
Matt Ellis
3b96e2eacd Add trigonometric and hyperbolic builtin functions 2025-02-20 19:21:31 +02:00
Matt Ellis
ffdd6716f5 Refactor some moved tests 2025-02-20 19:21:31 +02:00
Matt Ellis
4453862ea0 Extract function tests 2025-02-20 19:21:31 +02:00
Matt Ellis
c631d0738e Group function handlers like in Vim help
See `:help function-list`
2025-02-20 19:21:31 +02:00
Matt Ellis
1bd7a7596b Support binary numbers in vimscript
Also supports octal with an `0o` or `0O` prefix.
2025-02-20 19:21:31 +02:00
Matt Ellis
23329cc522 Add bitwise functions 2025-02-20 19:21:31 +02:00
Alex Plate
be86dc3c78
Rename VimNoWriteActionTestCase to IdeaVimTestCase 2025-02-20 19:15:43 +02:00
Alex Plate
d65a219194
Mark VimTestCase as deprecated 2025-02-20 19:13:39 +02:00
Alex Plate
e18035b729
Migrate java tests to VimNoWriteActionTestCase 2025-02-20 18:57:52 +02:00
Alex Plate
96a1456dcd
Remove the hack for yaml plugin 2025-02-19 16:48:12 +02:00
Alex Plate
83b92d84a6
Disable IdeaVim listeners in places where IdeaVim is disabled
This is needed for the new terminal. Before this change, it was impossible to put the caret at the line end, even taking the fact the IdeaVim is disabled in the new terminal.
2025-02-14 17:59:06 +02:00
Alex Plate
693bb50d5e
Do add a yaml module only for the latest snapshot 2025-02-14 17:58:01 +02:00