Path: utzoo!news-server.csri.toronto.edu!rutgers!dimacs.rutgers.edu!seismo!uunet!orca!mesa!rthomson From: rthomson@mesa.dsd.es.com (Rich Thomson) Newsgroups: comp.windows.x Subject: Re: running while iconized Message-ID: <1991Mar15.061005.6431@dsd.es.com> Date: 15 Mar 91 06:10:05 GMT References: <1991Mar14.232039.1950@unixg.ubc.ca> Sender: usenet@dsd.es.com Reply-To: rthomson@dsd.es.com (Rich Thomson) Organization: Design Systems Division, Evans & Sutherland, SLC, UT Lines: 30 Nntp-Posting-Host: 130.187.85.21 In article <1991Mar14.232039.1950@unixg.ubc.ca> lindholm@greve.ucs.ubc.ca (George Lindholm) writes: >What do I have to do so that my program can run while iconized? I've usually seen the state referred to as "iconified", or "iconic state". Anyway, you're program continues to run as usual when you're application has been iconified by the window manager. You will get an unmap event and a property notify event (if you're window manager is ICCCM compliant you'll get an event notifying you that your WM_STATE property has changed). What the window manager does is to unmap the application window and map (or create and map) the icon window. Since your application's window is unmapped, all output to the window will not appear on the screen. Your application will continue to run however; the window manager doesn't do anything to the process that created the window (and quite possibly couldn't even if it wanted to -- the process could be running quite literally on another continent). Now, if you're asking how to get button events, key presses, etc. when you're application is iconified, you can get the window ID of the icon window and select for input on that window like any other window. Whether or not this is a good idea remains an open question. -- Rich -- ``Read my MIPS -- no new VAXes!!'' -- George Bush after sniffing freon Disclaimer: I speak for myself, except as noted. UUCP: ...!uunet!dsd.es.com!rthomson Rich Thomson ARPA: rthomson@dsd.es.com PEXt Programmer