justincampbell / vim-eighties

Automatically resizes your windows
http://www.vim.org/scripts/script.php?script_id=4502
MIT License
64 stars 6 forks source link

Opening Tagbar #14

Open colwem opened 9 years ago

colwem commented 9 years ago

Setting let g:eighties_bufname_additional_patterns = ['Tagbar', ... ] works to prevent the tagbar window from resizing when I switch focus to it but it does not prevent this plugin from resizing it when I run :TagbarOpen or :TagbarToggle to open the tagbar window. Everytime I open tagbar I have to manually resize it back to something sensible. I notice you had to add a special routine to handle NERD_tree. This may be the same kind of problem. I think eighties#EightiesResize() is getting called on the tagbar window when bufname("%") in

for pattern in patterns
  if bufname("%") =~ pattern
    return 1
  endif
endfor

is not 'Tagbar'.

Otherwise I'm very happy I just discovered this plugin. It's a great idea.

justincampbell commented 9 years ago

Thanks for the report! I've also experienced this on occasion, especially when I've used NERDTree. I spent some time trying to fix this and came up short, but if someone submitted a pull-request, I'd happily accept it.

justincampbell commented 9 years ago

Could be related to #13

xxvxx1 commented 8 years ago

remove WinEnter auto command is a Temporary solution , but i have no idea if it can make other issues