Can you show/hide the tab bar with a script?
Posted: 30 Aug 2012 20:40
So... apparently Don is not interested in my request to show the tab bar when there's more than one tab, and hide it when there's only one. I dunno why, I thought it was fairly reasonable, but it's his software, he can do what he wants. I still want that functionality, though, and the original thread mentioned I could probably script it. So I figure I'd ask here: I looked through the help, and I didn't see anything that would let you script showing the tab bar? (At which point, it'd be easy enough to get a list of the current open tabs, check whether the list has more than one element, and toggle appropriately.)
In the scripting help: I see button(), but toggling the tab bar doesn't seem to be in the list of available toolbar buttons, just in the menu and as a keyboard shortcut. I see get() lets you get whether the tab bar is visible (#commandid 662), but no corresponding set(). I see setkey(), but that doesn't set it immediately, just on disk. setting() looked promising, but it doesn't seem to have the tab bar in its list, either. Am I missing anything about any of these, or anything else, that would let me toggle showing that bar immediately?
In retrospect, it's probably better scripting this anyway, as I've also become used to ctrl-w closing the window if it runs out of tabs to close - which Don would be completely right to not want to change that behavior now if I asked him to, as presumably loads of people are used to it not doing that, and would be annoyed
.
In the scripting help: I see button(), but toggling the tab bar doesn't seem to be in the list of available toolbar buttons, just in the menu and as a keyboard shortcut. I see get() lets you get whether the tab bar is visible (#commandid 662), but no corresponding set(). I see setkey(), but that doesn't set it immediately, just on disk. setting() looked promising, but it doesn't seem to have the tab bar in its list, either. Am I missing anything about any of these, or anything else, that would let me toggle showing that bar immediately?
In retrospect, it's probably better scripting this anyway, as I've also become used to ctrl-w closing the window if it runs out of tabs to close - which Don would be completely right to not want to change that behavior now if I asked him to, as presumably loads of people are used to it not doing that, and would be annoyed