Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!iuvax!purdue!bu-cs!bloom-beacon!SAM.CS.CMU.EDU!Francois.Bitz From: Francois.Bitz@SAM.CS.CMU.EDU Newsgroups: comp.windows.x Subject: getting CONTROL C to interrupt X application Message-ID: <8908231747.AA20273@ATHENA.MIT.EDU> Date: 23 Aug 89 17:46:53 GMT Organization: The Internet Lines: 28 I am trying to find a way to be able to 'stop' an X program by typing CONTROL C such as can be done with any other 'C' program. Actually I want to use the SIGINT that is generated by such an action to 'jump' somewhere in my program. This is sometimes necessary when displaying (or computing) lots of stuff that might takea long time and the user wants to stop (abort) it . The problem I have is that when I type CONTROL C in the windows created by my application (which uses SelectInput with KeyPressedMask) no SIGINT is generated (although when I read the bufffer I can see that there is a CONTROL C in it). If I typed CONTROL C in the xterm shell where I started my application, then I can get a SIGINT; but this is not a good solution since the startup shell is sometimes masked by the application (or could be on another machine). Alternatively is there a 'simple' way to write a small X program with a button which when clicked could 'send' a 'signal' to my application. Are there any signals which can be generated by the X server; or between X clients ? I hope my message is not too confusing; It might be related to a question somebody asked about running 'X' processes in parallel without having to fork (this being op. sys. dependant). Thanks