It probably helps to understand that however you are used to viewing your document, it’s structure (in the TBX) is as seen in the Outline. IOW, open outline view at root and expand all the branches. Numbering in visible vertical order (i.e. down each branch in order before backtracking to the next branching point, etc.) is the ‘outline order’ $OutlineOrder.
If in doubt, this is what Tinderbox falls back upon. Two notes with the same name?† In an agent both will be listed, but in much action code, silently Tinderbox will match the first-by-$OutlineOrder.
Different views, if switching view type within the current tab, use the same scope. So, say my Outline is at root-level (i.e. showing everything) and I select note as path /B/bb/bb1 and then switch the tab to Map view. The map displays the root map, showing container ‘B’ and the text pane shows ‘bb1’ even though the selected item is not visible in the Map.
Why? A map only shows the sibling children of a single container - in this case the root-level map.
If I repeat the above but select notes at path B and /B/bb/bb1, the map would show container ‘B’ selected and the text pane would show a list of 2 items ‘B’ and ‘bb1’. At this point ‘bb1’ is selected even though we can’t see it.
I think it likely that selections are likely to hold their listing (the path or IDs of those items) in outline order, as opposed to the order (manually) selected. For action code work that would certainly be a sensible assumption.
Note that map X/Y position or presumed left-to-right/top-to-bottom order is not connected those the outline order, although the Z-order (overlapping order) is the $OultineOrder. See more.
Different tabs in the same window can have different selections. There is no mechanism to tell tab A to adopt tab B’s selection (other than via possible using AppleScript).
If there are two or more windows open, the front tab of each will take the (changed) selection of the current tab of the active window. There is a cromulent reason why, but let’s avoid that rabbit hole. So using 2 windows to see 2 views at once, comes at the cost of the selection being the same in both windows.
FWIW, there isn’t an order in Timeline view. There are 3 sets of in-scope (i.e. under the root container) notes:
- those with no date
- those whose date is before/after the (optional) start/end dates of the view
- those with dates in range drawing in dateline order: oldest date (left) to newest date right
Further points when leaning on one’s expectations of what should happen:
- different users employ different views and use them different way
- intuition generally doesn’t scale
- user A’s choice/need of behaviour may completely wreck user B’s longstanding usage. This is why changes of this sort aren’t rushed into.
As view (changed in current tab) keeps scope, selection changing the new views scope likely hits bullet #3 above.
I think sorting out a command/shortcut to scroll the current selection to view on the Map before widening the request makes sense. This map thing is a long-running head scratcher. ISTM delaying to find out why the map isn’t showing what the user expects is false quest. This issue has been round for over a decade. It seems simpler, given an assumption the the selection (or at least one item) is selected on the current map to check it is in visible bounds and if not, to scroll the map so it is. Indeed, such a feature might allow the app indicate to itself where/when its view-area guess and the user’s differ.
†. Possible, as each note (and alias) has a discrete ID value ($ID).