Tinderbox Forum

How to create bookmarks to Tinderbox notes

You can read a tutorial about this on my blog post: https://johnsidi.com/2017/04/25/how-to-create-bookmarks-to-tinderbox-notes/.

Thanks, again very useful!

As I note in the parallel thread, about your direct-to-Inbox technique, really the only question this leaves me with is dealing with the surplus Tinderbox Tabs that are generated each time you use this system. But thanks for this in-public guidance.

You are welcome!

I am amazed by the versatility of Tinderbox, and I have spent considerable time adapting it to my needs.

I am glad that my solutions have helped you! I am going to publish some more in the near future.

1 Like

I’m trying to figure out the “surplus Tinderbox Tabs” question.

It is something like that:

This view is the reason that I created the thread about the tabs and the shortcuts which in my projects.tbx can become even worse.

On using a stamp for a bookmark: why not simple click the tab? Tabs store the view, scroll position, and selection state, so the tab has all the information in the runCommand bookmark.

Is this simply a question of having a keyboard shortcut?

Because the tab sometimes is not opened and I do not want to search in order to open it. Why do we have bookmarks on a browser? Because we want to go fast to a point of the network.

Moreover, the keyboard shortcut is really important, at least to me. I do not want to fiddle with the trackpad or even worse with a mouse and I do not want to spend time finding out which tab to click.

Regarding the closing of tabs, there is another (first world :slight_smile: ) problem. After closing a tab, the size of the rest readjusts and then I need to move slightly the cursor in order to click on the small X icon. I cannot close for example six tabs, without moving the cursor, by just clicking six times.

The tabs in Chrome, Firefox and Safari do not work like that. It is much faster to close multiple tabs in these applications.

I would certainly like to be able to close TB tabs using a keyboard shortcut. That’s pretty standard with any app that provides a tabbed interface. And it’s usually cmd+w (I don’t know why I would ever want to close the entire TB document with that shortcut, as it does right now)

If you’re figuring it out in the sense of its technical origin and possible solutions, obviously this is beyond my ken – except to say, good luck and Godspeed!

If you’re figuring it out in the sense of why people are raising it as a problem: it’s the minor but real inelegance of (a) having the number of tabs steadily proliferate, when you use one of these Inbox / stamp techniques, and (b) having the resulting close-the-tab chore be trickier than one would expect, because of the small target for mouse clicks.

I realize that (a) is the result of external add-ons rather than TB’s built-in functions, and that (b) could be the definition of a princess-and-pea issue. But that’s the question / problem as a I see it: an inelegance it would be nice to remove, by addressing either (a) or (b) – the proliferation of new tabs, or the detail-work involved in closing them.

I’ve built several test cases and haven’t been able to make my tabs proliferate; my tabs stay put. So, if someone could send a small sample case, that’d help.

The tabs proliferate only when you use the “Go to Inbox” bookmark.
demo.tbx (59.4 KB)

Here is another small sample TBX. Specs:

  • Created a new blank file called InboxTest.tbx
  • Created top-level container called Inbox Sample
  • Copied URL of that container, thus:
  • Put that URL into the send-to-inbox script we’ve been discussing.

Using the inbox script I added three items, Test 1, Test 2, Test 3. Each one of them generated a new tab. This is what I’m seeing in my normal working files too.

Hope this is useful in sleuthing it out.
InboxTest.tbx (53.9 KB)

For the sake of completeness, here is the script I am using to send items to the inbox, which at the moment is generating the extra tabs. I realize that the formatting may be messed up here, but in real life the script works fine, except for the extra-tab aspect.

Here goes:

property inboxURL : “tinderbox://InboxTest/?view=outline+select=1493148611;”

set the clipboard to “”
tell application “System Events”
set frontmostProcess to first process where it is frontmost
end tell

display dialog “Enter the title of the note:” default answer “” buttons {“Enter additionally the body of the note”, “OK”, “Cancel”} default button 2

copy the result as list to {titleBody, theTitle}

if titleBody is equal to “Enter additionally the body of the note” then
set theText to text returned of (display dialog “Enter the body of the note.” default answer “”)
set the clipboard to theTitle & return & theText
set the clipboard to theTitle
end if

tell application “Tinderbox 7”
–open the Inbox container
do shell script "open " & inboxURL
delay 0.5

tell application “System Events”
key code 125 using {shift down, command down} --arrow down
end tell
end tell

tell application “System Events”
keystroke “v” using {command down}
delay 0.5
key code 53 --Esc
end tell
delay 1
– return to the previous app
tell application “System Events”
set frontmost of frontmostProcess to true
end tell"

Forget the script, it has nothing to do with the script.

  1. Create a document
  2. Create a note
  3. Copy the note URL
  4. Open Safari, paste the URL, press enter (answer the security dialog to “Allow”)
  5. Tinderbox will open, press ⇧⌘↓ [View > Focus View]
  6. Repeat from step 4

You’ll get a duplicate tab every time you repeat from step 4

I.e…, when the frontmost tab in a Tinderbox window is in Focus View, the URL causes Tinderbox to open a new tab that is itself focused on the note that the URL is homed to.

PaulWalters: could you set up a sample Tinderbox document for me up through step 4, and email it along with the tinderbox:// url? Sorry to be dense about this; there’s some fine point I’m managing to miss.

I have no idea of why this is so, but for some reason today, when I’ve been using the “send note to Inbox” script shown above, it has not created extra tabs. Go figure. I will try to give more refined diagnostic info.

Updating Again I can’t explain why, but a pattern that always happened before, with this script, is not happening at all now. Items are going straight into the Inbox container, without creating any new tabs.

I think it must be the new spirit in the US: Make Tinderbox Great Again! #MTGA !

What view are you working in, when the extra tabs get created?

If it’s an outline view: is the “target” note of the bookmark at the top level of the tab – that is, is the note you’ve bookmarked an immediate child of the tab’s parent note? Or is it more deeply indented?

It’s stupendous. So beautiful. We have so many people with huge brains working on it. I tell you, these guys are smart. Who would have known that Tinderbox was so complicated. Who would have known?

Ah, good sleuthing!

The intended container, the one that has the URL link, is at the second level of the hierarchy. The file is set up as:

  • CONTENT [root level container]

– INBOX [child of Content, second-level]

If a tab (in outline view) is set with focus on CONTENT when I run the script, an extra tab is created.
If the view in that tab is focused on INBOX itself, an extra tab is not created.

Haven’t tried this with other outline-level variations, but the simplest observation is: Yes, tab-creation is affected by whether the target container is at the top of the displayed level of a tab, or lower down.

Update more refined diagnostics:

  • If the tab is at the very top level of the file, so that the tab name just lists the file’s name and several top-level containers are visible in the outline view, running the script does create an extra tab
  • If the tab is focused on a top-level container, specifically DATA (parent of the target container), so that the tab’s name is “Outline: DATA” and the target container is in view, the script does not create an extra tab
  • If the tab is focused on the target container, INBOX, the script does not create the extra tab.

Over to you! MTGA

In my case, when I reproduce as I explained above, not using any scripts, the document looks like this:

“Index” is the note. tinderbox://Sample/?view=outline+select=1493233403; is the URL in question.