Magic button functionality
Not logged in

The name and idea for this functionality comes from the Notebook application written by William Duquette at This functionality allows a node in an outline to be made into a "button" that when clicked will execute all its descendents' text as a Tcl script. The script is executed in the context of the current outline just as if it were typed into the console (see Scripting tkoutline).

I have used this magic button functionality in the following ways:

SEH 12Aug05: There doesn't seem to be any description anywhere of how to turn a link into a magic button. By looking at the saved text file of the "Magic button functionality" page, I surmise that you enclose the link text in a square-bracket/percent-sign combination; i.e., typing %console show% in a node will turn the enclosed text into a magic button (displayed in lavender).

Brian Theado: Thanks for pointing that out. The "Magic button functionality" page should describe how to do it and it doesn't. In addition to explicitly typing those characters, you can also hit Ctrl-m to automatically insert those characters (for the entire node or for the selected text). The current released version (0.93) operates slightly different than the current development version. Version 0.93 only executes code in the descendents. The development version will execute the actual text of the magic button if there are no descendents. For example:

will behave the same as