1
0
mirror of https://github.com/chylex/IntelliJ-IdeaVim.git synced 2024-11-23 11:42:45 +01:00
Commit Graph

1467 Commits

Author SHA1 Message Date
Tuomas Tynkkynen
6b5216077b Add few simple mark tests. 2014-12-12 23:05:28 +02:00
Tuomas Tynkkynen
7e119f7963 Add tests for change number operations (<C-A>, <C-X>) 2014-12-12 23:05:28 +02:00
Tuomas Tynkkynen
933cbc7e51 Add unit tests for some replace commands
Adds tests for: |r|, |s|, |R|, and <Ins> in insert mode.
2014-12-12 23:05:28 +02:00
Tuomas Tynkkynen
65f30d4480 Add testcase for '>' in visual block mode 2014-12-12 23:05:28 +02:00
Tuomas Tynkkynen
1f8d3f119e Add unit tests for Ex ranges
Adds tests for ranges in Ex commands. Almost every kind of range has
basic tests, except the following are still totally untested:
    - \/, \?, \&
    - register ranges
    - syntax errors in ranges
2014-12-12 23:05:28 +02:00
Tuomas Tynkkynen
45fe858503 Add tests for case changing operations
Add tests for the following commands:
- gu, gU, g~ in normal mode
- u, U, ~ in visual mode
2014-12-12 23:05:28 +02:00
Tuomas Tynkkynen
0cc06ad186 Move ChangeActionTest.doTest() to VimTestCase.
This method is convenient in other tests as well.
2014-12-12 23:05:28 +02:00
Tuomas Tynkkynen
18cd7547ad VIM-210 Fix focus issues with the Ex panel
Previously, if the editor window had been splitted, under certain
conditions some actions related to the Ex panel would cause the editor
focus to change to a different split.

The required conditions for this bug to occur:
    - no docked windows (like the Project sidebar) are open
    - 'View -> Navigation bar' is disabled

At least these actions triggered the bug:
    - search with /
    - successfully executing an Ex command
    - dismissing the Ex window with Esc
    - Ex commands that opened the output panel (e.g. :!)

All the deleted lines of the form
    FileEditorManager.getInstance(project).openFile(vf, true);
seem to be very old, non-functional workarounds for the focus issue.
2014-12-09 13:36:03 +02:00
Tuomas Tynkkynen
7746a26062 VIM-855 Fix regexp character class bugs
Previously strchr and istrchr didn't consider NUL chars as end-of-string
terminators. This caused problems in regexps using character classes:
a regexp like "[^a]bc" would be effectively treated as "[^abc]bc" - i.e.
some literal characters from the rest of the pattern would accidentally be
included in the character class.
2014-12-09 01:01:53 +02:00
Andrey Vlasovskikh
a47fc9d3be Don't share editor data contexts
The previous code threw "cannot share data context between Swing events"
throwables from DataManagerImpl$MyDataContext.getData since we used to
share DataContext objects passed to
VimShortcutKeyAction.actionPerformed() and
VimTypedActionHandler.execute() inside AnActionEvent objects with
runnables we invoked via SwingUtilities.invokeLater().
2014-12-07 18:40:51 +03:00
Andrey Vlasovskikh
8fdf75330c Updated changelog 2014-12-07 16:43:52 +03:00
Andrey Vlasovskikh
d6ebaa26b0 Merge branch 'invoke-shortcuts-handler-later' 2014-12-07 16:42:31 +03:00
Andrey Vlasovskikh
27bd7ec836 Merge remote-tracking branch 'dezgeg/fixes/misc-issues' 2014-12-07 16:28:15 +03:00
Andrey Vlasovskikh
6752058922 Version 0.39 2014-12-03 16:07:30 +03:00
Andrey Vlasovskikh
b965108dad Updated changelog 2014-12-03 16:06:20 +03:00
Andrey Vlasovskikh
6bf0f36567 Merge remote-tracking branch 'dezgeg/fixes/vim-702-fix-substitute-infinite-loop' 2014-12-03 15:59:43 +03:00
Andrey Vlasovskikh
69f1a70968 VIM-848 Show line numbers if they are enabled in the settings and there is no 'set number' 2014-12-03 15:42:59 +03:00
Tuomas Tynkkynen
47edfcac5e VIM-702 Fix infinite loop on s/$/\r/g
If the replacement contains newlines, the line number of the current
search position needs to be adjusted. Without this, e.g. s/$/\r/g would
get into an infinite loop.
2014-12-03 14:00:31 +02:00
Andrey Vlasovskikh
c34599b954 Updated the changelog 2014-12-01 16:03:12 +03:00
Andrey Vlasovskikh
48b371c985 Don't show line numbers in non-file editors 2014-12-01 15:54:48 +03:00
Andrey Vlasovskikh
47165e7b9d EA-63002 Don't update line numbers in the caret movement event listener
This update may require moving the caret.
2014-12-01 15:54:31 +03:00
Andrey Vlasovskikh
69f4611552 Version 0.38 2014-12-01 14:01:25 +03:00
Andrey Vlasovskikh
31a25449a8 Updated the changelist 2014-12-01 13:59:34 +03:00
Andrey Vlasovskikh
26a247c0bf Revert "Unified tests initialization for IntelliJ 13+ Community and Ultimate"
This reverts commit 296ef1bdf9.
2014-11-28 22:29:15 +03:00
Andrey Vlasovskikh
1c7cd23475 Updated IntelliJ version 2014-11-28 21:44:37 +03:00
Andrey Vlasovskikh
296ef1bdf9 Unified tests initialization for IntelliJ 13+ Community and Ultimate 2014-11-28 20:22:43 +03:00
Andrey Vlasovskikh
f2a0408801 VIM-586 Try to invoke Vim shortcuts handler later to restore input events sequence 2014-11-27 15:09:06 +03:00
Andrey Vlasovskikh
642659bc9b VIM-410 Use the standard editor line numbers for supporting 'nu'
Annotations-based line numbers reset all other annotations on caret
move, so the results of VCS annotate are reset all the time. It is
necessary for 'rnu', but for 'nu' we can use standard editor line
numbers and preserve the ability to show VCS annotations during caret
movement operations.
2014-11-26 19:49:09 +03:00
Andrey Vlasovskikh
f0e8d065b7 Merge remote-tracking branch 'dezgeg/fixes/vim-723-paste-wrong-line' 2014-11-26 18:18:54 +03:00
Andrey Vlasovskikh
520d852c04 Merge remote-tracking branch 'dezgeg/fixes/vim-771-repeated-semicolon' 2014-11-26 18:12:14 +03:00
Andrey Vlasovskikh
8d4d7a421a Merge remote-tracking branch 'dezgeg/fixes/crashes' 2014-11-26 17:58:27 +03:00
Andrey Vlasovskikh
802b83b0fe VIM-818 Enable key repeat on Mac OS X every time it gets reset by the OS 2014-11-26 17:21:18 +03:00
Tuomas Tynkkynen
7ccb6c8411 Optimize character case changing operations
Previously, performing e.g. visual '~' on a large file would completely
lock up the IDE. The culprit seemed to be the calls to replaceText() one
character at a time, which is not a cheap operation since each
replaceText() will for example trigger a DocumentChanged event.
2014-11-22 13:15:15 +02:00
Tuomas Tynkkynen
1518831f37 Add some missing key names. 2014-11-22 13:15:15 +02:00
Tuomas Tynkkynen
3bdfaa02e1 'J' shouldn't add whitespace if there is trailing whitespace 2014-11-22 13:15:11 +02:00
Tuomas Tynkkynen
e8de9f915c Make '>' not add trailing whitespace to empty lines. 2014-11-22 13:14:23 +02:00
Tuomas Tynkkynen
31f598d1e1 VIM-723 Fix pasting to an empty line
When pasting on an empty line, the pasted text would go to the start of
next line instead.
2014-11-17 03:47:50 +02:00
Tuomas Tynkkynen
46e6fd0847 VIM-771 Fix semicolon repeat for 'till char' motion
Based on empirical testing with Vim, ';' should work like this:
assuming "<caret>1:a 2:b 3:c" with ':' as the last f/t character:

- "t:" does nothing
- ";"  cursor goes to '2'
- "2;" cursor goes to '2', same as the previous
- "3;" cursor goes to '3'
2014-11-16 18:58:56 +02:00
Tuomas Tynkkynen
1441a60f4b Fix AIOOBE when '(' motion goes past start of file
If first character of the file is a newline, then findSentenceEnd()
could return -2 when the 'previous sentence' motion is performed,
leading to an eventual crash. Found by fuzzing.
2014-11-16 17:08:47 +02:00
Tuomas Tynkkynen
ebdf107946 Fix AIOOBE crash when using 'b' on first line
If 'b' were used on the first word of the file, and the word was
preceded by whitespace, ArrayIndexOutOfBoundsException would occur.
Found by fuzzing.
2014-11-16 17:08:47 +02:00
Tuomas Tynkkynen
38d672c9f9 Fix KeyHandler crash when using '<' or '>'
The '<' and '>' commands weren't marked with FLAG_OP_PEND even though
they should, which sometimes caused EmptyStackException in KeyHandler
(when typing <I<><I<> for example). Found by fuzzing.
2014-11-16 17:08:46 +02:00
Tuomas Tynkkynen
75d34abd45 Fix IOOBE when 'i)' motion doesn't find other delimiter
Found by fuzzing.
2014-11-16 17:08:43 +02:00
Andrey Vlasovskikh
1d98738e4d Updated the changelog 2014-11-15 00:11:35 +03:00
Andrey Vlasovskikh
3cfa0e1844 Merge remote-tracking branch 'dezgeg/fixes/vim-515-cW-command' 2014-11-15 00:09:00 +03:00
Andrey Vlasovskikh
82211a4373 Updated the changelog 2014-11-15 00:08:32 +03:00
Andrey Vlasovskikh
e324b04a94 Added Tuomas Tynkkynen to the list of contributors 2014-11-15 00:02:09 +03:00
Andrey Vlasovskikh
49d0c51d97 Merge branch 'vim-536-cc-second-to-last-line' 2014-11-15 00:00:43 +03:00
Andrey Vlasovskikh
fe4bc3b4a9 Moved line line position calculation before deletion 2014-11-15 00:00:13 +03:00
Tuomas Tynkkynen
58d964063c VIM-515 Fix cW command detecting end-of-word incorrectly
A cW command on text like 'x$$$$' or '$xxxx' would incorrectly delete
just the first character, and not the rest.
2014-11-14 22:51:46 +02:00
Andrey Vlasovskikh
17d3e37e1d Merge branch 'vim-567-run-external-command-in-window' 2014-11-14 23:43:42 +03:00