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

Reimplement the now missing curwin_col_off FFI function binding, fix #38 #41

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

bbjornstad
Copy link

Please see the resolved issue for more information about the specific issue this is solving. TLDR: removed a function binding which was necessary for plugin operation and reimplemented it according to @cassava's proposed solution.

This has worked for me for some time and I believe for other people as well.

bbjornstad and others added 6 commits May 29, 2024 12:32
…ixes anuvyklack#38

As noted by @cassava, as of a recent version of this plugin, the
`curwin_col_off` function was removed, leaving us to fend for ourselves.
Luckily, @cassava also proposed a fix, the likes of which seems to work on my
machine and from the limited reports, other individuals' machines as well.

This commit simply implements the patch specified by @cassava as the solution to
issues related to `curwin_col_off` no longer existing.
Not only was the original function `curwin_col_off` deprecated and removed, but
we also have a number of recent deprecations related to vim operations on
tables. In this case, we need to get rid of calls to `tbl_flatten` and replace
them with `vim.iter():flatten():totable()` wrappings
I accidentally forgot this part in the first commit, but we do still need a
function called `curwin_col_off` even though it was not used directly in
`init.lua`.
fix(ffi): correctly include variant definition for `curwin_col_off`
@bbjornstad
Copy link
Author

bbjornstad commented Jun 11, 2024

If anyone finds this hoping that this issue has been fixed in the upstream version of pretty-fold.nvim, until this PR is merged you can substitute my fork in your configuration (bbjornstad/pretty-fold.nvim). When this makes its way into the original repository I will remove my fork and one can move back to the upstream repo.

@taoso
Copy link

taoso commented Jun 11, 2024

@bbjornstad I am using you fork, it works like charming 👍

@daUnknownCoder
Copy link

If anyone finds this hoping that this issue has been fixed in the upstream version of pretty-fold.nvim, until this PR is merged you can substitute my fork in your configuration (bbjornstad/pretty-fold.nvim). When this makes its way into the original repository I will remove my fork and one can move back to the upstream repo.

might want to add this fork to rockerboo/awesome-neovim, because the last commit to this one was 2 years ago

adoyle-h added a commit to adoyle-h/one.nvim that referenced this pull request Aug 23, 2024
User should upgrade the plugin pretty-fold.nvim by manual.

use bbjornstad/pretty-fold.nvim instead of anuvyklack/pretty-fold.nvim,
because the later has not updated since 2 years ago.

related issue: anuvyklack/pretty-fold.nvim#39
pr: anuvyklack/pretty-fold.nvim#41
Fischmiep and others added 2 commits August 29, 2024 15:49
    - tbl_flatten is deprecated and will be removed in Nvim 0.13
    - This patch exchanges the affected parts with the suggested
      alternative vim.iter(…):flatten():totable()
fix(components): swap tbl_flatten
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.

4 participants