[racket] difference in handling window close with command-line racket and DrRacket?

From: George Oliver (georgeolivergo at gmail.com)
Date: Wed Jul 28 02:36:02 EDT 2010

hi,

I'm starting to work with a binding to a SDL-based library (on Windows 
XP) and have a strange bug. I've also been told the same bug is found on 
Linux.

When running a minimal example from the command line with 'racket 
<file>' the window close events (either by pressing Esc, a key handled 
in the code, or clicking the window close button) work normally. 
However, when running the same example from DrRacket (with ctrl-t), 
pressing Esc or the close button doesn't work, and I have to quit 
DrRacket to kill the window from the example.

Does anyone have an insight into this behaviour?

Unfortunately my working example is rather heavyweight, including a 
couple of libraries and only works on Windows, but I've made it 
available here and tried to include only the essential files:

http://bit.ly/racket_vs_DrRacket_window_close

Also I put the example in pastebin (about 30 lines) if that helps:

http://scheme.pastebin.com/bpr8Lu1a

This is an example I've cut down from the original one created by the 
library's author.


thanks, George




Posted on the users mailing list.