Numbering outlines

(Raymond Brock) #1

I would like to create a set of notes which each stand for numbered book sections within a container corresponding to a numbered chapter. I’m not convinced when I do this what the ordering will be so I’d like to do two, coupled things:

  1. I’d like to number the sections within the outline and if I move one, have it renumber automatically or because I invoke an agent or something…

  2. What would be cool, but that would probably magic, is to have that reordering change the physical layout of the map notes…

  3. or… less magical, that the number be reflected in the title so that I could then visually reorder the notes in the map.

So…can I do 1? and can I do 3? I’m sure you can see why this would be useful as a use case, but I couldn’t find evidence that this has been done.


(eastgate) #2

For #3, consider using $SiblingOrder in $DisplayExpression.

For #2, consider setting $Xpos and $Ypos depending on $SiblingOrder.

Outline export has lots of options for adding section numbers too, but of course that doesn’t change the display inside Tinderbox.

(Paul Walters) #3

Another method for getting an outline numbering that respects indention is to use this $DisplayExpression:

eval("^sectionNumber^") + " " + $Name

which you can include in a prototype and get a result such as this

Normally ^sectionNumber^ is export code, but with the eval() function you can cause action code to evaluate and display the result of export code.

(Mark Anderson) #4

I concur with this solution but be aware aliases, e.g. in agents, will show a different numbering from their original note. If the latter is unacceptable, happily it appears ^sectionNumber^ can use offset designators so this seems to work:

eval("^sectionNumber(original)^") + " " + $Name


(Tested in v7.3.1)