Maxime Coste
f9d3b0f671
Add select display columns test
2019-11-13 20:13:49 +11:00
Jason Felice
e712138ebd
Fix test suite freeze
...
The issue is that the `test/regression/2056-assert-on-small-window`
sent JSON UI input without waiting for for the JSON UI to be
initialized.
Closes #3196
2019-11-12 09:39:37 -05:00
Maxime Coste
7a8f57f97b
Add support for a -codepoint switch to the select command
2019-11-12 21:21:24 +11:00
Jason Felice
5fae16faef
Implement %val{selections_char_desc}
...
Fixes #3194
2019-11-12 20:54:32 +11:00
Jan-Jaap Korpershoek
fcc8ed5df3
[html] Fix indentation when entering a newline while in the middle of a tag
...
Example:
```
<tag>|</tag>
```
Then press enter
Old behaviour:
```
<tag>
</tag>
```
New behaviour:
```
<tag>
</tag>
```
I also added a test for it
2019-11-03 12:25:02 +01:00
Jason Felice
e888f4341c
test: Allow expect-style UI tests, testing any var
2019-10-13 14:57:24 -04:00
Jason Felice
2b1ca43328
test: Clear socket correctly when XDG_RUNTIME_DIR is set
2019-10-13 14:56:55 -04:00
Maxime Coste
f1047181cb
Fallback to wrapping in between 'word' when 'WORD' fails
...
First try to break at a whitespace, if that fails (likely because
that last WORD is too long for the wrapping width), then try to
wrap at a 'word' boundary (on a non alphanumeric character).
Fixes #3048
2019-08-12 18:40:56 +10:00
Maxime Coste
1c6aa9baed
Fix bug in WrapHighlighter::do_compute_display_setup
...
Additional lines were not pulled correctly when a line was removed
due to its wrapping hiding the cursor.
Fixes #2999
2019-08-05 20:16:59 +10:00
Maxime Coste
e840140b38
Add indent tests for brace after else indent
2019-07-25 17:27:08 +10:00
Maxime Coste
e42c81c8eb
Ensure current context switches away from buffer on delete-buffer
...
Fixes #3025
2019-07-22 20:26:39 +10:00
Maxime Coste
be3d0f8b33
Filter non-extra_word_chars completion candidates using Codepoints
...
Fixes #3010
2019-07-09 19:36:57 +10:00
Maxime Coste
9363f98f5b
Fix indent/sh/deindent-after-esac test case
2019-07-01 22:04:04 +10:00
Maxime Coste
5c219cc743
Merge remote-tracking branch 'sjjf/sh_indent_v2'
2019-07-01 22:00:31 +10:00
Simon Fowler
c5dd013235
Add tests.
...
Probably overkill, but at least this is comprehensive . . .
2019-06-30 12:57:59 +10:00
Maxime Coste
e4d6bff5ec
Fix quoting of tuple options
...
Fixes #2990
2019-06-27 22:42:12 +10:00
Maxime Coste
c9858bb6d1
Fix tests with new opt-in quoting
2019-06-23 12:04:21 +10:00
Dmitry Matveyev
01159a9e72
Add support for autoformatting after do keyword in Ruby
2019-06-12 09:03:24 +03:00
Maxime Coste
1ebea85e6f
Do not merge selections on backspace in insert mode
...
Fixes #2861
2019-05-29 23:12:04 +10:00
Maxime Coste
91386a535c
Support discarding selections in exec/eval -itersel
...
Only fail if all selections are discarded.
Fixes #2841
2019-05-13 17:34:43 +10:00
Maxime Coste
229768841b
Fix parsing of faces with a base but no attributes
2019-04-28 00:35:52 +01:00
Maxime Coste
1c8f1cbc2f
Fix wrapping of words with 'wrap col - indent < word len < wrap col'
...
Add a test case for those, and refactor bits of the wrap highlighter.
This explains part of the needed complexity in #2820 .
2019-04-24 11:40:57 +01:00
Maxime Coste
4e24ba86cc
Change faces alias to be a base that can be modified
...
Using <fg>,<bg>+<attr>@<base> will apply the given fg color,
bg color and attributes on top of base dynamically. Simply giving
<base> is a shorthand for default,default@<base>.
Inspired by the discussion in #2862
2019-04-23 23:15:23 +01:00
Alex Leferry 2
d1ae1cf971
Replace egrep with grep
2019-04-17 14:49:59 +02:00
Maxime Coste
6b79c1e000
Support named captures in hooks
...
Fixes #2857
2019-04-15 23:56:49 +10:00
Maxime Coste
41f19f8dc9
Add support for %file{...} expansions
...
This should make the use case exposed in #2836 implementable.
2019-04-07 09:43:40 +10:00
Maxime Coste
744778be30
Add a -to-file <filename> switch to the echo command
...
As discussed in #2836
2019-04-07 09:32:17 +10:00
Maxime Coste
baae0c899b
Add -timestamp switch support to the select command
...
Fixes #2829
2019-04-01 22:11:18 +11:00
Grant Moyer
d8e4c6801f
Fix autoindent issues with paren in literal
2019-03-31 00:07:12 -04:00
Maxime Coste
2c283d46a5
Merge remote-tracking branch 'GrantMoyer/rust-block-indent'
2019-03-29 20:12:34 +11:00
Grant Moyer
71c5077bec
Block indent on newline when previous line is '(stuff' and move 'stuff' to own line
...
Also, align closing paren on own line with opening paren
2019-03-28 13:17:57 -04:00
Grant Moyer
61840c8b11
Preserve tabs during autoindent and alignment with '(' for c-family languages
...
Also add test for tab preservation during c-family autoindentation, and correct alignment of '}' with opening of block in cases of wrap between '(' and ')' in c-family languages
2019-03-28 13:08:02 -04:00
Maxime Coste
b531bab1ce
Add support for -shell-script-* completion in :prompt
...
Fixes #2754
2019-03-24 19:28:46 +11:00
Alex Leferry 2
c0dccdd90d
Add categories in rc/
...
Closes #2783
2019-03-21 01:06:16 +01:00
Alex Leferry 2
25630f4c91
Refactor colorize function away from the test script
2019-03-12 23:22:03 +01:00
Maxime Coste
4843149b6a
Make error description available as "%val{error}" during catch blocks
...
Fixes #2761
2019-03-05 20:46:23 +11:00
Maxime Coste
f9d421130f
Fix use of invalidated iterators in highlight_range
...
Fixes #2755
2019-03-05 20:31:40 +11:00
Maxime Coste
bb2aa86388
Merge remote-tracking branch 'stevenyvr987/update-test/README.asciidoc'
2019-02-17 11:21:41 +11:00
Maxime Coste
a61b6d7649
Add a test case for WinDisplay segfault
...
Fixes #2737
2019-02-17 11:21:26 +11:00
Dimitri Merejkowsky
0b9164e7bc
Fix wording used in test runner
2019-02-17 11:21:26 +11:00
Steven Chan
fe0c357b66
Include more details in test/README.asciidoc
...
Define the role and content of each test file.
Further changes to test/README.asciidoc
2019-02-15 11:45:06 -08:00
Steven Chan
56bc1750cc
Include more details in test/README.asciidoc
...
Define the role and content of each test file.
2019-02-12 13:00:35 -08:00
Justin Frank
58c15b0240
Indent and deindent c-family single line else properly
2019-02-08 15:16:29 -08:00
Maxime Coste
5c0175d90a
Remove peephole regex optimization pass
...
The current implementation is wrong as it crosses basic blocks
boundaries. Doing basic block decomposition of regex is probably
a tad too complex for this single optimization.
Fixes #2711
2019-02-04 22:10:19 +11:00
Maxime Coste
370d10ccc7
Always select inserted text after piping
...
Relying on general selection update code is error prone due to
diffing.
Fixes #2394
2019-01-23 20:14:08 +11:00
Maxime Coste
0600724a8b
Improve some corner cases in c-family auto-indenting
2019-01-14 23:42:57 +11:00
Maxime Coste
328c497be2
Add support for named captures to the regex impl and regex highlighter
...
ECMAScript is adding support for it, and it is a pretty isolated
change to do.
Fixes #2293
2019-01-03 22:55:50 +11:00
Maxime Coste
0e1e0fc57b
Improve deindent behaviour with mixed indent
2018-12-13 17:35:16 +11:00
Maxime Coste
1875ff51a0
Gather the list of hooks to run before running the parent
...
This will prevent hooks added by the parent hook manager to be
gathered, as was decided during the discussion for #2603
2018-12-09 10:07:40 +11:00
Maxime Coste
16908bf091
Fix hooks triggering on unset-option even if parent has same value
2018-11-28 21:45:40 +11:00
Maxime Coste
c6d6060502
Add a test case for dropping full whitespace selections on trim
2018-11-27 21:05:35 +11:00
Maxime Coste
1553d91d27
Make '_' the default extra_word_chars, and remove built-in support
...
Fixes #2599
2018-11-27 18:16:21 +11:00
Maxime Coste
31d3cef093
Merge remote-tracking branch 'lenormf/rename-auto_complete'
2018-11-25 23:01:02 +11:00
Maxime Coste
b9ca3ee6dc
Fix column highlighter adding display atoms past the window width
2018-11-14 17:47:11 +11:00
Delapouite
c08ec08513
test: add end-extending-parent/braces for }B}B - Ref #2479
2018-10-27 13:49:45 -04:00
Maxime Coste
a383ce3045
Fix LineRangeSet::udpate not updating some traling ranges correctly
...
Fixes #2499
2018-10-21 11:49:30 +11:00
Maxime Coste
da13b5f814
Fix handling of capture matching in region highlighter
...
Also extend the highlight/regions test to validate that.
Thanks to lenormf for reviewing my change and finding this bug.
2018-10-15 21:21:12 +11:00
Maxime Coste
ed84a2d60c
Buffer begin and end are not end-of-words
...
Buffer begin never has a word character before, and end is always
preceeded by an end-of-line.
Fixes #2420
2018-10-08 12:40:52 +11:00
Justin Frank
ab6bc41358
Added shell command completion support to define-command and prompt
...
This commit also introduces a regression in that I decided that the best way to
avoid overly long and confusing names was to rename the current shell-*
switches to script-*, and have the shell command completion be
shell-completion.
renamed script-{completion,candidates} to shell-script-*
Updated docs with new switch names
Added -shell-completion switch to x11-repl and kitty-repl
2018-10-03 09:46:31 -07:00
Olivier Perret
93f913705a
Misc fixes
2018-09-24 09:54:21 +02:00
Maxime Coste
cb8b882878
Fix broken test after change in cursor faces
2018-09-24 08:15:12 +10:00
Maxime Coste
1631a7d8d9
Replace the Exclusive
face attribute with Final
...
Final is more granular, it consists of FinalFg (f), FinalBg (g)
and FinalAttr (a) which control if a face's fg, bg, or attributes
fully overwrite the previous face (instead of merging) and if
following faces apply on top of this face or not.
Fixes #2388 if the Whitespace face has the FinalFg flag.
2018-09-23 23:27:14 +10:00
Maxime Coste
c8fd1e1cf6
Merge remote-tracking branch 'laelath/c-indent-edits'
2018-09-13 20:42:04 +10:00
Justin Frank
de839d14c4
added test for deindentation
2018-09-12 12:25:36 -07:00
Maxime Coste
0c3d9ccd20
Change remove-hooks to take a regular expression
...
All hooks whose group match this regex will be removed.
Fixes #2380 .
2018-09-12 21:26:21 +10:00
Maxime Coste
8536adc5ac
Merge remote-tracking branch 'eraserhd/2367-surround-with-tight-nesting'
2018-09-12 20:57:59 +10:00
Maxime Coste
d3be78cca2
Only commit undo groups when buffer was modified
...
This fixes an interaction with kak-lsp that would trigger undo group
commit when setting a buffer option value.
2018-09-12 20:02:57 +10:00
Jason Felice
83244af106
Don't skip opening brace twice when finding closing
...
Fixes #2367
Fixes #2129
2018-09-09 10:15:41 -04:00
Maxime Coste
bd34d007d7
Fix tests with new shell escaping syntax
2018-08-29 12:36:40 +10:00
Maxime Coste
68aba9e353
Use shell specific quoting for env vars
...
Add a test case to validate roundtrips between Kakoune and the
shell.
2018-08-29 07:53:59 +10:00
Maxime Coste
293610a432
Add a test case for -once hooks and code style tweaks
2018-08-16 21:09:51 +10:00
Frank LENORMAND
0b8899d1d4
src: Rename auto_complete
to autocomplete
...
Removing the underscore seems to make the option name more
in line with the others (even though some do use a separator,
e.g. `disabled_hooks`).
2018-07-19 18:57:33 +03:00
Maxime Coste
d23ac09fc1
Add support for <a-;> in prompt mode
...
Fixes #2096
Closes #2060
2018-07-15 11:17:16 +10:00
Maxime Coste
bde726d034
Change autoshowcompl to auto_complete with insert|prompt possible values
2018-07-15 11:10:32 +10:00
Maxime Coste
79ec8d0010
Rename highlighters that used an underscore to use a dash
...
For example `show_matching` is now `show-matching`.
2018-07-08 19:14:15 +10:00
Maxime Coste
f0b3925ba7
Merge remote-tracking branch 'maximbaz/improve-comment-line'
2018-07-07 09:39:46 +10:00
Maxime Coste
63d4c8c311
Change a
on end of line behaviour to be consistent
...
`a` will just jump on next line, `a` on last end of line opens a new
line beneath it.
Fixes #1164
2018-07-05 08:00:14 +10:00
Maxime Coste
2e0e206951
Make recurse regex opt-in with a -recurse switch instead of opt-out
2018-07-05 07:54:28 +10:00
Maxime Coste
63d7984b89
Fix bug in recursive region highlighting
2018-07-05 07:54:28 +10:00
Maxime Coste
f61bcef469
Fix tests and required scripts to get back to green make test
2018-07-05 07:54:28 +10:00
Maxime Coste
124a5d4905
Tolerate restoring invalid coordinates from register
...
Clamp those selection after updating them to the current timestamp
Fixes #2078
2018-07-05 07:54:28 +10:00
Maxime Coste
183f32803b
Fix selection save/restore from registers post selection list syntax change
2018-07-05 07:54:28 +10:00
Maxime Coste
9387abed81
tests: Update selections files to match the new selection list syntax
2018-07-05 07:54:28 +10:00
Maxime Coste
55f857dd2b
Fix extra-word-chars test post list option refactoring
2018-07-05 07:54:28 +10:00
Maxime Coste
b5dd9f4094
test/run: Fix script post hook behaviour change
2018-07-05 07:54:28 +10:00
Maxim Baz
ba547ea4dd
Make tests a bit more interesting
2018-07-03 22:32:04 +02:00
Maxim Baz
8a1b557b5f
Add test to ensure whitespaces are preserved after uncomment
2018-06-29 00:10:21 +02:00
Maxim Baz
5d689858df
Improve comment-line command
2018-06-28 23:47:48 +02:00
Maxime Coste
43b72770ec
Fix wrong logic for moving filedescriptors leading to closed stdin
...
With this fix, tests can now use /dev/null as stdin.
Fixes #2165
2018-06-28 22:56:50 +10:00
dahlbaek
28637cec9e
Use egrep instead of grep for ERE
...
Some implementations of grep do not support extended regular
expressions (ERE). Using egrep instead seems to be more portable.
2018-06-22 20:35:36 +02:00
Maxime Coste
667777521b
Refactor the way main selection is determined after rotating contents
...
Fixes #2133
2018-06-21 08:07:17 +10:00
Maxime Coste
6dca67c674
Fix two <s-tab> requiered to access last completion in prompt
...
A single <s-tab> should be enough.
2018-06-19 07:40:52 +10:00
Maxime Coste
9b89652b0b
Fix potential assert on itersel selection restoration
...
We cannot guarantee after an itersel that selections are going to
still be in ascending order, but we were calling a SelectionList
constructor that was assuming this was the case.
2018-05-24 08:08:51 +10:00
Maxime Coste
878d2a4bdb
Add regression test for crash on BufSetOption hook
2018-05-21 20:36:25 +10:00
Maxime Coste
8c6af54db3
c-family.kak: Fix comment line continuation behaviour
...
Fixes #2043
2018-05-19 14:15:16 +10:00
Maxime Coste
c9a8658671
Fix assert with window small enough so that no part of buffer is displayed
...
Fixes #2056
2018-05-19 14:15:16 +10:00
Maxime Coste
a64afd7f1a
test/run: Support a "ui-in" file containing json-rpc messages
...
With this "ui-in", tests can execute json-rpc commands from the UI
at startup to set a specific UI state.
2018-05-19 14:15:16 +10:00
Maxime Coste
851494a374
test/run: Rename "display" expected ui output file as "ui-out"
2018-05-19 14:15:16 +10:00
Maxime Coste
148d6c205b
Fix wrong behaviour in select surrounding
...
Fixes #2030
2018-05-07 22:17:57 +10:00
Maxime Coste
e4f90e5ed2
Fix tests after changes to json_ui output
2018-04-29 23:06:24 +10:00