[racket] Fwd: gui application open without frame?

From: Louis-Philippe (default at spiralix.org)
Date: Mon Nov 21 15:36:56 EST 2011

thanks, I just also found this...
but anyway, I realised the root menu is really only usefull in OSX...
 won't rely on it...


2011/11/21 Matthew Flatt <mflatt at cs.utah.edu>

> You need to install a quit handler via `application-quit-handler'.
> The quit handler is invoked by the "Quit" menu item.
>
> At Mon, 21 Nov 2011 15:08:37 -0500, Louis-Philippe wrote:
> > right now, having
> > (yield (make-semaphore))
> > at the end of my program, the application doesn't exit and my root
> menu-bar
> > stays...  but the quit menu doesn't work anymore...  should I override
> it,
> > but with what, or am I missing something?
> >
> > thanks!
> >
> > 2011/11/21 Matthew Flatt <mflatt at cs.utah.edu>
> >
> > > At Mon, 21 Nov 2011 13:40:06 -0500, Louis-Philippe wrote:
> > > > I looked around the docs for racket/gui and I can't find how to do
> > > > something very basic...  how can I leave a racket/gui app opened
> after
> > > all
> > > > windows have closed so that the root menu-bar can stay visible?
> > >
> > > You'll need to add a call to `yield' to the end of your program to wait
> > > until your application quit handler exits. For example, you might add
> > >
> > >  (yield (make-semaphore))
> > >
> > > assuming that your quit handler exits via `exit', or you could use
> > >
> > >  (define s (make-semaphore))
> > >  (yield s)
> > >
> > > with a quit handler that exits via `(semaphore-post s)'.
> > >
> > >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20111121/6b46737c/attachment.html>

Posted on the users mailing list.