| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
| |
When tabstop and shiftwidth are not equal, tabs are inserted as individual
spaces and then rewritten as tab characters in a second pass. That second pass
did not call changed_bytes which resulted in events being omitted.
Fixes #25092
|
| |
|
|
|
|
| |
`nvim_(get|set)_option_value` pick the current buffer / window by default for buffer-local/window-local (but not global-local) options. So specifying `buf = 0` or `win = 0` in opts is unnecessary for those options. This PR removes those to reduce code clutter.
|
|
|
|
|
| |
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
Co-authored-by: famiu <famiuhaque@protonmail.com>
|
|
|
|
|
|
| |
test: replace lfs with luv
luv already pretty much does everything lfs does, so this duplication
of dependencies isn't needed.
|
|
|
|
|
|
|
| |
Problem: The fix from b50ee4a8dc4306e4be78ac33fb74b21dc6be5538 may
adjust extmark twice, triggering on_bytes callback twice.
Solution: Don't let mark_adjust adjust extmark.
|
|
|
|
|
|
|
|
| |
When a buffer update callback is called, textlock is active so buffer
text cannot be changed, but cursor can still be moved. This can cause
problems when the buffer update is in the middle of an operator, like
the one mentioned in #16729. The solution is to save cursor position and
restore it afterwards, like how cursor is saved and restored when
evaluating an <expr> mapping.
|
|
|
|
|
| |
Co-authored-by: Raphael <glephunter@gmail.com>
Co-authored-by: smjonas <jonas.strittmatter@gmx.de>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
|
|
|
|
|
|
|
|
|
| |
When :undo! was introduced to Nvim the implementation of 'inccommand'
preview callback hasn't been fully decided yet, so not notifying buffer
update callbacks made sense for 'inccommand' preview callback in case it
needs to undo the changes itself.
Now it turns out that the undo-and-forget is done automatically for
'inccommand', so it doesn't make sense for :undo! to avoid notifying
buffer update callbacks anymore.
|
|\
| |
| | |
fix(substitute): subtract number of backslashes later
|
| | |
|
|/
|
|
|
|
|
|
| |
There can be other places that access window buffer info (e.g.
`tabpagebuflist()`), so checking `w_closing` in `win_findbuf()` doesn't
solve the crash in all cases, and may also cause Nvim's behavior to
diverge from Vim.
Fix #14998
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
updates. fixes #12861
Now mark_adjust() will trigger appropriate buf_updates_send_splice() called by extmark_adjust()
|
| |
|
| |
|
|
|
|
|
|
| |
One step further towards stable tree-sitter.
Co-authored-by: Björn Linse <bjorn.linse@gmail.com>
|
| |
|
| |
|
|
|
|
|
| |
Problem first raised
https://github.com/nvim-treesitter/nvim-treesitter/issues/1304
|
| |
|
| |
|
| |
|
|\
| |
| | |
Extmarks: remove `curbuf->deleted_bytes2` from `op_delete`
|
| | |
|
|/ |
|
|\
| |
| | |
extmark: splice extmarks on :luado
|
| | |
|
|\ \
| | |
| | | |
extmark: correct extmark_splice call with substitute and inccommand when replacing with escaped backslashes
|
| |/ |
|
|/ |
|
|\
| |
| | |
Extmarks: send correct buffer events on blockwise paste for nonuniform lines
|
| | |
|
|/ |
|
|\
| |
| |
| |
| | |
New versions of neovim will not read undofiles written by nvim before this merge (there will be an error message about incopmatible version). Nvim 0.4 (or an master up to bda12927be84f0e0e05e885f9acb40a7ac2c5524 ) can be used to recover older undofiles, so if you worried about unsaved changes lurking around in undofiles it would make sense to keep such version around somewhere to recover them.
This is a necessary change to keep tree-sitter and plugins dependent on byte-level buffer change events fully working with undo states from a undofile. If there is a clear demand we might implement reading of the old format. Such recovered buffers will not be be fully functional with plugins relying on buffer updates or tree-sitter, however.
|
| | |
|
|\ \
| |/
|/| |
fix_cursor: do not change line number when edit will not impact cursor row
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| | |
Fixes #13710
|
| | |
|
|/ |
|
|
|
|
|
|
| |
add byte count tests
update documentation
|
|
|
|
|
| |
Also adds a test that we actually subscribe to buffer events when in
CMDPREVIEW.
|
| |
|
| |
|
| |
|