aboutsummaryrefslogtreecommitdiff
path: root/src
Commit message (Collapse)AuthorAge
...
* | | | | | | | | | | | | | | tui: flush -V3 ('verbose' >= 3) info ASAPJustin M. Keyes2017-12-05
| | | | | | | | | | | | | | |
* | | | | | | | | | | | | | | msg_outtrans_special(): handle NULLJustin M. Keyes2017-12-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is convenient for terminfo_info_msg().
* | | | | | | | | | | | | | | msg_outtrans_special(): `const` some stringsJustin M. Keyes2017-12-05
| | | | | | | | | | | | | | |
* | | | | | | | | | | | | | | str2specialbuf(): fix comparisonJustin M. Keyes2017-12-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | regression by 832c158a663c
* | | | | | | | | | | | | | | tui: set descriptions on termcap extensionsJustin M. Keyes2017-12-05
| | | | | | | | | | | | | | |
* | | | | | | | | | | | | | | tui: dump termcap info if -V3 ('verbose' >= 3)Justin M. Keyes2017-12-05
|/ / / / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Get terminal debugging info by starting Nvim with 'verbose' level 3: nvim -V3log This is like Vim's `:set termcap`, which was removed in Nvim (and would be very awkward to restore because of the decoupled UI).
* | | | | | | | | | | | | | vim-patch:8.0.0306 (#7675)KunMing Xie2017-12-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: mode() not sufficiently tested. Solution: Add more tests. (Yegappan Lakshmanan) https://github.com/vim/vim/commit/e971df39a5aac5d9b7e8033247dc18b12daa0eb8
* | | | | | | | | | | | | | Merge #7672 from ckelsel/vim-8.0.0298Justin M. Keyes2017-12-02
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / / / |/| | | | | | | | | | | | |
| * | | | | | | | | | | | | fix lint errorckelsel2017-12-02
| | | | | | | | | | | | | |
| * | | | | | | | | | | | | vim-patch:8.0.0298ckelsel2017-12-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Ex command range with repeated search does not work. (Bruce DeVisser) Solution: Skip over \/, \? and \&. https://github.com/vim/vim/commit/cbf20fbcd3e9bb006f694bcc35da859930fb12a2
* | | | | | | | | | | | | | vim-patch:8.0.0295 (#7671)KunMing Xie2017-12-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: test_viml hangs. Solution: Put resetting 'more' before sourcing the script. https://github.com/vim/vim/commit/7a073549a3b1e72037a4e98ceb406d057ac9ba50
* | | | | | | | | | | | | | tui.c: request focus-reporting (fix regression) #7670Justin M. Keyes2017-12-02
|/ / / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ref #7649 ref #7664 27f9b1c7b029d8 caused a regression: it uses loop_schedule_deferred() to defer emitting the "enable focus reporting" termcode. tui_main() never processes `tui_loop.events` (which loop_schedule_deferred() depends on), so the event was never actually processed. But fixing that (by processing `tui_loop.events`) would bring back the problem 27f9b1c7b029 tried to fix: it still emits the event too soon. Instead, do a little dance: schedule the event on `main_loop` and then forward it to `tui_loop`. NOTE: after this commit, in tmux 2.3 with `focus-events` enabled, FocusGained is fired on startup and when resuming from suspend. Using `script` to record the terminal session (and `vterm-dump` to post-process the result): BEFORE: {DECSM 1049}{DECSM 1}{ESC =} {CUP *}{ED *}{DECSM 2004}{DECSM 1004}{CSI 1,43 r} {CUP 1,1} {CUP *}{ED *}{SM 34}{DECSM 25} {DECRM 25}{CSI 2 q}{CSI 2 q} {CUP *}{ED *}{LF} {SGR *}{LS1}{SGR 94}~ ... AFTER: {CUP *}{ED *}{CSI 1,43 r} {CUP 1,1} {CUP *}{ED *}{SM 34}{DECSM 25} {DECRM 25}{CSI 2 q}{CSI 2 q} {CUP *}{ED *}{DECSM 2004}{DECSM 1004}{LF} {SGR *}{LS1}{SGR 94}~ ...
* | | | | | | | | | | | | tui: emit some termcodes later (after startup) (#7664)Justin M. Keyes2017-12-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For some reason, enabling focus reporting during terminal setup, causes slow rendering during Nvim startup on tmux 2.3 with the tmux `focus-events` option enabled. To workaround that issue, this commit defers the request. closes #7649 init.vim: call plug#begin('~/.config/nvim/plugged') Plug 'morhetz/gruvbox' call plug#end() set background=light " background light just to see the effect more quickly colorscheme gruvbox .tmux.conf: set -g focus-events on set-option -ga terminal-overrides ",xterm-256color:Tc" set-option -g default-terminal "screen-256color" Using `script` to record the terminal session (and `vterm-dump` to post-process the result): BEFORE this commit: ./build/bin/nvim -u NONE{CR}{LF} {DECSM 1049}{DECSM 1}{ESC =} {CUP *}{ED 2}{DECSM 2004}{DECSM 1004}{CSI 8,44,156 t}{CSI * r} {CUP 1,1} {CUP *}{ED 2}{DECSM 25} {DECRM 25}{CSI 2 q}{CSI 2 q} {CUP *}{ED 2}{LF} {ESC (B}{SGR *}{SGR 94}~ {CR}{LF} ~ {CR}{LF} AFTER this commit: ./build/bin/nvim -u NONE{CR}{LF} {DECSM 1049}{DECSM 1}{ESC =} {CUP *}{ED 2}{CSI 8,44,156 t}{CSI * r} {CUP 1,1} {CUP *}{ED 2}{DECSM 2004}{DECSM 1004}{DECSM 25} {DECRM 25}{CSI 2 q}{CSI 2 q} {CUP *}{ED 2}{LF} {ESC (B}{SGR *}{SGR 94}~ {CR}{LF} ~ {CR}{LF} ...
* | | | | | | | | | | | | tui/rxvt: enable focus-reportingJustin M. Keyes2017-12-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | closes #7578
* | | | | | | | | | | | | version.c: Mark 8.0.0171 as NAJames McCoy2017-11-29
| |_|_|_|_|_|/ / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ci skip]
* | | | | | | | | | | | Revert "tui: update cleared area only if non-default bg"Justin M. Keyes2017-11-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reverts 0b93bab6c22edf7a07cf965ebbbf631b93e1dc1b. This change was counter-productive to the other changes which intended to reduce the role of BCE. ref #7624
* | | | | | | | | | | | Use defined(BSD) check when defining OPEN_CHR_FILESJames McCoy2017-11-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rather than enumerate predefines for all BSD systems, just rely on the fact that they all "#define BSD" in sys/param.h. Debian's GNU/kFreeBSD still requires its own check, since it isn't using the BSD userspace. References: OpenBSD - https://github.com/openbsd/src/blob/210ebf9df0460bbdad02da9bbd5d859b61f57462/sys/sys/param.h#L40 FreeBSD - https://github.com/freebsd/freebsd/blob/f5d95e1f8d32db4ccccfd5ad9cecb21ed07a695d/sys/sys/param.h#L43 NetBSD - https://github.com/NetBSD/src/blob/ea620980793cf2011e5424f4a537b0488e3ffb4d/sys/sys/param.h#L49 DragonFlyBSD - https://github.com/DragonFlyBSD/DragonFlyBSD/blob/94ecf1295bb42b59772448d58ff40dd75c4a3ef8/sys/sys/param.h#L41 vim-patch:8.0.1357
* | | | | | | | | | | | Add OpenBSD as an expected OS for opening char devicesJames McCoy2017-11-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Closes #7542
* | | | | | | | | | | | version.c: mark NA patchesMichael Schupikov2017-11-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - channels: vim-patch:8.0.0018 - GUI: vim-patch:8.0.0021 - Different recursive function implementation: vim-patch:8.0.0141 - JSON handling: vim-patch:8.0.0166, vim-patch:8.0.0169, vim-patch:8.0.0170, vim-patch:8.0.0171, vim-patch:8.0.0180 Mark vim-patch:8.0.0096 applied, since it was added in 860ecd705588470b52094b7036c016b2af15f8c9. [ci skip]
* | | | | | | | | | | | lintJustin M. Keyes2017-11-27
| | | | | | | | | | | |
* | | | | | | | | | | | tui: expose terminal type in 'term' optionJustin M. Keyes2017-11-27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since "builtin" terminfo definitions were implemented (7cbf52db1bdf), the decisions made by tui.c and terminfo.c are more relevant. Exposing that decision in the 'term' option helps with troubleshooting. Also: remove code that allowed setting t_Co. `:set t_Co=…` has never worked; the highlight_spec test asserting that nvim_set_option('t_Co') _does_ work makes no sense, and should not have worked.
* | | | | | | | | | | | Merge #7633 'Retry fgets on EINTR'Justin M. Keyes2017-11-26
|\ \ \ \ \ \ \ \ \ \ \ \ | |_|_|_|_|_|/ / / / / / |/| | | | | | | | | | | closes #7632
| * | | | | | | | | | | io: fix handling EOF in vim_fgetsMatt Widmann2017-11-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If an EOF is returned from `fgets`, `vim_fgets` might spin forever, as it tries to consume the current line. A `NULL` return value from `fgets` should break out of the function (unless `errno` is `EINTR`), and then `feof` should be used to check for the EOF condition on the stream.
| * | | | | | | | | | | io: retry fgets on EINTR (#7632)Matt Widmann2017-11-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The calls to `fgets` in `src/nvim/if_cscope.c` (and elsewhere) can show communication errors to the user if a signal is delivered during its system calls. For plugins that proxy subprocess output into cscope requests, a `SIGCHLD` might *always* interfere with calls into `fgets`. To see this in a debugger, put a breakpoint on `cs_reading_emsg` and watch signals come in (with lldb, using `process handle --notify true --pass true`). Next, run a subcommand from neovim that calls through cscope when it returns. A tag picker plugin, like vim-picker and fzy, with `cscopetag` and `cscopetagorder=0` set, reproduced this reliably. The breakpoint will hit after a `SIGCHLD` is delivered, and `errno` will be set to 4, `EINTR`. The caller of `fgets` should retry when `NULL` is returned with `errno` set to `EINTR`.
* | | | | | | | | | | | Merge pull request #6844 from bfredl/channelBjörn Linse2017-11-26
|\ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | channels: support buffered output and bytes sockets/stdio
| * | | | | | | | | | | | input: only change mode of input fd if there is an input fdBjörn Linse2017-11-25
| | | | | | | | | | | | |
| * | | | | | | | | | | | tui: job-control: use saved termios for pty jobsJustin M. Keyes2017-11-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On startup, if running in a terminal, save the termios properties. Use the saved termios for `:terminal` and `jobstart()` pty jobs. This won't affect nvim spawned outside of a terminal. questions: - This affects `:terminal` and `jobstart({'pty':v:true})`. Should we be more conservative for `jobstart({'pty':v:true})` (e.g. pass NULL to forkpty() and let the OS defaults prevail)? - Note: `iutf8` would not be set in that case.
| * | | | | | | | | | | | channels: improvements to bufferingBjörn Linse2017-11-25
| | | | | | | | | | | | |
| * | | | | | | | | | | | channels: more consistent event handlingBjörn Linse2017-11-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | terminal: libvterm now receives data in async context. This was "almost" safe already, as redraws were queued anyway.
| * | | | | | | | | | | | channels: refactor jobwaitBjörn Linse2017-11-25
| | | | | | | | | | | | |
| * | | | | | | | | | | | channels: reimplement logging (as stub for proper event)Björn Linse2017-11-25
| | | | | | | | | | | | |
| * | | | | | | | | | | | channels: stderr channelBjörn Linse2017-11-25
| | | | | | | | | | | | |
| * | | | | | | | | | | | channels: generalize jobclose()Björn Linse2017-11-25
| | | | | | | | | | | | |
| * | | | | | | | | | | | channels: move away term code from eval.cBjörn Linse2017-11-25
| | | | | | | | | | | | |
| * | | | | | | | | | | | channels: allow bytes sockets and stdio, and buffered bytes outputBjörn Linse2017-11-24
| | | | | | | | | | | | |
| * | | | | | | | | | | | channels: refactorBjörn Linse2017-11-24
| | | | | | | | | | | | |
| * | | | | | | | | | | | Revert channel logging, rebased on new code belowBjörn Linse2017-11-24
| |/ / / / / / / / / / /
* | | | | | | | | | | | :highlight : avoid redraw on errornate2017-11-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | do_highlight() should not redraw if a validation error occurred. closes #7489
* | | | | | | | | | | | tui: update cleared area only if non-default bgJustin M. Keyes2017-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This check was removed in 133ae5eeeff3 without explanation.
* | | | | | | | | | | | tui: Disable BCE almost always. #7624Justin M. Keyes2017-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 133ae5eeeff3 implemented BCE (background color erase). But we can't trust terminfo, so it is safer disable BCE if we are not certain. Per https://github.com/kovidgoyal/kitty/issues/160#issuecomment-346470545 terminal support for BCE seems to be (1) optional and (2) inconsistent. ref #4210 #4421 #7035 #7337 #7381 #7425 #7618
* | | | | | | | | | | | tui: Disable BCE by default. #7624Justin M. Keyes2017-11-23
|/ / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 133ae5eeeff3 implemented BCE (background color erase). That's fine if the system terminfo claims to support it; but our built-in fallback should not assume it. Per https://github.com/kovidgoyal/kitty/issues/160#issuecomment-346470545 terminal support for BCE seems to be (1) optional and (2) inconsistent. So the built-in terminfos should disable it by default. ref #4210 #4421 #7035 #7337 #7381 #7425 #7618
* | | | | | | | | | | FIXUP: duplicate error number in #7422Björn Linse2017-11-23
| | | | | | | | | | |
* | | | | | | | | | | tui: move terminfo_is_term_family()Justin M. Keyes2017-11-22
| | | | | | | | | | |
* | | | | | | | | | | Merge #7593 'PVS static analysis fixes'Justin M. Keyes2017-11-22
|\ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | move.c: remove unreachable break statementPeter Kalauskas2017-11-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | n > 0 verified by while condition, (--n < 0) always false
| * | | | | | | | | | | eval.c: remove nonnullret deadcodePeter Kalauskas2017-11-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The following calls can't return null: * xmalloc * xcalloc * get_buffer_info * get_tabpage_info * get_vim_var_str * get_win_info * tv_get_string * tv_list_alloc * tv_list_alloc_ret * vim_strnsave
| * | | | | | | | | | | helpers.c: statically assert integer falls within rangePeter Kalauskas2017-11-22
| | | | | | | | | | | |
| * | | | | | | | | | | Fix for pvs V782, pointer access to first element of arrayPeter Kalauskas2017-11-22
| | | | | | | | | | | |
| * | | | | | | | | | | input.c: replace if/else with switchPeter Kalauskas2017-11-22
| | | | | | | | | | | |
| * | | | | | | | | | | menu.c: remove conditional expression that is always truePeter Kalauskas2017-11-22
| | | | | | | | | | | |