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

window local tagbar #607

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

isharaka
Copy link

@isharaka isharaka commented May 13, 2020

Adds a global option to allow keeping tagbar local to the window containing the buffer.

The intention is to keep the tagbar local to the current window. This change does do that. However if we move to another window while tagbar is active the tagbar will be updated to reflect the buffer in the active window.

I would like to do the following when switching windows with tagbar active (if the opted in):

  • prevent tagbar being updated when moving around windows
  • make TagbarToggle close the active tagbar and reopen it in the newly active window

I am very new to vimscript. I would appreciate some hints to be able to do that.

@isharaka isharaka marked this pull request as ready for review May 13, 2020 10:29
@alerque
Copy link
Member

alerque commented May 13, 2020

Some reason this was closed? It it isn't ready but you still plan to work on it it would be nice to track it as an open PR in Draft mode (you can convert it back using the link in the reviewer section after you open it up again).

@alerque alerque marked this pull request as draft May 13, 2020 10:51
@isharaka
Copy link
Author

Hi @alerque, This one is still open. I did open one before and unintentionally closed it.

@raven42
Copy link
Collaborator

raven42 commented Oct 29, 2020

@isharaka A little while ago there was a change made to the g:tagbar_left to use g:tagbar_position instead (#630 / #652). This allows more granular control of the window positioning so it should now be possible to make the tagbar window local to the active window by doing something like this:

let g:tagbar_position = leftabove

This should open the tagbar to the left or above of the current active window (see :h split for more details on exactly how this works). Note that this wouldn't cover the case of only updating the tagbar window when switching to other windows. It will still do that, but this should at least give you a few more options for window positioning.

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.

None yet

3 participants