| Commit message (Collapse) | Author | Age |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
What works:
1. ShaDa file dumping: header, registers, jump list, history, search patterns,
substitute strings, variables.
2. ShaDa file reading: registers, global marks, variables.
Most was not tested.
TODO:
1. Merging.
2. Reading history, local marks, jump and buffer lists.
3. Documentation update.
4. Converting some data from &encoding.
5. Safer variant of dumping viminfo (dump to temporary file then rename).
6. Removing old viminfo code (currently masked with `#if 0` in a ShaDa file for
reference).
|
|
|
|
| |
Also fix some other clint errors.
|
|
|
|
|
|
| |
- new feature: if the first character of 'keywordprg' is ":", the
command is invoked as a Vim ex-command prefixed with [count].
- change default 'keywordprg' to :Man
|
|
|
|
|
|
|
|
|
|
| |
- Improve the implementation of deferred/immediate events.
- Use the new queue module to change how/when events are queued/processed by
giving a private queue to each emitter.
- Immediate events(which only exist to break uv_run recursion) are now
represented in the `loop->fast_events` queue.
- Events pushed to child queues are propagated to the event loop main queue and
processed as K_EVENT keys.
|
|
|
|
|
|
| |
- Declare poll timer in Loop structure instead of a loop_poll_events local
variable.
- Move deferred event management to input.c
|
|
|
|
|
| |
Also handle clipboard errors more like vim: paste from unnamed register
if clipboard provider fails.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
- Add event loop abstraction module under src/nvim/event. The
src/nvim/event/loop module replaces src/nvim/os/event
- Remove direct dependency on libuv signal/timer API and use the new abstraction
instead.
- Replace all references to uv_default_loop() by &loop.uv, a new global variable
that wraps libuv main event loop but allows the event loop functions to be
reused in other contexts.
|
|
|
|
|
| |
This occured when clipboard=unnamedplus and doing "+p in visual mode.
Fixes #2942.
|
| |
|
|
|
|
|
|
|
| |
Problem: May crash when using a small window.
Solution: Avoid dividing by zero. (Christian Brabandt)
https://github.com/vim/vim/commit/v7-4-606
|
|
|
|
|
|
|
|
|
|
| |
Problem: Redrawing problem with 'relativenumber' and 'linebreak'.
Solution: Temporarily reset 'linebreak' and restore it in more places.
(Christian Brabandt)
https://github.com/vim/vim/commit/v7-4-576
Closes #1946
|
| |
|
|
|
|
| |
Introduction of asserts broke bracketless if's.
|
|
|
|
|
|
| |
After left clicking on a tab in the tabline, the "in_tab_line" variable wasn't
set to 'false' and every following mouse action assumed still being on the
tabline which messed up visual selection etc.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Refactor summary:
- extern int opcount --> extern long opcount
- bool find_decl(..., int len, ...) --> bool find_decl(..., size_t len, ...)
* int find_ident_under_cursor(...) --> size_t find_ident_under_cursor(...)
- int find_ident_at_pos(...) --> size_t find_ident_at_pos(...)
- int modify_fname(..., int *usedlen, ..., int *fnamelen) --> int modify_fname(..., size_t *usedlen, ..., size_t *fnamelen)
* char_u *eval_vars(..., int *usedlen, ...) --> char_u *eval_vars(..., size_t *usedlen, ...)
- int find_cmdline_var(..., int *usedlen) --> ssize_t find_cmdline_var(..., size_t *usedlen)
- static char_u *repl_cmdline(..., int srclen, ...) --> static char_u *repl_cmdline(..., size_t srclen, ...)
- bool get_visual_text(..., int *lenp) --> bool get_visual_text(..., size_t *lenp)
* char_u *find_file_name_in_path(..., int len, ...) --> char_u *find_file_name_in_path(..., size_t len, ...)
- static char_u *eval_includeexpr(..., int len) --> static char_u *eval_includeexpr(..., size_t len)
- char_u *find_file_in_path(..., int len, ...) --> char_u *find_file_in_path(..., size_t len, ...)
* char_u *find_file_in_path_option(..., int len, ...) --> char_u *find_file_in_path_option(..., size_t len, ...)
- char_u *find_directory_in_path(..., int len, ...) --> char_u *find_directory_in_path(..., size_t len, ...)
* int spell_move_to(...) --> size_t spell_move_to(...)
- int spell_check(...) --> size_t spell_check(...)
- static int spell_bad_len --> static size_t spell_bad_len
- void find_pattern_in_path(..., int len, ...) --> void find_pattern_in_path(..., size_t len, ...)
Helped-by: Justin M. Keyes <justinkz@gmail.com>
|
| |
|
| |
|
| |
|
|
|
|
|
| |
When clipboard=unnamed and put over visual selection, reduces number of
provider calls from 6 to 2. Also add test.
|
|
|
|
|
|
|
| |
This variable isn't stateful, and should be passed around instead.
Helped-By: Scott Prager <splinterofchaos@gmail.com>
Helped-By: Michael Reed <m.reed@mykolab.com>
|
|
|
|
|
|
| |
We already use wrappers for allocation, the new `xfree` function is the
equivalent for deallocation and provides a way to fully replace the malloc
implementation used by Neovim.
|
|
|
|
|
| |
Helped-By: Nicolas Hillegeer <nicolas@hillegeer.com>
Helped-By: Michael Reed <m.reed@mykolab.com>
|
| |
|
|
|
|
|
|
|
|
| |
Problem: A search with end offset gets stuck at end of file. (Gary Johnson)
Solution: When a search doesn't move the cursor repeat it with a higher
count. (Christian Brabandt)
https://github.com/vim/vim/releases/tag/v7-4-636
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Switching cursor off is only necessary in two occasions:
- When redrawing to avoid terminal flickering
- When the editor is busy
The first can now be handled by the TUI, so most calls to ui_cursor_off can be
removed from the core.
So, before this commit it was only necessary to switch the cursor off to notify
the user that nvim was running some long operation. Now the cursor_{on,off}
functions have been replaced by busy_{stop,start} which can be handled in a
UI-specific way(turning the cursor off or showing a busy indicator, for
example).
To make things even more simpler, nvim is always busy except when waiting for
user input or other asynchronous events: It automatically switches to a non-busy
state when the event loop is about to be entered for more than 100 milliseconds.
`ui_busy_start` can be called when its not desired to change the busy state in
the event loop (As its now done by functions that perform blocking shell
invocations).
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Removed term.c, term.h and term_defs.h
- Tests for T_* values were removed. screen.c was simplified as a
consequence(the best strategy for drawing is implemented in the UI layer)
- Redraw functions now call ui.c functions directly. Updates are flushed with
`ui_flush()`
- Removed all termcap options(they now return empty strings for compatibility)
- &term/&ttybuiltin options return a constant value(nvim)
- &t_Co is still available, but it mirrors t_colors directly
- Remove cursor tracking from screen.c and the `screen_start` function. Now the
UI is expected to maintain cursor state across any call, and reset it when
resized.
- Remove unused code
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Remove abstract_ui global, now it is always active
- Remove some terminal handling code
- Remove unused functions
- Remove HAVE_TGETENT/TERMINFO/TERMIOS/IOCTL #ifdefs
- Remove tgetent/terminfo from version.c
- Remove curses/terminfo dependencies
- Only start/stop termcap when starting/exiting the program
- msg_use_printf will return true if there are no attached UIs(
messages will be written to stdout)
- Remove `ex_winpos`(implement `:winpos` with `ex_ni`)
|
|
|
|
|
|
|
|
|
|
| |
Problem : Negative array index read @ 909.
Diagnostic : False positive.
Rationale : Suggested error path assigns a negative value to idx at
line 836 (`idx = find_command(ca.cmdchar);`). That's
impossible, as `ca.cmdchar` is set to Ctrl_BSL just two
lines above, so we know that value will be in the table.
Resolution : Assert idx >= 0.
|
|
|
|
|
|
|
|
|
| |
If you Google for this phrase found in the Vim documentation you'll find
almost exclusively hits from the Vim documentation. I think changing
"halfway a line" to "halfway through a line" makes more sense.
There seems to be an pervasive odd use of the word 'halfway' in the
original docs which I'm updating everywhere.
|
|\
| |
| | |
vim-patch:7.4.490
|
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Cannot specify the buffer to use for "do" and "dp", making them
useless for three-way diff.
Solution: Use the count as the buffer number. (James McCoy)
https://code.google.com/p/vim/source/detail?r=v7-4-490
|
|/
|
|
|
|
|
|
| |
Problem : Out-of-bound read from a buffer.
Diagnostic : False positive.
Rationale : nv_max_linear should always be less than nv_cmd_idx size
(NV_CMDS_SIZE).
Resolution : Assert rationale.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Replace code like this
```c
func() {
if (cond) {
...
...
...
}
return ret;
}
```
```c
for (...) {
if (cond) {
...
...
...
}
}
```
with
```c
func() {
if (!cond) {
return ret;
}
...
...
...
}
```
```c
for (...) {
if (!cond) {
continue;
}
...
...
...
}
```
|
| |
|
|
|
|
|
| |
Also get rid of some platform references made irrelevant by the removal
of their respective platform specific GUI code.
|
| |
|
| |
|
|\
| |
| | |
vim-patch:7.4.425,435,467,472,473,478
|
| |
| |
| |
| |
| |
| |
| |
| | |
vim-patch:7.4.467
Avoid a problem with unwanted linebreaks in block mode
https://code.google.com/p/vim/source/detail?r=v7-4-467
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
vim-patch:7.4.425
Problem: When 'showbreak' is used "gj" may move to the wrong
position. (Nazri Ramliy)
Solution: Adjust virtcol when 'showbreak' is set. (Christian Brabandt)
https://code.google.com/p/vim/source/detail?r=v7-4-425
|
| |
| |
| |
| | |
This is not being used and should not be part of the core anyway.
|
| | |
|