Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!know!zaphod.mps.ohio-state.edu!usc!ucsd!ucbvax!hbo.UUCP!bice From: bice@hbo.UUCP (Brent A. Bice) Newsgroups: comp.windows.news Subject: Hunh? Message-ID: <9007161732.AA01251@> Date: 19 Jul 90 06:43:56 GMT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 37 I've got a strange question. I have a window that has a menu. One menu entry I want to have a function that will spawn a completely independent window. When the main window gets Zap'd, it should go away, but not kill the window/s that it spawned. I have a piece of code that does this, but the main window won't die until all of the other window/s that it spawned also are zapped. Howcomeforwhy? Am I missin' somethin' here? /MainDict /ThisIsIt def % Make a window with a new processgroup and a clean environment. /makewin { { % Clean up dictionary stack { currentdict /MainDict known { exit } if end } loop clear % clean up regular stack newprocessgroup framebuffer /new LiteWindow send dup /reshapefromuser exch send /map exch send } fork pop } def % Here's the main window. It has a menu entry that merely calls makewin. framebuffer /new LiteWindow send dup { /ClientMenu [ (MAKEWIN) { makewin } ] /new DefaultMenu send def } exch send dup /reshapefromuser exch send /map exch send