-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Hi could be considered to add an option to hide/unhide a pane or window? #3047
Comments
Adding a special kind of hidden window or pane would add a lot of complexity when you could just as well move the pane or window to another session and back to hide it. You can filter the session out of choose mode if you don't want to see it. |
The addition of an special kind of window is just one of the alternatives. But moving to another session somehow will make very complex to have some kind of locality and may introduce issues with options like To have an invisible panel in principle it is not very different to zoom/unzoom (set layout with size zero) or assign it a null layout and save the previous one. An invisible window (or at least a window ignored is something as simple as just add a flag to it in order to make it ignored by switch or move commands loops... For example in emacs, the panels starting with a space in the name are not shown, listed or anything. Filtering out from Actually this is related the same somehow because the desired behavior it what What you suggest is more or less what my code tries to do, but I don't move it to a different session in order to respect Is there a reason why I can't set a Thanks for your reply, |
I don't find your problems with moving to another session very compelling I'm afraid. Problems with destroy-unattached seem trivial (turn it off when you have hidden windows?), you can use user options to store whatever locality information you need, and if you don't use choose mode, it should still be relatively simple to make whatever bindings you do use skip hidden windows using Removing a pane from the layout and flagging it so every loop skips it is adding a special kind of pane. The fact is that tmux's model is that every pty must belong to a pane, every pane to a window and every window to a session. And every pane must be visible - zooming is very much a special case of "only one pane" and even for it we unzoom before doing anything complicated. Changing fully to a model where things (ptys or panes) can float would be a big and disruptive shift and I can't see that some halfway thing where panes can be kind of hidden but also not would be much better than just using a special session. I would be OK with some changes if there are small things that would make the behaviour you want easier - maybe we make it so you can target the next window matching a filter, so instead of doing:
You could do something like:
To skip windows where the Or feel free to make other suggestions, but I don't think we are just going to have a way to say "hide this pane/window from everything", at least not anytime soon. |
That may be acceptable too to add a -F to some other commands. It may be confusing to know if @hidden refers to current or target window, but with a right documentation could be enough. |
You can already do this by wrapping the command in I have been thinking about this a bit more and I am perhaps a little more convinced about its usefulness. I still think that making a real "hidden pane" or "hidden window" would end up being no better than just moving the pane or window to a temporary session. A session is just a list of windows and panes, so adding our own "hidden panes" list is redundant. But I think we could extend the zoom mechanism to allow panes to be hidden. This is close to one of your suggestions. What I think we could do is:
This would be relatively simple to do but would - at least initially - not allow unhiding individual panes or mixing hide and zoom. Would this work for you? |
Hi @nicm : So far if The rest of your proposal will end up with some complex corner cases that I agree maybe don't worth it. I mean. The first use of the hidden panel may be to have a sort of toggle pane to hide-show in the current window. If the split shows the pane back it may end up being more unconformable than useful IMHO. The issue with temporary session is that when I set the |
Hi, I wrote https://github.com/nkh/tmuxake to do something similar. a quick and dirty and slooow screencast |
I have added this ( |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
This is actually a feature request,
Could we consider to add an option to hide/unhide a pane like the
resize-pane -Z
but inverse? The idea is to be hable to open a temporal panel and keep the history information. (Useful for example when working with an editor and want to compile or debug the current code temporarily, and go back and forth)I tried something like
resize-pane -t 2:0.1 -y 0
but it keeps one line of the target pane, so it not really hiden.Then I have a bash script like this:
That goes around the limitation a bit, but it is very limited and sometimes conflicts with
next-window
orswap-window
.So far I see several possible solutions here:
base-index
is considered likedisabled
but still local to this section. This may work but has a side effect of keeping session fully hidden, so maybe requires extra modifications...(looking at the code it may be something like what zoom-window does but calling:
But applied for a single pane.
3. Allow zero sizes in the
resize-pane
command so the panel will be here but not visible.4. Implement a sort of toggle pane inherent to every window that can be hidden like the
status-bar
.Does it makes sence?
Best,
Ergus
The text was updated successfully, but these errors were encountered: