toggle between two most recently used tabs (MRU)

184 views
Skip to first unread message

John Dohe

unread,
May 23, 2014, 4:27:40 PM5/23/14
to cani...@googlegroups.com
Hardware: Mac Mini
OS: Mavericks: OS X 10.9.3 (13D65)
Browser: Safari Version 7.0.3 (9537.75.14)

I want a single key sequence that will allow me to toggle between the two 
most recently used Safari tabs.

This has to work with several open tabs, that are not right next to each other 
meaning, that the two tabs may have 3,4,5 or more other tabs between them. 

I'm looking for something like what Ctrl-Tab in a windows pc does: 
Ctrl-Tab in a pc toggles between the two most recently used tabs, no matter 
how many tabs are in between them.

Can this be done?

Suggestions?

Canisbos Computing

unread,
May 23, 2014, 5:06:40 PM5/23/14
to John Dohe, cani...@googlegroups.com
Tab Options has that. 

--

---
You received this message because you are subscribed to the Google Groups "Canisbos Extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to canisbos+u...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Canisbos Computing

unread,
May 23, 2014, 6:38:45 PM5/23/14
to from SJZ MacMini #3, canisbos
A few comments.

  1. After installing Tab Options, it won't have any effect on tabs that were already open when it was installed. So if didn't restart Safari after installing the extension, please do so or close all the tabs that were open.
  2. Ctrl-Tab is, I believe, Safari's default hotkey for cycling tabs forward. To use it in Tab Options, first you have to assign a different hotkey to Safari's built-in function. You can do so in the Keyboard prefpane of System Preferences.
  3. I'm not sure I understood you correctly, but it sounded like you tried pressing Command-Z, Ctrl-Z, and Alt-Z (Option-Z) to switch to the last active tab. Did you try pressing just Z by itself? The default hotkey for that function is Z without any modifiers.

Chul



On May 23, 2014, at 2:56 PM, from SJZ MacMini #3 <drf...@gmail.com> wrote:

I have “Tab Options”.

I’ve tried deleting all default key sequences, and setting only one for the 
Switch to Last Active Tab” option.

It won’t “take” Ctrl-Tab: it doesn’t record this sequence at all.

The default is “Z”.

Command-Z, Ctrl-Z, Alt-Z all have no effect whatsoever.  Nothing happens 
when I try those key combinations in my Safari with 10 tabs open.

So I tried Command-Z

Again, nothing happened.

What am I doing incorrectly?

Do I have to enable something in “Tab Options”?

Here are my current settings:

<Screen Shot 2014-05-23 at 5.54.27 PM   Friday  5-23-14.png>

Please advise!

Thanks,
Stan

Canisbos Computing

unread,
May 23, 2014, 7:54:29 PM5/23/14
to from SJZ MacMini #3, canisbos
Stan,

Command-Tab one of the few hotkeys that cannot be reassigned away from its system-wide function of switching between applications. So forget about that.

I just tried myself to assign Ctrl-Tab to Tab Options's Switch to Last Active Tab function. It didn't work, even after assigning a different shortcut to Safari's built-in tab switching function. It seems that Tab Options is unable to use Ctrl-Tab because it fails to capture the hotkey. I will try to fix this, but I probably won't get around to it anytime soon.

In the meantime, I suggest you use a different hotkey for Switch to Last Active Tab. Most combinations that don't involve the Tab key (and that are not already in use by Safari or OS X) should work. Did you try pressing the default hotkey Z by itself? Did it work?

Anyway, to answer your question about how to assign a different shortcut to Safari's built-in tab switcher, this is how you do it:

  1. Open the Keyboard pane of System Preferences.
  2. Switch to the Shortcuts tab.
  3. In the menu on the left, choose App Shortcuts. (See below.)

  1. Click the + button to add a shortcut.
  2. In the Application drop-down, choose Safari.
  3. In the Menu Title box, enter "Show Next Tab" exactly, without the quotes.
  4. In the Keyboard Shortcut box, type some key combo that's not Ctrl-Tab. (For example, Ctrl-Cmd-Tab will work.)
  5. Click Add.



Chul


On May 23, 2014, at 4:31 PM, from SJZ MacMini #3 <drf...@gmail.com> wrote:

Hi Chul,

Thanks for getting back.

Ok, I went to the Keyboard prefpane of System Preferences and tried to find the 
command-tab sequence and either turn it off, or re-assign it to another key combination, 
but … I could not find where cmd-tab is located !!

Can you provide me with a screenshot of where it it?

Thanks,
Stan

Canisbos Computing

unread,
May 25, 2014, 12:54:01 PM5/25/14
to from SJZ MacMiniMail#3, canisbos
Stan,

The issues you mentioned are not bugs in Tab Options.

If a page focuses a search field (or any other field) when you start typing something, Tab Options should not interfere with that. To avoid such a search field's being focused when you use a Tab Options hotkey, the hotkey should use a modifier. That's why you were able to avoid that problem by assigning Ctrl-Tilde in place of Z.

If the keyboard focus is in Safari's address (URL) bar, Tab Options cannot "see" any keys you press. This is a limitation of all Safari extensions that use the native extension API. It can only "see" keypresses that happen while the web page is focused (such as after you click anywhere on the page). This is a problem, but it's not a problem I can do anything about.

For a list of Safari's built-in keyboard shortcuts, try a program called CheatSheet. It is a utility that will show a list of any application's keyboard shortcuts when you hold down the Command key for a couple of seconds.

Chul


On May 25, 2014, at 9:29 AM, from SJZ MacMiniMail#3 <drf...@gmail.com> wrote:

Thanks Chul,

I did what you suggested, and was able to create Ctrl-Escape as a key sequence 
that will advance to the next tab, of a series of open tabs, in Safari, just like what 
Ctrl-Tab does.  However, this is not stable.  It will work and allow me to cycle from 
left to right through 18 open tabs for awhile, and then it will quit after cycling through 
from tab-1 to tab-6, and stop going past tab-6.  Then I wait a little bit, and Ctrl-Esc
will then cycle through all open tabs as usual.

When I had Ctrl-Esc active, and tried Ctrl-Tab, Ctrl-Tab cycled me through my 
Favorites Bar bookmarks, from left to right, one after the other.  Interesting, but 
I don’t see much utility in this.

However, this is not what I’m looking for.  I’ve deleted Ctrl-Esc.

I did try Z, but it behaved strangely as follows:

Say I’ve got ten tabs open.

With the Z default enabled, when I mouseclick tab-1, and then mouseclick tab-2, 
and then press Z, the result will be to toggle between these two tabs as many times 
as I press Z.

Z also works when I want to switch between tab-1 and tab-5, or tab-4 and tab-8.

However, when I mouseclick tab-1, and then mouseclick tab-5, and if tab-5 is a google 
search page, the cursor defaults to the search field.  When I press Z again, this letter 
is simply added to the end of whatever search term is already in this field, even if its blank, 
and the system does not switch back to the most recently used tab.

A similar problem occurs with some other sites that have a search field in the displayed page.

When I Z-toggle to it from another tab, the cursor again defaults to the search field of this site, 
and pressing Z simply puts that letter into the search field.

I tried replacing Z with Alt-tilde: the Alt symbol appears yellow, and the tilde is normal black. 
When I try using this combination, it doesn’t work at all.

So I switched to Ctrl-tilde, and that worked … some.

or www.google.com set as tab-18, I could toggle to tab-18 from say, tab-5, but when I tried 
to toggle back tab-5, Ctrl-tilde didn’t work.

But … when I put http://news.google.com/nwshp?hl=en&tab=wn into tab-18, I could then 
toggle between tab-5 and tab-18.

Also, if the URL field of a tab is hi-lited, Ctrl-tilde doesn’t work: the system dings audibly 
when I try the key combination.  I have to un-hi-lite the URL field by clicking into the clear 
area of the page, and then Ctrl-tilde works again.  BUT … if I click into the search field 
of that page, Ctrl-tilde doesn’t work.

All in all, this seems to be a fix that works for me, but there are the bugs noted above 
that, if you could address, would make the product that much better!  :)

By the way, where can I get a list of commands like “Show Next Tab” to play with?

Thanks!
Stan


On May 23, 2014, at 7:54 PM, Canisbos Computing <cani...@gmail.com> wrote:

Stan,

Command-Tab one of the few hotkeys that cannot be reassigned away from its system-wide function of switching between applications. So forget about that.

I just tried myself to assign Ctrl-Tab to Tab Options's Switch to Last Active Tab function. It didn't work, even after assigning a different shortcut to Safari's built-in tab switching function. It seems that Tab Options is unable to use Ctrl-Tab because it fails to capture the hotkey. I will try to fix this, but I probably won't get around to it anytime soon.

In the meantime, I suggest you use a different hotkey for Switch to Last Active Tab. Most combinations that don't involve the Tab key (and that are not already in use by Safari or OS X) should work. Did you try pressing the default hotkey Z by itself? Did it work?

Anyway, to answer your question about how to assign a different shortcut to Safari's built-in tab switcher, this is how you do it:

  1. Open the Keyboard pane of System Preferences.
  2. Switch to the Shortcuts tab.
  3. In the menu on the left, choose App Shortcuts. (See below.)

<PastedGraphic-2.png>
Reply all
Reply to author
Forward
0 new messages