home | help
mcwm(1) 								 mcwm(1)

NAME
     mcwm - MC's Window Manager for X11.

SYNOPSIS
     mcwm  [ -b width ] [ -i ] [ -t terminal-program ] [ -f colour ] [ -u colour
     ] [ -x colour ]

DESCRIPTION
     mcwm is a window manager for the X Window System.

OPTIONS
     -b width sets border width to this many pixels.

     -i turns on icons/hidden windows.	Please note that there is  no  way  from
     mcwm  to get a hidden window back! You have to use an external program such
     as a panel or the mcicon or 9icon scripts (see below)  to	get  the  window
     mapped again.

     -t  urxvt	will start urxvt when MODKEY + Return is pressed. Change to your
     prefered terminal program or something else entirely.

     -f colour sets border colour for focused window to a named colour, such  as
     "red".

     -u colour sets border colour for unfocused windows.

     -x  colour  sets border colour for fixed windows, that is, windows that are
     visible on all workspaces.

USE
     Nota bene: For mcwm to be at all useful you need to know how what keys gen-
     erate the Mod1 and Mod4 modifier masks (default). If you  don't  know,  use
     xmodmap(1)  with the -pm option to list them. If you don't want to use Mod1
     and Mod4, you can change the modifiers in the file config.h and recompile.

     With the the default configuration, use mcwm like this.

     Mod1 + mouse buttons:

	    * 1 move

	    * 2 raise or lower

	    * 3 resize window

     Note that the mouse cursor needs to be inside the window you want to  move,
     raise/lower  or  resize  even if it currently has the focus. This is a fea-
     ture, not a bug.

     Mod4 + key on focused window:

	    * r raise or lower (toggles).

	    * x maximize (toggles).

	    * m maximize vertically (toggles).

	    * H resize left.

	    * J resize down.

	    * K resize up.

	    * L resize right.

	    * h move left.

	    * j move down.

	    * k move up.

	    * l move right.

	    * y move to upper left corner of monitor.

	    * u move  to upper right corner of monitor.

	    * b move to lower left corner of monitor.

	    * n move to lower right corner of monitor.

	    * Return start terminal or whatever program you have configured with
	      -t or in the config.h.

	    * Tab go to next window in the current workspace window ring. If you
	      release MODKEY or press another command key mcwm will change focus
	      to the new window. A new press of MODKEY + Tab will bring you back
	      to the window where you last had focus.

	    * Shift-Tab go to previous window in the  current  workspace  window
	      ring.  This  is most useful while you are tabbing: if you acciden-
	      tally pressed Tab one time too many, you can move back by pressing
	      Shift + TAB (all the while holding down the MODKEY).

	    * f fix window so it is visible on all  workspaces	(toggles).  Note
	      that  this  is also used to move windows between workspaces: First
	      fix the window, change to the workspace you want, then  unfix  the
	      window on the new workspace.

	    * i iconify (or hide) window from the display. Only usable when mcwm
	      has  been started with -i. Currently there is no way to get a hid-
	      den window back. You have to use an external  program  such  as  a
	      panel or the mcicon or 9icon script in the mcwm distribution.

	    * 0-9 go to workspace n, 0-9.

	    * c go to previous workspace.

	    * v go to next workspace.

	    * End close window.

	    * , move window to previous monitor.

	    * .  move window to next monitor.

     Note  that  all functions activated from the keyboard work on the currently
     focused window regardless of the position of the mouse cursor.  Of  course,
     changing workspaces has nothing to do with the focused window.

     If  you  don't like the default key bindings, border width, et cetera, look
     in the config.h file, change and recompile. In the config.h  file	you  can
     also  define  mouse  button actions on the root window. By default button 3
     starts the command mcmenu. You can write your own mcmenu by using, for  in-
     stance, 9menu, dmenu or ratmenu.

ENVIRONMENT
     mcwm obeys the $DISPLAY variable.

STARTING
     Typically	the  window  manager  is  started  from  a script, either run by
     startx(1) or a login manager such as xdm(1).

     If you start from the console, you need an .xinitrc file. Here's a complete
     example:

	 #! /bin/sh

	 # Set nice background.
	 xsetroot -solid grey20

	 # Set nice pointer cursor.
	 xsetroot -cursor_name plus -fg white -bg black

	 # Load resources.
	 xrdb -load ~/.Xresources

	 # Start window manager in the background. If it dies, X still lives.
	 mcwm &

	 # If you want to allow windows to be hidden, use this instead:
	 # mcwm -i &

	 # Start a terminal in the foreground. If this dies, X dies.
	 exec urxvt

SCRIPTS
     You may want to define a menu program for use with mcwm (see config.h).  In
     the source distribution you can find an example as mcmenu (the default menu
     program in config.h) in the scripts directory.

     Christian	Neukirchen  wrote  a  little script you can use to get iconified
     windows mapped again if you are running mcwm in allow icons mode (-i).  You
     need awk, xdotool, xprop and xwininfo installed. You can find the script as
     scripts/9icon.

     Inspired  by  Christian's work I wrote a small program, hidden(1), which is
     included with mcwm. You can use hidden(1) with the -c option together  with
     9menu. See scripts/mcicon for an example.

     You  might  also  be  interested in the following shell function that might
     come in handy to give your terminal emulators  good  titles  before  hiding
     them.

	 # Set the title and icon name of an xterm or clone.
	 function title
	 {
	     # icon name
	     echo -e '\033]1;'$1'\007'
	     # title
	     echo -e '\033]2;'$1'\007'
	 }

     Use it like this:

	 % title 'really descriptive title'

SEE ALSO
     hidden(1)

AUTHOR
     Michael Cardell Widerkrantz <mc@hack.org>.

				  Apr 30, 2012				 mcwm(1)

home | help