piroor / treestyletab

Tree Style Tab, Show tabs like a tree.
http://piro.sakura.ne.jp/xul/treestyletab/
Other
3.5k stars 278 forks source link

[feature request] TST in separate window #1715

Closed Gaven-ar closed 5 years ago

Gaven-ar commented 6 years ago

Description

Is there a way to see the Tree Style Tab panel in a separate window? If is not, it would be a great feature because hide and show the panel change the size page content shown in the browser. In "read me page" says:

TST is implemented as just a sidebar panel, so there is no chance to provide horizontal version.

If this is about "just a sidebar panel"... is there a plan to another kind of TST style addon, as new window maybe?

Lej77 commented 6 years ago

This is actually already possible with the current version of Tree Style Tab. You just need to open the sidebar page in a normal tab in the window you want to control and then move that tab to a new window.

To do this you need to find the sidebar URL. It should be something like moz-extension://%Extension-id%/sidebar/sidebar.html where %Extension-id% should be replaced with the extensions random id.

Tree Style Tab's id can be found by opening a group tab. Do this by rapidly opening several tabs (hold ctrl+t). You can also do this by entering the URL about:treestyletab-group in the address bar and pressing enter.

TST's group tabs' have the URL moz-extension://%Extension-id%/resources/group-tab.html so you can simply replace resources/group-tab.html with sidebar/sidebar.html.

piroor commented 6 years ago

@Gaven-ar Your plan is quite similar to these alternatives on Chrome: https://chrome.google.com/webstore/detail/sidewise-tree-style-tabs/biiammgklaefagjclmnlialkmaemifgo https://chrome.google.com/webstore/detail/tabs-outliner/eggkanocgddhmamlbiijnphhppkpkmkl

TST 2.x's sidebar panel is designed to work in the sidebar frame, so loading of moz-extension://{UUID}/sidebar/sidebar.html produces very odd result for now. Tabs in other windows never appear, instead only tabs in the window itself appear in the list. To make TST similar to these Chrome extensions, we need to introduce some changes to list cross-window tabs into one panel.

piroor commented 6 years ago

Current TST 2.x's sidebar is designed to be associated to one window, thus it will be done easily that separating sidebar panel to a popup window for each Firefox window.On the other hand, it is hard to provide single tree for all other Firefox windows (like the Tabs Outliner on Chrome). In other words, because it is quite different from current TST's design model, Tabs Outliner-like TST should be released as a forked version.

Tragen commented 6 years ago

But the question is why would you need many windows anyhow? Only allow one window and you should be fine.

piroor commented 6 years ago

Did you mean an single-window mode (forcing to redirect new window requests to tabs in the only one existing window)? I think it is out of purpose for TST, because it's not related to "tree". Instead it should be done by something another addon to provide single-window mode, for people who don't want to use tree of tabs.

Gaven-ar commented 6 years ago

I get your points @piroor . So.. This feature request comes from the resizing behaviour when showing and hiding panels, like TST, on Firefox. Well, is there another way to change that? Before Firefox 57+ we had the auto-hiding setting, making possible show the panel over the page visited (and not next to).

piroor commented 6 years ago

Hmm, anyway such an "auto-hide sidebar" like behavior is hard to be done by WebExtensions-based addons for now. There are many problems: stacking order of windows, synchronizing window positions, and so on. Implementing any custom sidebar with auto-hide behavior based on existing APIs is an interesting challenge, so I hope that someone implements such an sidebar-framework for WE addons... (I think it is "too much" as just a TST's built-in features.)

Gaven-ar commented 6 years ago

It's clear that the discussion is not about TST functionality, but Firefox plugin integration, maybe. We'll have to wait for an improvement in the API. Or new plugins that use a side-panel in the web browser should be designed thinking in a diffrent integration.

Lej77 commented 6 years ago

I made an extension that opens the sidebar page in a new window.

Here is a link: Tree Style Tab in Separate Window