I have an autocmd that updates the window title in my terminal based on the
current file name. BufEnter clearly seems to be the event I would want to
trigger it with. But I've noticed two problems:
(a) BufEnter isn't getting triggered after closing the last window in a tab and
ending up in a different tab. It *should* be getting triggered, right? I
mean, it gets triggered when I close a window and end up in a different window
in the same tab, so why wouldn't it get triggered when I close a tab?
(b) When switching directories in netrw (which switches buffers), BufEnter gets
triggered before the directory location is known, so expand('%') will be empty.
But once I'm in the directory, I get the directory location just fine by
calling expand('%'), so I'm not sure how netrw is changing the buffer location
*after* the BufEnter event. It seems like there's some questionable logic
going on there, but I'm not sure who's to blame.
...Aaron
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.