Commit Graph

21306 Commits

Author SHA1 Message Date
zeertzjq
6832b626ea vim-patch:8.2.0851: can't distinguish <M-a> from accented "a" in the GUI
Problem:    Can't distinguish <M-a> from accented "a" in the GUI.
Solution:   Use another way to make mapping <C-bslash> work. (closes vim/vim#6163)
f4ae6b245a
2022-04-29 15:51:04 +08:00
zeertzjq
66747f18de vim-patch:8.2.0839: dropping modifier when putting a character back in typeahead
Problem:    Dropping modifier when putting a character back in typeahead.
Solution:   Add modifier to ins_char_typebuf(). (closes vim/vim#6158)
b42c0d5427

Vim's test doesn't seem to work properly as the hit-enter prompt seems
to be delayed. Add a Lua screen test.
2022-04-29 15:51:04 +08:00
zeertzjq
82a13a78bb vim-patch:partial:8.2.0815: maparg() does not provide enough information for mapset()
Problem:    maparg() does not provide enough information for mapset().
Solution:   Add "lhsraw" and "lhsrawalt" items.  Drop "simplified"
9c65253fe7

This only includes the "lhs" value part.
2022-04-29 15:51:04 +08:00
zeertzjq
212349c100 feat(edit): insert an unsimplified key using CTRL-SHIFT-V
This marks the following Vim patches as ported:

vim-patch:8.1.2333: with modifyOtherKeys CTRL-^ doesn't work

Problem:    With modifyOtherKeys CTRL-^ doesn't work.
Solution:   Handle the exception.
828ffd5963

vim-patch:8.1.2350: other text for CTRL-V in Insert mode with modifyOtherKeys

Problem:    Other text for CTRL-V in Insert mode with modifyOtherKeys.
Solution:   Convert the Escape sequence back to key as if modifyOtherKeys is
            not set, and use CTRL-SHIFT-V to get the Escape sequence itself.
            (closes vim/vim#5254)
fc4ea2a72d

vim-patch:8.2.2084: CTRL-V U doesn't work to enter a Unicode character

Problem:    CTRL-V U doesn't work to enter a Unicode character when
            modifyOtherKeys is effective. (Ken Takata)
Solution:   Add a flag to get_literal() for the shift key. (closes vim/vim#7413)
0684e36a7e

Omit getcmdkeycmd() change as it depends on Vim patch 8.2.2062, which
may introduce a potential breakage.
2022-04-29 15:51:03 +08:00
zeertzjq
44269c73a3 vim-patch:8.1.2167: mapping test fails on MS-Windows
Problem:    Mapping test fails on MS-Windows.
Solution:   Remove all the existing Insert-mode mappings.
2559a47823
2022-04-29 15:51:03 +08:00
zeertzjq
b5837e55e6 vim-patch:8.1.2165: mapping test fails on Mac
Problem:    Mapping test fails on Mac.
Solution:   Remove the default Mac mapping.
4f2f61a014
2022-04-29 15:51:03 +08:00
zeertzjq
c3634a0261 vim-patch:8.1.2159: some mappings are listed twice
Problem:    Some mappings are listed twice.
Solution:   Skip mappings duplicated for modifyOtherKeys. (closes vim/vim#5064)
fafb4b18cd
2022-04-29 15:51:03 +08:00
zeertzjq
7029b4b44a feat(input): delay all simplifications
Avoid unsimplfied Ctrl-C in input buffer when it is not mapped.
2022-04-29 15:51:03 +08:00
zeertzjq
68ddbdd03b test(old): revert changes from ed88ca7503
Copy test_regex_char_classes.vim from upstream to avoid future encoding
problems.
2022-04-29 15:51:03 +08:00
zeertzjq
dde4f09f51 vim-patch:8.1.2145: cannot map <C-H> when modifyOtherKeys is enabled
Problem:    Cannot map <C-H> when modifyOtherKeys is enabled.
Solution:   Add the <C-H> mapping twice, both with modifier and as 0x08.  Use
            only the first one when modifyOtherKeys has been detected.
459fd785e4

Add REPTERM_NO_SPECIAL instead of REPTERM_SPECIAL because the meaning of
"special" is different between Vim and Nvim.
Omit seenModifyOtherKeys as Nvim supports attaching multiple UIs.
Omit tests as they send terminal codes.
Keep the behavior of API functions.
2022-04-29 15:51:03 +08:00
Gregory Anders
188537efb3
fix: suppress "is a directory" messages with shortmess 'F' (#18296)
When 'F' is in 'shortmess', don't show messages when editing a
directory. This fixes a regression introduced by 0956283.
2022-04-28 15:27:34 -06:00
Christian Clason
521e91e1c4
vim-patch:ce001a337e28 (#18287)
Update runtime files
ce001a337e

also add `vimStdPlugin` keywords missing from previous updates
2022-04-27 17:48:35 +02:00
bfredl
ee85d8d756
Merge pull request #18254 from dundargoc/refactor/remove-char_u
refactor: replace char_u variables and functions with char
2022-04-27 13:37:56 +02:00
dundargoc
8e20c04fa0
refactor: enable -Wconversion warning for ex_docmd.c (#18277)
* refactor: enable -Wconversion warning for ex_docmd.c

Work on https://github.com/neovim/neovim/issues/567
2022-04-27 13:35:56 +02:00
kylo252
0d41c4dee1
refactor(build): remove unused includes #17078
Remove unused includes in src/nvim/buffer.c|h using the IWYU library.
Yet another step towards #6371 and #549
2022-04-26 21:38:12 -07:00
erw7
5f3018fa1a
refactor(terminal)!: drop winpty, require Windows 10 #18253
Problem:
winpty is only needed for Windows 8.1. Removing it reduces our build and code
complexity.

Solution:
- Remove winpty.
- Require Windows 10.

closes #18252
2022-04-26 21:17:06 -07:00
Andrey Mishchenko
3933592338
fix: has() should preserve v:shell_error #18280
fixes #18278
2022-04-26 20:58:25 -07:00
Philip Linell
d98e5357af
feat(checkhealth): check for slow shell #17829
Problem:
I had some issues where multiple plugins (vim-fzf and fugitive) was slow
because of my `.zshenv`.

Solution:
Check shell performance in :checkhealth.

Co-authored-by: Justin M. Keyes <justinkz@gmail.com>
2022-04-26 20:55:57 -07:00
kylo252
39d149752f
fix(build): missing definitions for sizeof macros #16393
Verified with -Wundef

Fixes #16392
2022-04-26 19:41:11 -07:00
bfredl
f3e99e691d
Merge pull request #18260 from dundargoc/refactor/enable-conversion-warning
refactor: enable -Wconversion warning for funcs.c and userfuncs.c
2022-04-26 19:57:02 +02:00
ii14
55135cea61
fix(lsp): fix unnecessary buffers being added on empty diagnostics (#18275)
Some language servers send empty `textDocument/publishDiagnostics`
messages after indexing the project with URIs corresponding to unopened buffers.
This commit guards against opening buffers corresponding to empty diagnostics.
2022-04-26 10:00:28 -07:00
Dundar Goc
909dbbbd4b refactor: enable -Wconversion warning for funcs.c and userfuncs.c
Work on https://github.com/neovim/neovim/issues/567
2022-04-26 10:43:37 +02:00
zeertzjq
a75efc237d
Merge pull request #18267 from zeertzjq/test-eq-arg-order
test: correct order of arguments to eq() and neq()
2022-04-26 12:20:19 +08:00
zeertzjq
519e4c4472 test: correct order of arguments to eq() and neq() 2022-04-26 11:38:58 +08:00
Gregory Anders
5d159a7faa
feat(tui): query terminal for CSI u support (#18181)
On startup query the terminal for CSI u support and enable it using
the escape sequence from kitty's progressive enhancement protocol [1].

[1]: https://sw.kovidgoyal.net/kitty/keyboard-protocol/
2022-04-25 20:49:45 -06:00
zeertzjq
d7a7315957
Merge pull request #18249 from zeertzjq/vim-8.2.4760
vim-patch:8.2.{4760,4765}: matchfuzzy() limit
2022-04-26 08:38:21 +08:00
zeertzjq
13e54f7130 vim-patch:8.2.4765: function matchfuzzy() sorts too many items
Problem:    Function matchfuzzy() sorts too many items.
Solution:   Only put matches in the array. (Yegappan Lakshmanan,
            closes vim/vim#10208)
047a7019b2
2022-04-26 08:06:33 +08:00
zeertzjq
e6974114fb vim-patch:8.2.4760: using matchfuzzy() on a long list can take a while
Problem:    Using matchfuzzy() on a long list can take a while.
Solution:   Add a limit to the number of matches. (Yasuhiro Matsumoto,
            closes vim/vim#10189)
9029a6e993
2022-04-26 08:06:32 +08:00
Christian Clason
af82eab946
vim-patch:8.2.4826: .cshtml files are not recognized (#18259)
Problem:    .cshtml files are not recognized.
Solution:   Use html filetype for .cshtml files. (Julien Voisin, closes vim/vim#10212)
1f435dafff
2022-04-25 20:02:36 +02:00
bfredl
35aa072647
Merge pull request #18257 from dundargoc/refactor/enable-conversion-warning/tag
refactor: enable Wconversion warning for tag
2022-04-25 18:59:20 +02:00
Dundar Goc
4d092af32d refactor: enable Wconversion warning for tag
Work on https://github.com/neovim/neovim/issues/567
2022-04-25 18:12:27 +02:00
bfredl
f765c30b38
Merge pull request #18255 from bfredl/workaround_version
fix(ci): workaround bug in msgpackparse() on windows caused by api level bump
2022-04-25 17:29:54 +02:00
Gregory Anders
2dddc86a42
fix: show autocmd output when F is in shortmess (#18251)
The default value of including F in 'shortmess' has the unfortunate side
effect of hiding output from autocommands. This is a common source of
confusion and often leads people to think their autocommands are not
working when they are. There is a small snippet in the docs for
'shortmess' indicating that the F flag suppresses autocmd output, but
it's not easy to find if you don't already know to look for it.

This commit removes that behavior of the F flag to make it only suppress
file info when opening a new file.
2022-04-25 08:44:18 -06:00
bfredl
10693a9e8a fix(ci): workaround bug in msgpackparse() on windows caused by api level bump 2022-04-25 16:30:20 +02:00
Dundar Goc
4aae0eebb2 refactor: replace char_u variables and functions with char
Work on https://github.com/neovim/neovim/issues/459
2022-04-25 13:32:01 +02:00
dundargoc
440b65c338
revert: "man.vim: Ensure 'modifiable' in man#init_pager" #17791
This reverts commit 526798a941.

This will make man filetype not modifiable by default, as it is the
superior behavior in my opinion. More importantly, also make it possible
for a user to modify man filetypes by adding `set modifiable` in
`~/.config/nvim/ftplugin/man.vim` or its equivalent.

ref #11450
closes #17595

Co-authored-by: Javier López <graulopezjavier@gmail.com>
2022-04-25 01:57:14 -07:00
zeertzjq
89df042a89
Merge pull request #18234 from zeertzjq/cursearch-reduce-redraw
perf: only redraw for CurSearch when it is currently in use
2022-04-25 10:53:54 +08:00
dundargoc
0648100fed
refactor: convert macros to all-caps (#17895)
Closes https://github.com/neovim/neovim/issues/6297
2022-04-24 20:18:43 -06:00
dundargoc
7813fa2f8c
refactor: enable Wconversion warning for diff (#18094)
Work on https://github.com/neovim/neovim/issues/567
2022-04-24 20:13:59 -06:00
Gregory Anders
cf2d77763f
Merge pull request #18110 from dundargoc/refactor/remove-char_u
refactor: replace char_u variables and functions with char
2022-04-24 20:13:23 -06:00
dundargoc
c582194135
refactor: add pure attribute to pure functions (#18165)
This will allow the compilers that support the pure attribute to make
further optimizations.
2022-04-24 20:12:47 -06:00
zeertzjq
38ee2a41df perf: only redraw for CurSearch when it is currently in use
The check in redraw_for_cursorline() is not needed because VALID_VIRTCOL
is always cleared when the cursor moves to another line, so the check in
redraw_for_cursorcolumn() is enough.
2022-04-25 09:57:26 +08:00
dundargoc
933274c438
fix/PVS #17863
* fix(PVS/V002): disable rule completely

V002: "Some diagnostic messages may contain incorrect line number in
this file." This particular check seems unreliable. It says on their
website https://pvs-studio.com/en/docs/warnings/v002/ that this warning
occurs when there are multiline pragmas, but there are none in
extmark.c.

* fix(PVS/V756): ignore "counter is not used inside a nested loop" warning

The nested loop starts with "AutoCmd *ac = ap->cmds" so "ap" is
definitely used.

* fix(PVS/V560): disable "a part of conditional expression is always true"

* fix(PVS/V614): potentially uninitialized variable 'blen' used
2022-04-24 18:51:22 -07:00
dundargoc
68d27e156c
build: bump Doxyfile to minimum required version 1.9.0 #18118 2022-04-24 18:50:42 -07:00
Joel Bradshaw
b7717ed450
docs: clarify enhanced modifiers, SHIFT usage #18124
Co-authored-by: Justin M. Keyes <justinkz@gmail.com>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
2022-04-24 18:46:56 -07:00
casswedson
ac3794c351
ci: label all markdown edits as "documentation" #18120 2022-04-24 18:40:13 -07:00
sitiom
aede28ab3b
fix(packaging): remove excess forward slash in Wix Patch (#18121) 2022-04-24 17:53:09 -07:00
zeertzjq
4cf1bcf183
Merge pull request #18248 from zeertzjq/vim-8.2.4806
vim-patch:8.2.{4806,4818}: a mapping using <LeftDrag> does not start Select mode
2022-04-25 07:52:35 +08:00
zeertzjq
48a35106ef vim-patch:8.2.4818: no test for what 8.2.4806 fixes
Problem:    No test for what 8.2.4806 fixes.
Solution:   Add a test. (closes vim/vim#10727)
ac92ab7719

Test cannot be used because it must use test_setmouse(). Use a Lua test.
2022-04-25 07:23:24 +08:00
zeertzjq
c8fe8c5ea4 vim-patch:8.2.4806: a mapping using <LeftDrag> does not start Select mode
Problem:    A mapping using <LeftDrag> does not start Select mode.
Solution:   When checking for starting select mode with the mouse also do this
            when there is typeahead. (closes vim/vim#10249)
53ef573148
2022-04-25 07:23:23 +08:00