RS-6000 (there is an elegant way to kill "X")

Peter A. Castro peter at dbaccess.com
Wed Sep 19 09:06:11 AEST 1990


in article <IVAN%NEFX4.90Sep15181026 at nefx4.ncsuvx.ncsu.edu>, ivan%nefx4 at ncsuvx.ncsu.edu (Ivan Maldonado) says:
> In-reply-to: rudy at chukran.austin.ibm.com's message of 14 Sep 90 22:02:08 GMT
> 
> 
> On 14 Sep 90 22:02:08 GMT,
> rudy at chukran.austin.ibm.com said:
> 
>> I just kill mwm with the menu popdown provided.  
>> I startup X with "open xinit".
>> the last thing in xinitrc is "exec mwm", therefore mwm becomes the
>> process group
>> leader for the virtual terminal.   When mwm exits, all her children get
>> a SIGHUP,
>> including X.   No nasty messages about server killed either.
> 
> Thank you, this works much more neatly.  One thing, however, 
> the menu popdown I get (the same one used to open a new window) 
> has a "restart mwm" option, and not a "kill mwm".  So I end up
> using "ps -a" and then "kill PID(mwm)".  No "broken pipes" just
> like you said.

   There should be another menu item called "Exit MWM" (at the bottom, just
   after the Restart item).  This item does the kill of the mwm for you
   and cleans up things.  You should have a .mwmrc file in your home 
   directory.  If not, you can get a copy of the system one.  It should be
   in /usr/lib/X11/system.mwmrc.
   Here is an example of the RootMenu with the Exit MWM item:
    
   # Root Menu Description
   Menu RootMenu
   {
       "Root Menu"	f.title
       no-label		f.separator
       "New Window"	f.exec "aixterm &"
       "Shuffle Up"	f.circle_up
       "Shuffle Down"	f.circle_down
       "Refresh"	f.refresh
       no-label		f.separator
       "InfoExplorer"	f.exec "info -g"
       "xclock"		f.menu Xclocks
       "xbiff"		f.exec "xbiff &"
       no-label		f.separator
       "Backgrounds.."	f.menu Backgrounds
       no-label		f.separator
       "Restart..."	f.restart
       "Exit MWM"	f.quit_mwm
   }

   Just like the Restart prompts you for restarting the MWM, the Exit MWM
   item prompts you to quit the mwm (Yes or No? ).

> 
> -Ivan
> 
> 
> --
> ------------------------------------------------------------------------------
> | Guillermo Ivan Maldonado           |  Internet: ivan%nefx4 at ncsuvx.ncsu.edu |
> | Department of Nuclear Engineering  |  BITNET  : maldonado at ncsune           |
> | North Carolina State University    |----------------------------------------
> | NCSU Box # 7909                    |   ... que viva Quito !                |
> | Raleigh. NC 27606-7909             |         ... que viva el ECUADOR !!    |
> ------------------------------------------------------------------------------
-- 
Peter A. Castro                   INTERNET: peter at dbaccess.com        // //|
c/o DB/Access Inc.                UUCP: {uunet,mips}!troi!peter      // //||
2900 Gordon Avenue, Suite 101     FAX: (408) 735-0328            \\ // //-||-
Santa Clara, CA 95051-0718        TEL: (408) 735-7545             \// //  ||



More information about the Comp.unix.aix mailing list