-
-
Notifications
You must be signed in to change notification settings - Fork 488
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
Feature Request: Highlight higher scope of unshown highlit items #882
Comments
Can you please share a screenshot or something? I'm not quite understanding the issue you are describing. I'm not understanding why a variable assignment line being too long would have any impact on the tags identified by universal-ctags or on tagbar. I just want to make sure I understand your request. As for number 4, if I understand that request, I don't believe there is any option to do this currently. Tagbar only sets the fold levels for each line, but doesn't control showing/hiding the folds. |
If you want to take a look at the current implementation, the function that performs the highlight is here. Lines 2242 to 2246 in 0815b54
There is a bit specifically about highlighting the parent instead. Is this the issue to which you are referring? Lines 2304 to 2308 in 0815b54
|
Yes, the code at 2307 looks like it should be doing what I am wanting/expecting, but for me it isn't, here are some screenshots. The cursor is on an unfolded var, the var is highlit, makes sense: The cursor is on a folded var, the parent scope isn't highlit, and I wish it was :( The cursor is not on a var, the function is highlit, I'm happy for a moment :) |
Ok, I see what you mean now. Ya it looks like this might be a bug based on the comments in the code. It looks like it is supposed to set the highlight identifier to the parent tag if the fold is closed, but it looks like that might now be happening correctly. I suspect something it wrong with this logic here: Lines 2322 to 2325 in 0815b54
It is using the same Lines 2260 to 2264 in 0815b54
So maybe it is something to do with the Unfortunately I don't have time to really dig into it right now, but it is likely something in this area. I'm thinking if we do detect that the parent is folded, we may need to change the value of |
Thanks for the pointers though, I'm sure I can figure it out from here! |
It bugs me a bit that if my cursor rests on a variable assignment line too long the highlighting for the method I'm in disappears because the variable within its scope is highlit but folded from view. I'd love to be able to configure tagbar so that there are four options:
I'm not completely sure 4 isn't already possible, I scanned the help, wiki, and issues pretty carefully but not perfectly. I'm also not completely sure I can't already configure the highlighting colour/style based on tag type, but that's another thing I think would be cool.
I'm a software developer and I'd be happy to do the coding if someone who knows this codebase can confirm that it's possible and point me in approximately the right direction!
The text was updated successfully, but these errors were encountered: