tiling.nv
· 1.4 KiB · Text
Bruto
Playground
|:: focus on node $n :focus: $|
:: ensure node $n exists
:focus: $n
|:: focus on node $n|
:: ensure node $n exists
:focus: $n
||:nodes: root horizontal
|:: create a node under root :unique ID: $x?|
:: go to the next unique ID
:edges: root $x
:nodes: $x horizontal
|:: create a node under $n :unique ID: $x?|
:: ensure node $n exists
:: go to the next unique ID
:edges: $n $x
:nodes: $x horizontal
|:: set node $n to use a $s split :nodes: $n $|
:nodes: $n $s
:: reset nodes
|:: set node $n to use a $s split :not found: $n|
:: error :message: $n is not a node
|:: set node $n to use a $s split?|
:: find node $n
|:: find node $n :nodes: $n $?|
|:: find node $n? :nodes: $x $y|
:checked nodes: $x $y
|:: find node $n|
:not found: $n
:: reset nodes
|:: ensure node $n exists :not found: $n|
:: error :message: $n is not a node
|:: ensure node $n exists :nodes: $n $?|
:: reset nodes
|:: ensure node $n exists?|
:: find node $n
|:: reset nodes? :checked nodes: $x $y|
:nodes: $x $y
|:: reset nodes|
||:unique ID: 0
|:: go to the next unique ID :@math: $x|
:unique ID: $x
|:: go to the next unique ID? :unique ID: $n|
:@math: add $n 1
||:: create a node under root
:: create a node under 0
:: create a node under 0
:: create a node under 1
:: create a node under 3
:: set node 0 to use a vertical split
:: set node 3 to use a vertical split
| 1 | |:: focus on node $n :focus: $| |
| 2 | :: ensure node $n exists |
| 3 | :focus: $n |
| 4 | |:: focus on node $n| |
| 5 | :: ensure node $n exists |
| 6 | :focus: $n |
| 7 | |
| 8 | ||:nodes: root horizontal |
| 9 | |:: create a node under root :unique ID: $x?| |
| 10 | :: go to the next unique ID |
| 11 | :edges: root $x |
| 12 | :nodes: $x horizontal |
| 13 | |:: create a node under $n :unique ID: $x?| |
| 14 | :: ensure node $n exists |
| 15 | :: go to the next unique ID |
| 16 | :edges: $n $x |
| 17 | :nodes: $x horizontal |
| 18 | |
| 19 | |:: set node $n to use a $s split :nodes: $n $| |
| 20 | :nodes: $n $s |
| 21 | :: reset nodes |
| 22 | |:: set node $n to use a $s split :not found: $n| |
| 23 | :: error :message: $n is not a node |
| 24 | |:: set node $n to use a $s split?| |
| 25 | :: find node $n |
| 26 | |
| 27 | |:: find node $n :nodes: $n $?| |
| 28 | |:: find node $n? :nodes: $x $y| |
| 29 | :checked nodes: $x $y |
| 30 | |:: find node $n| |
| 31 | :not found: $n |
| 32 | :: reset nodes |
| 33 | |
| 34 | |:: ensure node $n exists :not found: $n| |
| 35 | :: error :message: $n is not a node |
| 36 | |:: ensure node $n exists :nodes: $n $?| |
| 37 | :: reset nodes |
| 38 | |:: ensure node $n exists?| |
| 39 | :: find node $n |
| 40 | |
| 41 | |:: reset nodes? :checked nodes: $x $y| |
| 42 | :nodes: $x $y |
| 43 | |:: reset nodes| |
| 44 | |
| 45 | ||:unique ID: 0 |
| 46 | |:: go to the next unique ID :@math: $x| |
| 47 | :unique ID: $x |
| 48 | |:: go to the next unique ID? :unique ID: $n| |
| 49 | :@math: add $n 1 |
| 50 | |
| 51 | ||:: create a node under root |
| 52 | :: create a node under 0 |
| 53 | :: create a node under 0 |
| 54 | :: create a node under 1 |
| 55 | :: create a node under 3 |
| 56 | :: set node 0 to use a vertical split |
| 57 | :: set node 3 to use a vertical split |