Skip to content
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

Fix highlights on expanded lines. #337

Merged

Conversation

przepompownia
Copy link
Contributor

@przepompownia przepompownia commented Mar 6, 2024

  • Don't pass invalid ns_id key to nvim_buf_set_extmark opts - it resulted with error (silenced by using pcall)
  • Fix column number in the end of range of copied extmark
  • Quick return if window id is invalid
  • fix revealed line/column issues (related to different offset on vim.fn and vim.api methods)
  • notify (debug level) about some errors (maybe not needed after above fixes)

@przepompownia
Copy link
Contributor Author

master (window with no extmark copied):
image

df34cd0 (extmarks are copied but into incorrect position):
image
52f5c7a(extmarks are placed correctly):
image

(in the meantime `col` was used to guess the correct `end_col`)
@rcarriga
Copy link
Owner

Great thanks for the PR! 😄

@rcarriga rcarriga merged commit 4575bc3 into rcarriga:master Mar 18, 2024
@przepompownia przepompownia deleted the fix-copying-extmark-in-line-hover branch March 18, 2024 15:38
@przepompownia
Copy link
Contributor Author

Thanks for merging. For many months I couldn't find a good time to look in detail at what was happening there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants