Commit Graph

9160 Commits

Author SHA1 Message Date
Justin M. Keyes
5ae6849517 paste: phases, dots
- Send `phase` parameter to the paste handler.
- Redraw at intervals and when paste terminates.
- Show "..." throbber during paste to indicate activity.
2019-08-27 21:19:10 +02:00
Justin M. Keyes
93e5f0235b API: nvim_put: "follow" parameter 2019-08-27 21:19:10 +02:00
Justin M. Keyes
613296936b API: nvim_put: always PUT_CURSEND
Fixes strange behavior where sometimes the buffer contents of a series
of paste chunks (vim._paste) would be out-of-order.

Now the tui_spec.lua screen-tests are much more reliable. But they still
sometimes fail because of off-by-one cursor (caused by "typeahead race"
resulting in wrong mode; fixed later in this patch-series).
2019-08-27 21:19:10 +02:00
Justin M. Keyes
517bf99ddb API: nvim_put: Avoid "N more lines" message 2019-08-27 21:19:10 +02:00
Justin M. Keyes
0221a9220a paste: edge-case: handle EOL at end-of-buffer
This is "readfile()-style", see also ":help channel-lines".
2019-08-27 21:19:10 +02:00
Justin M. Keyes
5a2894d677 paste: use nvim_put() 2019-08-27 21:19:10 +02:00
Justin M. Keyes
e1177be363 API: nvim_put #6819 2019-08-27 21:19:10 +02:00
Björn Linse
9e25a36467 API: nvim_put #6819: try to fix Insert, Visual 2019-08-27 21:19:10 +02:00
Björn Linse
4cc56905cb API: nvim_put #6819 2019-08-27 21:19:10 +02:00
Justin M. Keyes
f99caa755c paste: use chansend() in Terminal-mode 2019-08-27 21:19:10 +02:00
Justin M. Keyes
abd55be19a paste: fixup tests 2019-08-27 21:19:10 +02:00
Justin M. Keyes
4389401a7c paste: abort paste if handler does not return true 2019-08-27 21:19:10 +02:00
Justin M. Keyes
68ea9a7c8a TUI/paste: always flush on paste mode-change
Flush input before entering, not only when leaving, paste mode. Else
there could be pending input which will erroneously be sent to the paste
handler.
2019-08-27 21:19:10 +02:00
Justin M. Keyes
6d277f43a2 TUI/paste: define paste function as Lua builtin
- Define in Lua so that it is compiled-in (available with `-u NONE`).

TODO: Eventually we will want a 'pastefunc' option or some other way to
override the default paste handler.
2019-08-27 21:19:10 +02:00
Justin M. Keyes
7df566060c lua/stdlib: cleanup 2019-08-27 21:19:10 +02:00
Justin M. Keyes
0a4ef38e43 log: log_key() 2019-08-27 21:19:10 +02:00
Justin M. Keyes
9a92ba88dd TUI/paste: push bytes directly (avoid libtermkey) 2019-08-27 21:19:10 +02:00
ZyX
75663aaf0f TUI/paste: collect data, invoke user callback #4448 2019-08-27 21:19:10 +02:00
Justin M. Keyes
21f0f7bca5 paste: WIP #4448 2019-08-27 21:19:10 +02:00
Jan Edmund Lazo
41ec296640
vim-patch:8.1.1931: syntax test fails
Problem:    Syntax test fails.
Solution:   Add new javascriptreact type to completions.
ea7a08a53e
2019-08-26 19:51:43 -04:00
Jan Edmund Lazo
f667a0e02a
vim-patch:8.1.1930: cannot recognize .jsx and .tsx files
Problem:    Cannot recognize .jsx and .tsx files.
Solution:   Recognize them as javascriptreact and typescriptreact.
            (closes vim/vim#4830)
92852cee3f
2019-08-26 19:51:26 -04:00
Ihor Antonov
f3cb529774 clang/"dereference of null pointer" #10856
In edit.c insert_execute calls ins_compl_addfrommatch
2019-08-26 20:22:39 +02:00
Daniel Hahler
6a21fe9fd1
vim-patch:8.1.1923: some source files are not in a normal encoding (#10852)
Problem:    Some source files are not in a normal encoding.
Solution:   Convert hangulin.c from euc-kr to utf-8 and digraph.c from latin1
            to utf-8. (Daniel Hahler, closes vim/vim#4731)
4119309d70
2019-08-26 12:22:21 +02:00
Daniel Hahler
b069a20910
runnvim.sh: lint (shellcheck) (#10851) 2019-08-26 12:21:53 +02:00
Daniel Hahler
b12b01a828
Merge pull request #10850 from blueyed/option-alias
findoption_len: treat viminfo/viminfofile as aliases
2019-08-26 10:23:12 +02:00
Jan Edmund Lazo
233597152a vim-patch:8.1.1790: :mkvimrc is not tested
Problem:    :mkvimrc is not tested.
Solution:   Add a test.
8750026a7f
2019-08-26 09:39:00 +02:00
Daniel Hahler
b2d6a6891e findoption_len: treat viminfo/viminfofile as aliases
Ref: https://github.com/neovim/neovim/pull/10672#issuecomment-524716824
2019-08-26 09:39:00 +02:00
Jan Edmund Lazo
ebc3070b7d vim-patch:8.1.1926: redraw cursorline after putting line above #10849
Problem:    Cursorline not redrawn when putting a line above the cursor.
Solution:   Redraw when the curor line is below a change. (closes vim/vim#4862)
c2b97643a8
2019-08-26 04:17:34 +02:00
Daniel Hahler
e3e0574cb3
Merge pull request #10841 from janlazo/vim-7.4.1407
vim-patch:7.4.1407,8.1.1111
2019-08-25 21:04:17 +02:00
Daniel Hahler
bec2336231
vim-patch:8.1.1913: not easy to compute the space on the command line (#10845)
Problem:    Not easy to compute the space on the command line.
Solution:   Add v:echospace. (Daniel Hahler, closes vim/vim#4732)
37f4cbd46f
2019-08-25 20:53:17 +02:00
Justin M. Keyes
c8fc285db6
Merge #10840 from janlazo/vim-8.1.1757
vim-patch:8.1.{1757,1924}
2019-08-25 09:13:49 +02:00
Abdelhakeem Osama
2e621553c0 teardown: fix win_free_all() heap-use-after-free #10839
Fixes #10838
2019-08-25 09:11:22 +02:00
Jan Edmund Lazo
66c06dad62
vim-patch:8.1.1924: using empty string for current buffer is unexpected
Problem:    Using empty string for current buffer is unexpected.
Solution:   Make the argument optional for bufname() and bufnr().
a8eee21e75
2019-08-24 21:18:15 -04:00
Jan Edmund Lazo
1dc088ea7d
vim-patch:8.1.1111: it is not easy to check for infinity
Problem:    It is not easy to check for infinity.
Solution:   Add isinf(). (Ozaki Kiichi, closes vim/vim#3787)
fda1bff39f
2019-08-24 17:02:05 -04:00
Jan Edmund Lazo
01b5499eea
vim-patch:7.4.1407
Problem:    json_encode() does not handle NaN and inf properly. (David
            Barnett)
Solution:   For JSON turn them into "null".  For JS use "NaN" and "Infinity".
            Add isnan().
f1b6ac7229
2019-08-24 15:56:17 -04:00
Jan Edmund Lazo
4fedef51b0
vim-patch:8.1.1757: text added with appendbufline() isn't displayed
Problem:    Text added with appendbufline() to another buffer isn't displayed.
Solution:   Update topline. (partly by Christian Brabandt, closes vim/vim#4718)
2984666291
2019-08-24 14:04:20 -04:00
Jan Edmund Lazo
34e4166673 vim-patch:8.0.1236: Mac features are confusing #10837
Problem:    Mac features are confusing.
Solution:   Make feature names more consistent, add "osxdarwin". Rename
            feature flags, cleanup Mac code. (Kazunobu Kuriyama, closes vim/vim#2178)
d057301b1f
2019-08-24 09:04:08 +02:00
Justin M. Keyes
82aaac5baa
Merge #10833 from janlazo/vim-8.1.0037
vim-patch:8.0.1386,8.1.{37,39,187}
2019-08-23 19:39:04 +02:00
Jan Edmund Lazo
2a1887c2df
vim-patch:8.1.0187: getwininfo() and win_screenpos() return different numbers
Problem:    getwininfo() and win_screenpos() return different numbers.
Solution:   Add one to "wincol" and "winrow" from getwininfo().
7132ddc101
2019-08-23 07:46:51 -04:00
Jan Edmund Lazo
c58054c231
vim-patch:8.0.1386: cannot select modified buffers with getbufinfo()
Problem:    Cannot select modified buffers with getbufinfo().
Solution:   Add the "bufmodified" flag. (Yegappan Lakshmanan, closes vim/vim#2431)
8e6a31df81
2019-08-23 07:46:51 -04:00
Jan Edmund Lazo
7e6a2f2bed
vim-patch:8.1.0039: cannot easily delete lines in another buffer
Problem:    Cannot easily delete lines in another buffer.
Solution:   Add deletebufline().
d79a26219d
2019-08-23 07:46:51 -04:00
Jan Edmund Lazo
9358979d09
vim-patch:8.1.0037: cannot easily append lines to another buffer
Problem:    Cannot easily append lines to another buffer.
Solution:   Add appendbufline().
ca851593a6
2019-08-23 07:46:51 -04:00
Justin M. Keyes
79ea7709b7
Merge #9163 'fix crash wiping buffer after getbufinfo()' 2019-08-23 10:31:35 +02:00
Abdelhakeem Osama
c6eb1f42be API: fix nvim_command_output buffer overflow (#10830)
Fixes https://github.com/neovim/neovim/issues/10829.
2019-08-22 10:07:54 +02:00
Jan Edmund Lazo
ed28668392 vim-patch:8.1.1897: may free memory twice when out of memory (#10827)
Problem:    May free memory twice when out of memory.
Solution:   Check that backslash_halve_save() returns a different pointer.
            (Dominique Pelle, closes vim/vim#4847)
f1552d07d7
2019-08-22 06:49:33 +02:00
Daniel Hahler
bb50eadc84
Merge pull request #10815 from blueyed/vim-8.1.1483
vim-patch:8.1.1483: skipped tests are not properly listed
2019-08-22 06:37:05 +02:00
Daniel Hahler
42f492ac99
tui: handle Smulx extension capability (extended underline) (#9097)
This was added to ncurses terminfo for vte and tmux.

Ref: https://github.com/tmux/tmux/issues/1492#issuecomment-427675180

Assumes color support is available when extended underline is supported.

Ref: https://github.com/tmux/tmux/issues/1492#issuecomment-427803984
2019-08-22 06:36:39 +02:00
Daniel Hahler
86d88076ce -u NONE for no syntax highlighting 2019-08-22 05:06:30 +02:00
Daniel Hahler
376d394981 vim-patch:8.1.1893: script to summarize test results can be improved
Problem:    Script to summarize test results can be improved.
Solution:   Use "silent" for substitute to avoid reporting number of matches.
            Remove duplicate "set nocp". (Daniel Hahler, closes vim/vim#4845)
f1e0544d41
2019-08-22 05:06:30 +02:00
Daniel Hahler
356f5fc6e2 vim-patch:8.1.1478: still an error when running tests with the tiny version
Problem:    Still an error when running tests with the tiny version.
Solution:   Do not try reading test.log
18250e291a
2019-08-22 05:06:30 +02:00