Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I was wondering how the window manager registers itself with the X server, and how it knows what process to kill when it goes about replacing the current window manager

share|improve this question
1  
The source code of dwm would be useful to read -- the whole window manager is just over 2000 lines, although lacking replace. Metacity's src/core/screen.c:322 too. (I'm only suggesting as a practical example, not as documentation.) – grawity Sep 8 '11 at 21:32
up vote 1 down vote accepted

X just keep waiting for the return of the process of wm/de. Suppose you have a line of exec awesome in your ~/.xinitrc. X will start and execute that line and monitor that process return. Try putting commands below of exec line, they'll never be parsed.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .