       mainloop
              This  procedure sets up a top-level event loop.  Events are pro-
              cessed until there are no more active event  sources,  at  which
              time the process exits.  It is used to build event oriented pro-
              grams using the TclX shell in a style similar to that used  with
              wish.   If  the global variable tcl_interactive exists and has a
              true value an interactive command handler is  started  as  well.
              If the command handler is terminated by an EOF, the process will
              be exited.
