[Haskell-cafe] Exiting GLUT application
Marc A. Ziegert
coeus at gmx.de
Tue Jul 31 17:16:02 EDT 2007
in old glut, the main loop was the core of the single threaded program. exiting it did mean to exit the program completely.
in freeglut, you have alternatives. but for compatibility, it defaults to the old behaviour.
<http://haskell.org/ghc/docs/latest/html/libraries/GLUT/Graphics-UI-GLUT-Begin.html#v%3AExit>
- marc
Am Dienstag, 31. Juli 2007 19:16 schrieb Dave Tapley:
> Hi everyone, I have the following skeleton GLUT code:
>
> > import Graphics.UI.GLUT
> > main = do
> > getArgsAndInitialize
> > createWindow ""
> > mainLoop
>
> It loads into both hugs and ghci fine and when 'main' is evaluated an
> empty window opens as expected.
> However when closing the window (clicking the window manager's x
> button) both hugs and ghci exit with the window, as opposed to
> returning to the the 'Main>' prompt.
>
> I suspect I need some callback to exit the GUI cleanly?
>
> Cheers,
> Dave
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://www.haskell.org/pipermail/haskell-cafe/attachments/20070731/56ec824d/attachment.bin
More information about the Haskell-Cafe
mailing list