Commit Graph

181 Commits

Author SHA1 Message Date
Björn Linse
43823acae2 ui: rename ext_newgrid to ext_linegrid 2018-10-01 21:24:15 +02:00
Björn Linse
4da5cb38d3 startup: always wait for UI with --embed, unless --headless also is supplied 2018-09-22 10:18:28 +02:00
Justin M. Keyes
608ff261ad test: API validation: assert exact string
expect_err() matches against a pattern. Terminate the pattern with "$"
to check against buffer overrun.

ref #8931
2018-09-05 08:04:15 +02:00
Justin M. Keyes
db17d2c0fa API: Avoid overrun when formatting error-message
msgpack_rpc_to_object (called by handle_request .. msgpack_rpc_to_array)
always NUL-terminates API Strings.
But handle_request .. msgpack_rpc_get_handler_for operates on a raw
msgpack_object, before preparation.
2018-09-05 08:04:15 +02:00
Daniel Hahler
643ef257b3 API: nvim_unsubscribe(): Handle unknown events #8745
close #8745
2018-08-28 10:20:19 +02:00
Peter Hodge
b53b621ef6 functests: tests related to operations on unloaded buffers #7688 2018-07-25 15:07:13 +10:00
Björn Linse
1adb01c120 ui: use line-based rather than char-based updates in screen.c
Add ext_newgrid and ext_hlstate extensions. These use predefined
highlights and line-segment based updates, for efficiency and
simplicity.. The ext_hlstate extension in addition allows semantic
identification of builtin and syntax highlights.

Reimplement the old char-based updates in the remote UI layer, for
compatibility. For the moment, this is still the default. The bulitin
TUI uses the new line-based protocol.

