GithubHelp home page GithubHelp logo

Comments (13)

brokenbyte avatar brokenbyte commented on May 5, 2024 2

I have the same issue with it still resizing NERDTree windows, even when using the example given in the readme of let g:lens#disabled_filetypes = ['nerdtree', 'fzf']

from lens.vim.

ipod825 avatar ipod825 commented on May 5, 2024 1

The problem might be related to this.
Particularly, for me the filter doesn't work for neovim's terminal because when opening a terminal, in the lens#win_enter function still see the current window as the original window, which can be confirmed easily by putting the following autocmd in vimrc

augroup Testingautocmd!
    autocmd WinEnter * echom expand('%:p')
augroup END

A quick solution would be (as indicated by the previous link) changing this line to

  autocmd! BufEnter * call lens#win_enter()

However, this will then fail the case if you want to have two window viewing the same file in the same tabpage, which I have no idea how to fix.

from lens.vim.

jemag avatar jemag commented on May 5, 2024

that is weird, I am also using Defx and it does work for me with :

let g:lens#disabled_filetypes = ['nerdtree', 'fzf', 'defx']

from lens.vim.

infinite-ops avatar infinite-ops commented on May 5, 2024

that is weird, I am also using Defx and it does work for me with :

let g:lens#disabled_filetypes = ['nerdtree', 'fzf', 'defx']

Using the vimrc I posted? What version of vim?

from lens.vim.

jemag avatar jemag commented on May 5, 2024

I just meant that it works on my own setup. I am using neovim v0.5.0-378-gbb331a9b3 and lens.vim commit 8a1a14b.

from lens.vim.

infinite-ops avatar infinite-ops commented on May 5, 2024

@jemag you are right! the problem for me is not lens but animate! if I disable animate from the config above and lens behaves as expected.

let g:lens#animate = 0

@camspiers it appears lens was not the cause of this issue but rather one of your other plugins I was using in combination with it. Shall I raise a new issue against animate? Would it be possible to get a similar disabled_filetypes in animate?

from lens.vim.

PolarJunction avatar PolarJunction commented on May 5, 2024

@infinite-ops Wow, I had thrown these plugins in the trash because the resize filtering didn't work!
Disabling g:lens#animate worked for me too.

from lens.vim.

camspiers avatar camspiers commented on May 5, 2024

Thanks for the reports, I will fix this behavior when I get some time,

from lens.vim.

infinite-ops avatar infinite-ops commented on May 5, 2024

sounds good thank you @camspiers !

from lens.vim.

pinggit avatar pinggit commented on May 5, 2024

it also does not work for voomtree side panel.
https://github.com/vim-voom/VOoM

when you generate voomtree panel, it is extended he width unexpectedly.
then you manually squeeze the width back. from now it won't be extended anymore, which is good.
but then everytime you toggle the voomtree panel, it will be extended again. very annoying.

my vimrc:

let g:lens#width_resize_max = 80
"let g:lens#disabled = 1
let g:lens#animate = 0
let g:lens#disabled_filetypes = ['nerdtree', 'fzf', 'voomtree', 'vim-plug']

this plugin is super and useful since I'm a buffer split lover. but I'm also a Voom user and can't live without it. so this issue is a stopper for me. have to uninstall it for now...

btw nerdtree work fine after I disabled animate.

from lens.vim.

ipod825 avatar ipod825 commented on May 5, 2024

It turned out that #31 could solve the problem.

from lens.vim.

infinite-ops avatar infinite-ops commented on May 5, 2024

I just tried @ipod825 fork and it fixes this problem and also a new one I found with nnn.vim
I used this branch which appears to have a bunch of his PR's for lens.vim applied.

Plug 'ipod825/lens.vim', {'branch': 'disableoption'}

from lens.vim.

ipod825 avatar ipod825 commented on May 5, 2024

I ended up implemented my own plugin that only resize window if specified by rules: ipod825/war.vim.

from lens.vim.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.