1
0
mirror of https://github.com/chylex/IntelliJ-IdeaVim.git synced 2024-12-30 10:42:47 +01:00
Commit Graph

8101 Commits

Author SHA1 Message Date
Alex Plate
035804860c
Fix incorrect configuration in gradle 2024-11-25 15:32:01 +02:00
Alex Plate
0f1a4d523f
Move the docs to the init method of VimExtension 2024-11-25 14:01:23 +02:00
Alex Plate
5f5a97a7e1
Lazily load the logger to avoid injector initialization problems 2024-11-25 13:39:24 +02:00
IdeaVim Bot
03996dce59 Add Julien Phalip to contributors list 2024-11-23 09:03:04 +00:00
filipp
0dd63c7b57 Fix nullable editor in tests 2024-11-22 17:15:07 +02:00
filipp
94d7902ef2 Remove more deprecated methods 2024-11-22 17:15:07 +02:00
filipp
3d08170d54 Post-rebase fixes 2024-11-22 17:15:07 +02:00
filipp
cccb23d9ee Specify which commands perform mode change
We need this for undo subsystem. Mode change is not something that we want to be a separate entity in the undo log

P.S. It's not a full list of such commands, e.g. <ESC> for leaving insert mode is missing. It is because <ESC> may insert some text after visual block mode, I'll figure out a solution for this later
2024-11-22 17:15:07 +02:00
Filipp Vakhitov
eae3fb3ebe Introduce VimKeyBasedUndoService and VimTimestampBasedUndoService
Undo is managed differently in Fleet and IJ Platform, so now we have two different interfaces that are aware of that
2024-11-22 17:15:07 +02:00
Filipp Vakhitov
7f5dce4051 Stop using some deprecated methods 2024-11-22 17:15:07 +02:00
Filipp Vakhitov
25e3988dcf Introduce VimCopiedText class
I don't really like that we have `transferableData: List<Any>`
2024-11-22 17:15:07 +02:00
Filipp Vakhitov
36589c5250 Add context argument in clipboard methods
Alas, adding in just to clipboard was not possible, as there are a lot of depending on methods
2024-11-22 17:15:07 +02:00
Filipp Vakhitov
f1f86b5cd2 Simplify Register class
1. `rawText` vs `text` is confusing and `rawText` was misused, we do not need this field in IdeaVim at all
2. `rawText` and `keys` are the same thing, just parsed. And for some reason, rawText was a nullable field
3. Register is an immutable class now
4. Working with Register class is easier and more compact now
2024-11-22 17:15:07 +02:00
Filipp Vakhitov
628b3ca89f Fix <CR> parsing
It's ^M, not ^J
2024-11-22 17:15:07 +02:00
Filipp Vakhitov
d2b929ddd0 Fix parsing for clipboard option
When I added the selection clipboard, it was confusing to explain to people how this option works and why they should prepend, because the parsing was broken
I've also removed "exclude" part, because it doesn't work in IdeaVim and can confuse people
2024-11-22 17:15:07 +02:00
filipp
43d770ff5a Simplify getTransferableData method signature 2024-11-22 17:15:07 +02:00
Filipp Vakhitov
cde9bc94e6 Fix select mode for immutable caret
Due to implementation details, caret cannot be moved after setting selection
2024-11-22 17:15:07 +02:00
Filipp Vakhitov
63f6e73223 Fix select mode for immutable caret 2024-11-22 17:15:07 +02:00
Filipp Vakhitov
ad28e09fec Move caret when deleting a char
In Fleet deleting text does not move caret, so we add caret moving logic
2024-11-22 17:15:07 +02:00
Filipp Vakhitov
f616f2c3c1 Fix gv in Fleet
Moving caret after setting selection removes the selection
2024-11-22 17:15:07 +02:00
Filipp Vakhitov
66aec26091 Move ColLineFunctionHandler.kt to vim-engine 2024-11-22 17:15:07 +02:00
Filipp Vakhitov
1d59c49b95 Move more logic to vim-engine 2024-11-22 17:15:07 +02:00
Matt Ellis
8da15b8c08 Manually track last selected editor
This is important for initialising options. We can't rely on FileEditorManager.selectedTextEditor, as 2024.2 changed behaviour to reset to null during creation of a new editor. This fixes tests (and option initialisation) for 242.
2024-11-22 17:01:38 +02:00
Matt Ellis
e22c2b6473 Improve updating fallback window option values
The assumption for selection change events is no longer valid in 242, so switch approach to checking when editors are released
2024-11-22 17:01:38 +02:00
Matt Ellis
e293c1b786 Add tests for updating the fallback window 2024-11-22 17:01:38 +02:00
Matt Ellis
468ca840ed Update options tests
Expanded to assert changes on all open windows, and formatted to make it a little easier to read/comprehend what's being tested
2024-11-22 17:01:38 +02:00
Julien Phalip
c75e6756c0 Add some tests for the getcmdtype() function 2024-11-22 16:49:04 +02:00
Julien Phalip
52737c60cf Add JSON entry for getcmdtype function 2024-11-22 16:49:04 +02:00
Julien Phalip
e99c191d49 Add partial support for getcmdtype() function
Tests not included
2024-11-22 16:49:04 +02:00
Julien Phalip
5db2984fdd Add ability to set the highlightedyank foreground color 2024-11-22 15:48:22 +02:00
Alex Plate
365b58eb56
Update build.gradle checker 2024-11-15 20:54:07 +02:00
Alex Plate
b026144254
Add RWLock label to selectionStart & selectionEnd 2024-11-15 20:53:54 +02:00
Alex Plate
0e3cda827c
Fix(VIM-3695): Wrap getting a vimLeadSelectionOffset with a read action 2024-11-15 20:44:00 +02:00
Alex Plate
ed2fe3dcf0
Fix(VIM-3696): Get the state of the selection in read action 2024-11-15 20:34:41 +02:00
Alex Plate
791edbd29b
Restore compatibility with peekaboo plugin
https://plugins.jetbrains.com/plugin/25776-vim-peekaboo
2024-11-13 19:39:24 +02:00
Matt Ellis
4f9d76ef66 Fix memory leak with non-disposed listeners
Fixes VIM-3319
2024-11-13 18:00:47 +02:00
Matt Ellis
4b7381901d Fix bug removing map that is also a prefix 2024-11-13 17:57:31 +02:00
Matt Ellis
6e2cb9ba11 Reorder functions. No logic changes 2024-11-13 17:57:31 +02:00
Matt Ellis
91cd4ab01f Add sequences to iterate keystroke trie
Allows iterating the trie entries without having to create a list or create a list for each entry's keystrokes.
2024-11-13 17:57:31 +02:00
Matt Ellis
34d23180bd Avoid wrapping the keys list for each map attempt 2024-11-13 17:57:31 +02:00
Matt Ellis
fc5aaa50d8 Remove unnecessary hasmapfrom function 2024-11-13 17:57:31 +02:00
Matt Ellis
c7bbfdcaf5 Remove some test only functions 2024-11-13 17:57:31 +02:00
Matt Ellis
562906fe6d Filter map output by prefix
Fixes VIM-2981
2024-11-13 17:57:31 +02:00
Matt Ellis
976771d11a Implement smap and snoremap
Support for sunmap and smapclear already exists, and vmap would introduce a Select mode map.

Fixes VIM-2260
2024-11-13 17:57:31 +02:00
Matt Ellis
5fc4462b03 Support map! to map insert and cmdline modes
Also supports `mapclear!` and `unmap!`

Moves parsing of the bang modifier to the parser so we can tell the difference between `map! foo bar` and `map ! foo bar`
2024-11-13 17:57:31 +02:00
Matt Ellis
5f263e7014 Fix output of maps with same keys in multiple modes
E.g. `map foo bar` and `vmap foo baz` would only output one map for `foo` when calling `:map`. Now it will output all maps that match the ex command's modes. This change also improves the marker characters in the first column of map output.
2024-11-13 17:57:31 +02:00
Matt Ellis
4c899fcc93 Simplify test code 2024-11-13 17:57:31 +02:00
Matt Ellis
2f8fe392af Use KeyStrokeTrie for maps 2024-11-13 17:57:31 +02:00
Matt Ellis
84c7e1159b Introduce KeyStrokeTrie to find commands
Should also restore compatibility with idea-which-key
2024-11-13 17:57:31 +02:00
Matt Ellis
18d6f79796 Add missing C-PageUp/Down shortcuts to switch tab
Fixes VIM-2044
2024-11-13 17:52:28 +02:00