avr@cs.purdue.EDU (Andrew V. Royappa) (05/17/91)
Hi, I am writing an application that opens both X and NeWS windows (in one process). I wish to receive input events from both X and NeWS windows. Currently, the program sits in a busy loop polling both X and NeWS event queues, which degrades the application's performance tremendously. However, X provides a file descriptor for each display connection: a program can call select() on that descriptor to wait for events. If NeWS also provided such a file descriptor to test for input, the program could use select() to wait for both NeWS and X events, thus eliminating the busy wait. Can anyone tell me if such a file descriptor is used by NeWS programs, and if so, how a user can access it ? Assuming, of course, that it's not a static variable in some library, or something like that. I understand that there will be a merged NeWS/X server, or perhaps just a single X server, in the near future. However, we can't wait until then. Thanks very much for your time. Andrew V. Royappa avr@purdue.edu {decvax,ucbvax,pur-ee}!purdue!avr