Path: utzoo!news-server.csri.toronto.edu!cs.utexas.edu!uunet!ora!bloom-beacon!dont-send-mail-to-path-lines From: dshr@eng.sun.COM (David Rosenthal) Newsgroups: comp.windows.x Subject: Re: Warping the pointer and social behaviour Message-ID: <9103162058.AA13921@devnull.Eng.Sun.COM> Date: 16 Mar 91 20:46:37 GMT Sender: daemon@athena.mit.edu (Mr Background) Organization: The Internet Lines: 58 > Certainly one should not randomly warp the pointer around, however there are > cases where pointer warping is necessary, and it is not just toolkit writers > who may need to do it. For example, suppose you are writing a client which > requires a choice be made on startup for proper functionality. In this case > it seems to me reasonable to popup a menu of choices and warp the pointer to > the menu. Sure, the rest of the functionality of the client should be > defined such that until this choice is made a warning is given. However, > the warping is a strong way of indicating to the user that the choice must > be made. You might reply that the warning should suffice, and that the > warping is anti-social. However, in my experience naive users find warning > messages to make a choice, when they try any action in a widget, far more > annoying than warping the pointer to a popup on startup. > > (Note: to minimise conflict with other applications, such warping as I > mentioned above should only take place if the pointer is within the bounds > of the top level window for the application. So, what one should do is have > an entry action for the top level window which checks to see if the > selection has been made, and if not pops up the popup (if not already popped > up) and warps the pointer.) This is not a sensible approach: 1. The client's top-level window appears some time after the action is taken to start the application. I hope you are not suggesting that when the client finally gets started it should randomly attempt to sieze the pointer away from whatever is happening then and pop something up. That would be seriously anti-social. It sounds to me as though you are stuck in PC/Mac thinking, where there is only one application running at a time and nothing else can happen between the user's actions to start an app and the time it grabs the screen, keyboard and mouse for its exclusive use. 2. Popups should be implemented by the toolkit. All toolkits I've seen implement them. So that if, in the particular user interface style the toolkit writer is implementing, warping the pointer to a pop-up is the right thing to do, the toolkit writer should do it. The toolkit writer should understand the need to grab the server when it happens, and all the other details. The application writer should *not* be trying to do this - they should use whatever popups are provided by their toolkit. 3. If the user tries to do something that doesn't work in the current state of the client, it is appropriate to popup a warning and prevent them from doing anything else until it has been dealt with. It is very anti-social to prevent them from doing anything with other clients while this happens. Thus, the grabs necessary to deal with pointer warping should be used with extreme caution because they may prevent the user working with anotehr application while you have the pointer warped. To repeat my original point - application writers should never warp the pointer. Toolkit writers may warp the pointer under controlled circumstances, such as when implementing popup warnings and scrollbars, but should always do it with the src-window set as required by the ICCCM. David.