
On Feb 11, 2008, at 6:35 , Andrea Rossato wrote:
Basically, I'm going to use what Brandon suggested: check for a button event on the lower right corner of the window (I'm thinking about a 4 pixels wide square).
The problem is that the window's mask doesn't include button press events. Now I'm puzzled (due to my ignorance): should I change that? should I add some other decorations in the window's corners and set their event mask?
The usual way to do this is to place a transparent window (InputOnly, often called an "event window") over the place where you want to intercept clicks and select for ButtonPress on it. Selecting for ButtonPress on the whole window (a) requires you to calculate whether to pay attention to it or not (b) complicates things when the application owning the window is *also* selecting for ButtonPress in the same area. -- brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery@kf8nh.com system administrator [openafs,heimdal,too many hats] allbery@ece.cmu.edu electrical and computer engineering, carnegie mellon university KF8NH