| Commit message (Collapse) | Author | Age |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Refactoring summary:
- ui_write(): len: int --> size_t
* parse_abstract_ui_codes(): len: int --> size_t
* string_convert(): lenp: int * --> size_t *
- string_convert_ext(): lenp : int * --> size_t *
unconvlenp: int * --> size_t *
* utf8len_tab_zero: char[] --> uint8_t[]
* iconv_string(): slen : int --> size_t
unconvlenp: int * --> size_t *
resultlenp: int * --> size_t *
- mch_print_text_out(): len: int --> size_t
* out_pos: int --> size_t
|
| |
|
|
|
|
|
|
|
| |
- Add xterm/iterm sequences for changing cursor shape(with tmux wrapping).
Enabled by setting the NVIM_TUI_ENABLE_CURSOR_SHAPE environment variable.
- Remove nvim_override parameter from unibi_out. In the future another way of
overriding the terminal strings will be added.
|
| |
|
|
|
|
|
| |
Inspired by the vim-bracketed-paste plugin but adapted for the new TUI. Also
initialize some variables of type `Error` that were uninitialized
|
|
|
|
|
| |
Moving the cursor to the status line(to set the title) requires a different
sequence for xterm than the one used by urxvt.
|
|
|
|
|
| |
Some terminals will perform clearing functions using the current attributes.
Ensure the default attributes are set before clearing.
|
|
|
|
| |
TabClosed is triggered when a tab page closes.
|
|
|
|
| |
TabNewEntered is triggered after vim has entered a buffer in new tab.
|
|
|
|
|
| |
TabNew triggers when entering a new tab page, but not when entering an
already created one.
|
| |
|
|
|
|
|
| |
Now the attrentry_T structure will store all attributes in separate fields for
cterm and rgb UIs.
|
|
|
|
|
| |
Now all terminal-handling code was moved to src/nvim/tui, which implements a
new terminal UI based on libtermkey and unibilium
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- 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`)
|
| |
|
|
|
|
|
|
|
| |
The input buffer is only used for data that really came from another process and
is only visible to os/input.c. Remove the input_buffer_{save,restore} functions,
they are not necessary(Also can result in problems if data comes while the
typeahead is saved).
|
|
|
|
| |
Ignore all keys that aren't prefixed with KS_EXTRA.
|
|
|
|
| |
This is required to correctly handle certain keys such as <delete>
|
| |
|
|
|
|
| |
Closes #1902
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
Problem: It is not possible to have feedkeys() insert characters.
Solution: Add the 'i' flag.
https://code.google.com/p/vim/source/detail?r=v7-4-601
|
| |
|
|
|
|
| |
Fixes: #1976
|
|
|
|
|
|
|
|
|
|
| |
Problem : Out-of-bounds access @ 5815.
Diagnostic : False positive.
Rationale : Error occurs when event_name2nr() returns NUM_EVENTS, which
means an event with that name was not found. That cannot
happen, as previous check using find_end_event() @ 5744
ensures event name exists.
Resolution : Assert event_name2nr() result is less thatn NUM_EVENTS.
|
|
|
|
|
|
|
|
|
| |
Problem : Read from pointer after free @ {242, 391}.
Diagnostic : Real issues.
Rationale : Channel gets indeed freed on error case, producing
incorrect accesses to freed pointer later on.
Resolution : Implement reference counting mechanism to know when to free
channel.
|
|
|
|
|
|
|
| |
Problem : Resource leak @ 3324.
Diagnostic : Real issue.
Rationale : Stack is not being freed on error cases.
Resolution : Free stack before invoking EMSG_RET_NULL.
|
|
|
|
|
|
|
|
|
| |
Problem : Out-of-bounds read @ 9514.
Diagnostic : Real issue.
Rationale : PFD_NOTSPECIAL (253) is defined as the maximum not-special
value a prefix can have. But stack (and other) arrays are
defined as having MAXWLEN (250) items.
Resolution : Define MAXWLEN = 254.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem : Out-of-bounds read @ 2213.
Diagnostic : Real issue.
Rationale : Error occurs if cmap == ARRAY_SIZE(prt_ps_mbfonts),
but code takes the `if (prt_out_mbyte)` branch. That's it,
if a matching encoding is found but not a matching charset.
In that case, the first matching encoding is used.
Resolution : Remember the value of cmap for the first matching encoding.
Reset cmap to that value if first matching encoding is
going to be used.
|
|
|
|
|
|
|
| |
closes #1899
closes #1967
refs https://github.com/msgpack/msgpack-c/pull/194
|
|
|
|
|
|
|
|
| |
refs #1045 #1051
This was enabled by default a while ago (#1051), and has apparently not
created any issues. The amount of actual code related to it is tiny, so
it has been removed.
|
|
|
|
|
|
|
| |
While we're here:
- Remove references to the '+diff' feature, which has since been made
non-optional.
- Update a few Vim instances with Nvim.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Factor out main_msg() in favor of mch_msg() and manual indentation, as to
provide a much closer representation to the actual output of '--help'.
'gcc -E' reveals that main_msg() only consists of 3 printf calls
anyways.
- Factor out for loop used for printing top part of usage text; just
print the text normally.
usage() text:
- Don't print the version; that's what '--version' is for.
- Be consistent about nomenclature, e.g. '<arg>' denotes required
argument, '-h | --help' denotes '-h' and '--help' are equivalent, etc.
- Change some instances of vim{,rc,info} to nvim
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
Problem : Unitialized scalar variable @ 3239.
Diagnostic : Harmless issue.
Rationale : It's true pos.coladd is not initialized when calling
searchit(). But that's no problem, as coladd is only set in
that function.
Resolution : Initialize variable to 0.
|
|
|
|
|
|
|
|
|
|
|
| |
Problem : Argument cannot be negative @ 1165.
Diagnostic : Real issue.
Rationale : len can be assigned a negative value @ 1162;
len is passed as an unsigned argument @ 1165.
Resolution : Refactor variable's types:
- Use ftello instead of ftell to avoid using long.
- Assert ftello result is safely convertible to size_t.
- Introduce variable read_size to avoid using i (int).
|
|
|
|
|
|
|
|
| |
Problem : String not null terminated @ 1165.
Diagnostic : False positive.
Rationale : Code below terminates string (with NUL or '\n').
Resolution : Add explanatory comment, and assert termination.
Mark as Intentional at coverity's database.
|
|
|
|
|
|
|
|
|
|
| |
Diagnostic : False positive.
Rationale : Coverity thinks we are forgetting to add more char to hold
NULL, but it's not taking into account that two chars from
cntxformat will no be present in the result. In fact, we
can even allocate one byte less than currently done.
Resolution : Add explanatory comment and allocate one less byte.
Marked as "Intentional" at coverity's database.
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
| |
This makes it possible to highlight the lines starting with ~ at the end
of buffers and other elements highlighted using NonText.
As proposed by mhinz at
https://groups.google.com/forum/#!topic/vim_dev/p3de1iU1GXI/discussion
|
|\
| |
| | |
Factor out float usage & remove '+float' references
|
| |
| |
| |
| |
| | |
The corresponding code was already removed in
b4ca3abc9f6676ea250e42c834716a5f66d8ec30
|
| | |
|
| | |
|
| |
| |
| |
| |
| | |
Executing old tests leaves an empty file 'del' that doesn't get removed
by `make clean`.
|
|\ \
| | |
| | | |
Remove deadcode due to nonnullret funcs.
|
| | | |
|