On Sep 1, 2011, at 5:34 AM, Matthew Flatt wrote: > At Wed, 31 Aug 2011 23:00:25 -0700, John Clements wrote: >> This doesn't work at all for me on the Mac, and highlights a problem that >> I've >> had at other times with racket & GUI frames: none of the keyboard input goes >> to the window. >> >> Specifically, here's the sequence of events: >> >> 1) run racket -W info -l- drracket >> 2) See splash window come up, *underneath* terminal window and not given >> focus. >> 3) See DrRacket frame come up, again without focus. >> 4) Click on DrRacket frame, it gets focus and I see the cursor blinking. >> 5) Type a few characters -- they don't show up in DrRacket. Instead, they go >> to the terminal window. >> Furthermore, there's no DrRacket menu bar, and no DrRacket icon in the >> cmd-tab >> list. >> >> 6) Go back to terminal window, use ctrl-\ to blow it away. >> >> Is that expected? It looks like the OS is preventing >> not-full-fledged-app-things from opening windows and handling input. This is >> OS 10.6,8. > > The code that is supposed to make the process a full-fledged app is > line at line 81 of "collects/mred/private/cocoa/queue.rkt": > > ;; In case we were started in an executable without a bundle, > ;; explicitly register with the dock so the application can receive > ;; keyboard events. > (define-cstruct _ProcessSerialNumber > ([highLongOfPSN _ulong] > [lowLongOfPSN _ulong])) > (define kCurrentProcess 2) > (define kProcessTransformToForegroundApplication 1) > (define-appserv TransformProcessType (_fun _ProcessSerialNumber-pointer > _uint32 > -> _OSStatus)) > (void (TransformProcessType (make-ProcessSerialNumber 0 kCurrentProcess) > kProcessTransformToForegroundApplication)) > > Note that the code ignores the result of `TransformProcessType', which > is a bad idea. If you remove the `void' wrapper, what number result > gets printed on your machine? >
Looks like it's -50. Here's the transcript: pcp070159pcs:~/plt clements$ racket -W info -l- drracket -50 Pango: couldn't load font "Apple Chancery Medium Not-Rotated 13", falling back to "Sans Medium Not-Rotated 13", expect ugly output. expanding-place.rkt: 01 starting thread expanding-place.rkt: 02 setting basic parameters expanding-place.rkt: 03 setting module language parameters expanding-place.rkt: 04 setting directories expanding-place.rkt: 05 installing security guard expanding-place.rkt: 06 setting uncaught-exception-handler expanding-place.rkt: 07 starting read-syntax expanding-place.rkt: 08 read expanding-place.rkt: 09 starting expansion expanding-place.rkt: 10 expanded expanding-place.rkt: 11 handlers finished expanding-place.rkt: 12 finished John
smime.p7s
Description: S/MIME cryptographic signature
_________________________________________________ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev