Steve Spicklemire figured out a much simpler scheme for VPython-wx which
eliminates the strange "double import" structure I had created, in which
you import visual, and visual imports you.
Instead, he uses the "atexit" module to define a function to be called at
the end of a Python program. That end-of-program function enters and
endless while loop containing rate(30), which keeps the graphics window
alive for zoom and spin. There is no double import.
Many thanks, Steve!
Bruce Sherwood
|