omerxx / tmux-sessionx

A Tmux session manager, with preview, fuzzy finding, and MORE
GNU General Public License v3.0
554 stars 51 forks source link

Am I confused?? Preview only shows pane0 of the window?? #78

Closed cavanaug closed 2 months ago

cavanaug commented 2 months ago

Is this the expected behavior??

I have a window with multiple panes, but during preview Im only session pane0.

omerxx commented 2 months ago

You should be able to see additional panes, maybe with slightly wider settings? image

cavanaug commented 2 months ago

image

You can see on the side where I have session 4 in a two pane horizontal split, but when sessionx previews it, you only see one pane. It appears that it is only showing preview for the active pane?

Ive tried with both tmux 3.4 & 3.3

omerxx commented 2 months ago

I'm sorry. You're right I misread your issue. Yes the current preview uses tmux capture-pane and fetches the active pane from the session you're on. The way around it is using the window_mode where you can browse a list of windows inside sessions. I was looking for a way to construct the view and eded up not bothering with presenting everything in a small preview window.

If you think it's necessary and have a better way of presenting please share!

cavanaug commented 2 months ago

I think even when using the window-mode (C-M) it only shows the active pane. In this regard, I think the native choose-tree is better because it actually shows the multiple panes. I dunno, maybe tmux itself could expose a capture-window that uses the same logic as how the preview is handled in choose-tree.

Net, net, this is the expected behavior, so Ill close this...

omerxx commented 2 months ago

@cavanaug This was exactly my request / when I tried searching. Even the Tmux preview itself (prefix+S) reconstructs it's own layout of capture-pane (not necessarily in the order they are laid on the screen.

If anyone ever wants to construct this in the plugin's preview I'm more than happy to explore :)