Re: [racket-dev] mouse motion events in Linux
Thanks! That page is clearer than the docs I read, though I still don't feel more enlightened. I did eventually conclude that GDK_POINTER_MOTION_HINT_MASK is orthogonal to GDK_POINTER_MOTION_MASK / GDK_BUTTON_MOTION_MASK, but adding it back seemed to have no effect on the mouse events that arrived. In particular, more mouse-move events arrive than just one after entering the window --- even without pressing a button or hitting a key. Maybe something internal to the Gtk widget implementation calls gdk_window_get_pointer(); in that case, I didn't want the mouse-event behavior to change (to generate less movement events than `racket/gui' intends to provide) if the Gtk widget changes to not call gdk_window_get_pointer(). More generally, since adding GDK_POINTER_MOTION_HINT_MASK didn't seem to change anything, the safest course seemed to be leaving it out. Does adding GDK_POINTER_MOTION_HINT_MASK change the mouse events that you see on your machine? At Sun, 17 Jul 2011 15:57:10 +0200, Stephan Houben wrote: > Hi Matthew, > > On 07/16/2011 10:31 PM, Matthew Flatt wrote: > > Short answer: change pushed. > > Thanks for picking this up. > > I see you also removed GDK_POINTER_MOTION_HINT_MASK , which > means we will be again seeing more motion events than before. > > Please note that GDK_POINTER_MOTION_HINT_MASK is really orthogonal to > GDK_POINTER_MOTION_MASK / GDK_BUTTON_MOTION_MASK . > > The latter selects in which cases motion events should be sent > (GDK_POINTER_MOTION_MASK == always, GDK_BUTTON_MOTION_MASK == only > when a mouse button is pressed). > > The former enables coalescing of motion events so that the application > doesn't see so many of them. GDK_POINTER_MOTION_HINT_MASK by itself > doesn't enable the sending of motion events. > > See also: > http://www.linuxtopia.org/online_books/gui_toolkit_guides/gtk+_gnome_application > _development/sec-gdkevent_5.html > > (Apology if you knew all this already). > > Note that this page states that if the motion events can be handled quickly > (under 5 ms), > then not using GDK_POINTER_MOTION_HINT_MASK may be preferable. > I guess most apps don't do anything with the motion events which is probably > quite fast indeed. > > Stephan _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] mouse motion events in Linux
Hi Matthew, On 07/16/2011 10:31 PM, Matthew Flatt wrote: > Short answer: change pushed. Thanks for picking this up. I see you also removed GDK_POINTER_MOTION_HINT_MASK , which means we will be again seeing more motion events than before. Please note that GDK_POINTER_MOTION_HINT_MASK is really orthogonal to GDK_POINTER_MOTION_MASK / GDK_BUTTON_MOTION_MASK . The latter selects in which cases motion events should be sent (GDK_POINTER_MOTION_MASK == always, GDK_BUTTON_MOTION_MASK == only when a mouse button is pressed). The former enables coalescing of motion events so that the application doesn't see so many of them. GDK_POINTER_MOTION_HINT_MASK by itself doesn't enable the sending of motion events. See also: http://www.linuxtopia.org/online_books/gui_toolkit_guides/gtk+_gnome_application_development/sec-gdkevent_5.html (Apology if you knew all this already). Note that this page states that if the motion events can be handled quickly (under 5 ms), then not using GDK_POINTER_MOTION_HINT_MASK may be preferable. I guess most apps don't do anything with the motion events which is probably quite fast indeed. Stephan _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] [plt] Push #23053: master branch updated
On Sat, Jul 16, 2011 at 10:52 PM, Robby Findler wrote: > Thanks for fixing the bug! > > On Sat, Jul 16, 2011 at 6:40 PM, Casey Klein > wrote: >> I tried to add a test case to >> collects/tests/racket/contract-test.rktl, but that file seems broken. >> In particular, `test/pos-blame' and `test/neg-blame' pass strings when >> `test/spec-failed' expects a symbol. Fixing that mismatch causes >> hundreds of existing tests to fail. > > They seem to work for me. I've pushed a new test case. > Here's what I tried: 1. I added this test, which should fail for identifying the wrong party: (test/neg-blame 'contract-arrow-wrong-number-values '((contract (-> integer? (values integer? integer?)) (lambda (x) (values 1)) 'pos 'neg) 1)) 2. From the directory containing contract-test.rktl, I ran: $ racket Welcome to Racket v5.1.2.3. > (load "contract-test.rktl") and got this message: Passed all tests. (Other messages report successful tests of error-handling behavior.) Those other messages contain this output for the new test: testing: contract-arrow-wrong-number-values ((contract (-> integer? (values integer? integer?)) (lambda (x) (values 1)) (quote pos) (quote neg)) 1) =e=> exception raised by exception handler: test/spec-failed: unknown blame name "neg"; original exception raised: self-contract violation: expected 2 values, returned 1 value contract from: pos, blaming: pos contract: (-> integer? (values integer? integer?)) _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] Racket DMG improvements
FWIW, I believe we build these things on a mac, so figuring out how to do that under linux is not necessary (for us). Robby On Sun, Jul 17, 2011 at 8:02 AM, Neil Van Dyke wrote: > Jakub Piotr Cłapa wrote at 07/17/2011 08:25 AM: >> >> Uncompressed HFS+ images may be mounted on Linux but I am not sure if >> there is a way to do it without being root. > > If you want to access a filesystem image file *as a Linux filesystem*, I > think you probably have to mount it with a "loop" device, which requires > either root/sudo privs, or perhaps a fixed path that can be put into > "/etc/fstab" with privs granted for normal users to mount it. (There is > another option, using FUSE, but I think "loop" will be easier.) > > I would guess that any building of HFS+ images would be done on OS X, > though. > > -- > http://www.neilvandyke.org/ > _ > For list-related administrative tasks: > http://lists.racket-lang.org/listinfo/dev _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] Racket DMG improvements
Jakub Piotr Cłapa wrote at 07/17/2011 08:25 AM: Uncompressed HFS+ images may be mounted on Linux but I am not sure if there is a way to do it without being root. If you want to access a filesystem image file *as a Linux filesystem*, I think you probably have to mount it with a "loop" device, which requires either root/sudo privs, or perhaps a fixed path that can be put into "/etc/fstab" with privs granted for normal users to mount it. (There is another option, using FUSE, but I think "loop" will be easier.) I would guess that any building of HFS+ images would be done on OS X, though. -- http://www.neilvandyke.org/ _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] Racket DMG improvements
On Sun, Jul 17, 2011 at 7:25 AM, Jakub Piotr Cłapa wrote: > [1]: > http://stackoverflow.com/questions/96882/how-do-i-create-a-nice-looking-dmg-for-mac-os-x-using-command-line-tools Mecki's answer here sounds just perfect for us, since we only really need one (or three, I suppose). Robby _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] Racket DMG improvements
I believe that making dmg files is quite difficult without OS X. The way to go is (confirmed here: [1]) is to create a template with the background and icons in place and then replace the contents of the disk image without touching the saved metadata. Uncompressed HFS+ images may be mounted on Linux but I am not sure if there is a way to do it without being root. I believe there is a problem with compressing .dmg images without OS X. But these guys [2] seem to have some solution based on [3]. [1]: http://stackoverflow.com/questions/96882/how-do-i-create-a-nice-looking-dmg-for-mac-os-x-using-command-line-tools [2]: http://svn.dmdirc.com/trunk/installer/osx/makeInstallerOSX.sh [3]: https://github.com/planetbeing/libdmg-hfsplus -- regards, Jakub Piotr Cłapa _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev