This function deletes the widget. It will remove all callbacks attached to it as well. If the widget class has a defined destructor, then it is called. The class instance object is marked as a destroyed instance type and the memory used for the widget is recovered the next time the garbage collector runs.
Gamma> PtInit(nil);
t
Gamma> win = new(PtWindow);
window instance definition
Gamma> PtDestroyWidget(win);
t