-
-
Notifications
You must be signed in to change notification settings - Fork 196
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue Tracker: Refactor document change manager (remove dot-repeat hack) #1266
Comments
Here are my new ideas for removing dot repeat. I had some old ones at #992 (comment), but they mostly involved trying to send edits to nvim in a way that would be picked up by dot repeat. Directly writing to dot repeat is going to be added to nvim at some point according to @justinmk, but not yet iirc. My new idea takes inspiration from the way that many nvim plugins handle dot repeat: https://www.reddit.com/r/neovim/comments/wkqkzf/adding_dotrepeat_to_plugins/ The challenge is that I need to construct a string to save in operatorfunc. There are two strategies:
This should delete a lot of code. |
This effort might be a no-go :/ The current dot repeat workaround works by However, the only thing we can reasonably record is what is pressed during insert mode - the way that insert mode was reached (for example ciw) is not recorded. Thus, I can't set Binding However, as one door closes, another opens, and I have come across neovim/neovim#3306, which should allow me to implement the ideas in #992 (comment). |
I have narrowed it down to two options: bind vscode
|
…anges Use nvim's built-in `vim.lsp.util.apply_text_edits` to synchronize document changes. Due to the built-in function already handling marks, it indirectly fixed the issue of missing marks vscode-neovim#1266
Closed, most content may be outdated. If there are new ideas, it's best to start a new discussion. |
We want to refactor two-way sync.
nvim_buf_set_lines
withnvim_buf_set_text
#992The text was updated successfully, but these errors were encountered: