window.visit

Syntax window.visit (visitProc)

Params visitProc is the address of a script that is to be applied to each open window in turn.

Action Visits each open window and applies the procedures in visitProc to it.

Returns The results of the execution of visitProc on the last window visited. As long as visitProc returns true, the process of visiting open windows continues. If visitProc returns false, the processing terminates and the verb returns false.

Examples edit (@examples.cleanupWindows)
This example script demonstrates the use of window.visit to organize all of the open windows in your Frontier environment so that they stack neatly beginning in the upper left corner of your screen. A local script called cleanupvisit is defined, with the
name of the window as a parameter. This local script is then called from the final line in the script as an argument to the window.visit verb.

Here is the listing of this script:
on cleanupvisit (wname)

if wname == "frontier.root"

window.setPosition (wname,10,20)

else

window.setPosition (wname, h, v)

window.setSize (wname,300, 200)

h = h + 20

v = v + 20

return (true)

window.visit (@cleanupvisit)

Discuss