Sublime Forum

Jump to Tab in Any Group

#1

Hey I wanted ask if it is at all possible to have this feature implemented. Basically, let’s say I have 2 groups (2 columns) and the first column includes 1.txt. If I am working on the 2nd group and I forget that 1.txt was open in group 1, when I type ctrl+p and then enter 1.txt and press enter, is it possible to jump to the 1.txt file open on the first group rather than open it again in the current group?

Thanks

0 Likes

#2

+1

This is a critical issue for me as well. If SublimeText2 can do this, it would be my editor of choice. E-TextEditor on Windows is doing this and I really miss this feature.

0 Likes

#3

Only if there’s already a clone in the current group would it take precedence?

The current behaviour leads to much easier cloning than the New view into file but perhaps that ease could be maintained in some other form.

0 Likes

#4

I personally wouldn’t mind if the clone in the current group got precedence over the one in another group. I think that makes a lot more sense. However, I really think that this behavior is important for ST2. I hope that it can be implemented. My only concern is that the groups are very distinct and seems like completely unaware of each other.

0 Likes

#5

Don’t forget multiple windows too :smile:

What I find annoying is that you can’t have a project spanning windows. Say you
have some project specific settings that are used to mod the behaviour of some
plugins you have.

Say you have 3 monitors and say you drag out a tab from the project window into
a second window. Cool, it’s already been given the setting right, so all is
fine?

But what if you use some open in same folder quick panel command to open a few
more files in that second window? The project specific settings aren’t applied.

As well as multiple groups / windows the handling of clones seems less than
optimal.

Clones have implications for plugins. I’ve never really sat down before and
studied it, having only in the last few months started to use them extensively,
but I’ve been dimly aware of some quirks. For example I noticed that SublimeLint
(not SublimeLinter) will only work in ONE of the clones and sometimes not at
all.

Views have an id(), but also a buffer_id(), the latter is what’s shared between
clones. The add_regions regions and view.sel() selections are not share though
the view.settings() object is.

Settings being shared has interesting implications if used for tracking state on
your plugin (settings are easily referenceable out of the box via bindings and
not an uncommon way of tracking state)

I just looked then and found that event handlers DO seem to be fired for each
clone, but curiously the handlers are passed the same view multiple times? This
can be quite easily determined by comparing the id() of the view passed to the
EventListener and the window.active_view(). It’s not even always the
active_view() that gets passed to the EventListener method.

This could easily be the cause of havoc on stateful plugins I’ve been noticing.
I’m wondering if there’s any reasoning behind that or if it’s just a bug?
Perhaps it’s there to make the case of handling single views easier?

Like multiple selections, I’d guess a bit more attention needs to be paid when
developing for multiple views. IIRC The TextMate guy used to say multiple
selections were too complicated. I think everyone’s on the same page with seeing
that the additional complexity cost is worth it though.

Likewise, I’d say the same with clones. They are far too handy to have to choose
between them or other handy plugins that don’t operate with them.

0 Likes

#6

This is actually a pretty good suggestion.

Another idea is to have another key combo to open the file, say Cmd P, then using Cmd Enter or Shift Enter to open the file in a) if already opened file, jump to a different group if necessary, b) if the file has’t been opened, open it in the current group. The “Enter” action can still be the same as is – reopen the file again in the current group.

0 Likes

#7

bump!

0 Likes

#8

Unfortunately, I think it isn’t attracting enough attention or is not a feature that is commonly used/required by developers to be in the radar. Hopefully somebody can implement this as a Package Control plug-in.

0 Likes

#9

[quote=“castles_made_of_sand”]What I find annoying is that you can’t have a project spanning windows. Say you
have some project specific settings that are used to mod the behaviour of some
plugins you have.[/quote]

I agree. The “reveal in side-bar” is something that I would love to work in multiple windows.

[quote=“castles_made_of_sand”]Likewise, I’d say the same with clones. They are far too handy to have to choose
between them or other handy plugins that don’t operate with them.[/quote]

Again, I agree. However, as you mention maybe the complexity cost is too much and demand is too low.

0 Likes