kevinhwang91 / nvim-ufo

Not UFO in the sky, but an ultra fold in Neovim.
BSD 3-Clause "New" or "Revised" License
2.16k stars 37 forks source link

`rightleft` support #157

Open rwmpelstilzchen opened 10 months ago

rwmpelstilzchen commented 10 months ago

Neovim version (nvim -v | head -n1)

NVIM v0.9.1

Operating system/version

BTW I use Arch

How to reproduce the issue

Install with vim-plug:

Plug 'kevinhwang91/promise-async'  " (dependency)
Plug 'kevinhwang91/nvim-ufo'

Configure with nvim-treesitter (installed elsewhere in the init file):

lua << EOF
require('ufo').setup({
    provider_selector = function(bufnr, filetype, buftype)
        return {'treesitter', 'indent'}
    end
})
EOF

Fold something with nvim-ufo. Switch to rightleft mode (for Hebrew, Persian, Arabic, etc…) using :set rl.

Expected behavior

The folded lines should display in a right-to-left manner, just as they do without nvim-ufo.

Actual behavior

Folded lines disappear. They reappear when rightleft is disabled (:set norl).

This have the same symptoms as this bug with org-bullets.nvim.