cmdline uses curwin cursor position when ext_cmdline is active.
2018-07-21 13:21:58 +02:00
Jan Edmund Lazo
175297a23a tests: <SNR> is represented as 'R' (ASCII) 2018-07-12 20:26:54 -04:00
Justin M. Keyes
f65a751d82 test: nvim_buf_attach: reduce delay
This test is mostly a demo/reference for:
https://github.com/neovim/neovim/issues/8634#issuecomment-400940467
so let's not pay a 1s penalty.
2018-07-02 20:47:28 +02:00
Justin M. Keyes
b4fcf02316 test: nvim_buf_attach response after initial delay
ref #8634
2018-07-01 17:31:58 +02:00
Justin M. Keyes
60ef7889a2 test: buffer_updates: 10s timeout 2018-07-01 17:31:00 +02:00
KillTheMule
40911e435e API: emit nvim_buf_lines_event from :terminal #8616
closes #8575
2018-07-01 14:42:56 +02:00
David Hotham
1cbc830189 API: nvim_win_set_cursor: set curswant #8613
Fixes #8591
2018-06-25 02:14:55 +02:00
Justin M. Keyes
f85cbea725 Merge #7917 'API: buffer updates' 2018-06-08 10:13:04 +02:00
Justin M. Keyes
3abf17ae88
API: validation: mention invalid method name (#8489) 2018-06-07 10:56:44 +02:00
Björn Linse
5be3865ce7 nvim_list_uis: include channel id 2018-06-01 10:20:13 +02:00
KillTheMule
333679ad0e Add empty options dict to buf_attach 2018-05-23 22:07:27 +02:00
KillTheMule
65e7f6f0b9 Rename some more, fixe borked renaming 2018-05-23 22:07:27 +02:00
KillTheMule
0bee3925ab Send changedtick as first event if buffer contents weren't requested 2018-05-23 22:07:27 +02:00
KillTheMule
ad151847f1 Unify updates_start and updates to lines_event
Also rename changedtick -> changedtick_event
2018-05-23 22:07:27 +02:00
KillTheMule
3866137eed Update test 2018-05-23 22:07:27 +02:00
KillTheMule
e7451f8a91 Some renamings and doc changes 2018-05-23 22:07:27 +02:00
KillTheMule
de5d1e863c Try fixing that test on travis 2018-05-23 22:07:27 +02:00
KillTheMule
5aa8af7cdb Increase sendkeys timeout 2018-05-23 22:07:27 +02:00
KillTheMule
6bdcbef2f5 The grand renaming 2018-05-23 22:07:27 +02:00
KillTheMule
ec215a1962 Fix tests on windows
`cat` is distributed with neovim, so when can use it everywhere, as
opposed to `sort`.

The diffget test fails for unknown reasons on appveyor, mark it pending
for now.
2018-05-23 22:07:27 +02:00
KillTheMule
0476e0aef3 Make LiveUpdate return lastline instead of numreplaced
In analogy to `nvim_buf_set_lines`.
2018-05-23 22:07:27 +02:00
KillTheMule
37b8e95fd6 Lint 2018-05-23 22:07:27 +02:00
KillTheMule
8bcc011959 Make separate functions to start/stop live updates 2018-05-23 22:07:27 +02:00
KillTheMule
bafae1c427 Add argument to not send a buffers content when updates are enabled
Add a test.
2018-05-23 22:07:27 +02:00
Peter Hodge
79184809bb Tests for buffer updates
Originally written by @phodge in
https://github.com/neovim/neovim/pull/5269.
2018-05-23 22:07:27 +02:00
Björn Linse
6da4548f0e api: list information about all channels/jobs.
Fire autocmd when channel opens or its info changes.
Add a way for API clients can describe themselves.
2018-05-23 18:18:16 +02:00
Justin M. Keyes
137eedb4ed API: nvim_get_commands(): return Dictionary 2018-05-12 07:29:21 +02:00
Justin M. Keyes
cb6672853a API: nvim_get_commands(): builtin is irrelevant for buffer-local
builtin commands are never buffer-local, so we can return empty for that
case.
2018-05-12 07:29:21 +02:00
Justin M. Keyes
738bffea2c API: nvim_get_commands(): more attributes
Support more :command attributes:
  -bang
  -bar
  -register
2018-05-11 13:50:00 +02:00
Justin M. Keyes
9fa7727ce0 API: nvim_get_commands(): always return keys
- Always return all keys, with at least NIL value.
- Require `opts` param to be {"builtin":false}
- Validate `opts` param
2018-05-11 13:20:43 +02:00
Nimit Bhardwaj
25b6304840 API: nvim_get_commands() 2018-05-11 13:20:19 +02:00
Justin M. Keyes
273d2cd5d5 Merge #8329 'API: Make nvim_set_option() update :verbose set …' 2018-05-11 10:08:09 +02:00
Justin M. Keyes
79a0d82755 test: API: fix tests after improved error capture 2018-05-10 04:01:25 +02:00
Justin M. Keyes
2326a4ac3a API: nvim_eval(): return non-generic VimL errors
Use the same pattern as nvim_call_function (_call_function).
2018-05-09 23:18:39 +02:00
Justin M. Keyes
c9f3174075 API: return non-generic VimL errors
- Return VimL errors instead of generic errors for:
  - nvim_call_function
  - nvim_call_dict_function
- Fix tests which were silently broken before this change.

This violates #6150 where we agreed not to translate API errors.  But
that can be fixed later.
2018-05-09 23:18:38 +02:00
Justin M. Keyes
cabffb0182 API: nvim_call_dict_function: expect actual function, not name 2018-05-06 14:52:21 +02:00
Justin M. Keyes
fe7ab60af7 API: nvim_call_dict_function: eliminate internal param
The `internal` param is difficult to explain, and will rarely be
anything but `true`.  To avoid it, use a hack: check if the resolved
dict value starts with "function(".
2018-05-06 14:38:26 +02:00
Justin M. Keyes
19c2ce1901 refactor: nvim_call_dict_function
- Add test coverage for errors.
- Rename, rearrange.
2018-05-06 14:38:26 +02:00
Sebastian Witte
124275dd58 API: nvim_call_dict_function #3032 2018-05-06 14:38:26 +02:00
Justin M. Keyes
f46f138fb6 test: nvim_call_function: verify "too many arguments" error 2018-05-06 14:38:26 +02:00
b-r-o-c-k
7170de1971 api: Make nvim_set_option() update :verbose set ...
Make `:verbose set ...` show when an option was last modified by an
API client or Lua script/chunk. In the case of an API client, the
channel ID is displayed.
2018-05-03 21:05:20 -05:00
Justin M. Keyes
1c3a849881
API/nvim_command_output: handle :echon capture (#8265)
ref https://github.com/neovim/python-client/pull/290
2018-04-13 00:49:37 +02:00
Justin M. Keyes
87f4d2592c
test/util: expect_err() (#8257)
other cleanup, ref #8245
2018-04-11 22:07:00 +02:00
Justin M. Keyes
fa6415f13f
test/API: validate channel arg (#8245) 2018-04-08 03:01:15 +02:00