back to Tcl/Tk page       source: bgcanv.tcl get the Tcl/Tk plug-in

This script generates a family of shapes, where the sliders control the two parameters to the "xor" calculation.  Since it's a Tcl/Tk script, it runs under the Tcl/Tk browser plug-in.

Here's a screen shot: .

The "Random" button or <space> bar generates a random shape.
The "Sym" button or <enter> key generates a symmetrical (random) shape.
The "Animate" button or <s> key starts generating a random shape every second. (click it again to turn it off)
The -> and <- buttons or arrow keys cycle through the list of pre-sets.
The <f> key flips right/left.

The code button (also <e> key) causes an exception, because it can't find the source file to display it. Also, it uses a pop-up window to show the code, and pop-ups are not available from the browser safe subset. If you run it with "wish", the code button works, and there's a mouse menu too.

  back