alloywm: The Metallic Window Manager, by Kensuke Otake
Original 9wm code by David Hogan
Original aewm code by Decklin Foster
Version 0.4.0

Table of Contents
-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+

I.  Preamble
	1.  About alloywm
	2.  Getting to know alloywm
II.  Compiling and installing alloywm
	1.  Unpacking
	2.  Configuring
	3.  Compiling
III.  Using alloywm
	1.  Mouse/Window functions
	2.  Command-line Options
	3.  Configuration
	4.  Miscellaneous
	5.  Keyboard control
IV.  Foreclosure
	1.  Bugs
	2.  Changelog
	3.  To Do
	4.  About the Author
	5.  Mindless Legal Garbage

I. Preamble
-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+

1.  About alloywm

As its name implies, alloywm is a quite exquisite, aesthetic little window
manager for X11.  The premise of this window manager is not to be
over-bloated like better known window managers such as KDE, and to keep
the interface out of a user's way.  Also, alloywm maintains to be small,
fast, and have a really small memory footprint.

I first decided to adopt this window manager as a testbed for programming
in C for X11, because I was mainly a non-graphical programmer for a long
time.  It is not very configurable, thusly you would have to edit the
sourcecode to add any functionality, to bend it to your likings.

2.  Getting to know alloywm

The window manager feels like a Macintosh GUI interface, except that you
cannot click inside the window to give focus (that will change, soon.)
A new window is drawn wherever the mouse happens to be.  So, in other
words, if I run an rxvt, and the mouse is in the centre, then the top-left
hand corner of the window is in the centre.

II.  Compiling and Installing alloywm
-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+

2.  Configuring

Run the configure script.  It will create the Makefiles and some other shell
scripts.

Now would be the perfect time to pore over the Makefile, and change what
you need.

You may also want to change some of the defaults
for alloywm.  Just check out src/alloywm.h, so you can change the compiled-in
defaults.  Check section 2.3 of this document for details on what there is
to change.

3.  Compiling

Once you have everything ready to compile, just do these commands, in
order:

	make			(To compile everything)
	make install		(To install alloywm properly)
	make clean		(Remove the compiled binaries)

NOTE: If you wish to compile the [optional] goodies, you will need Gtk in 
order to compile the goodies, the root menu and window listing programs.

Now, everything's set.  Read on, and enjoy alloywm!

III.  Using alloywm
-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+

1.  Mouse/Window functions

When you first run the window manager, and you see a window, you will find
that there is a titlebar aligned to the left, and two small boxes on the
right, on the titlebar.  All of these are fundamental to the operation of
alloywm.  Most of the window functions are based upon mouse clicks, and they
are as they follow:

****************************************************************
*Mousebutton	Rootwindow	Titlebar	Mnmz.	Close  *
*-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=*
*Left		Program 1	Raise/Move	Rollup	Kill   *
*Middle		Windowlist	Lower		*	Hide   *
*Right		Program 2	Move		Move	Resize *
****************************************************************

Program 1 and Program 2 specify a program to be executed on a left or
right button on the root window, respectively.  To specify the programs,
you can edit aewm.h to specify a default program, or use the -new1 and
-new2 flags on the command line.

Since version 0.3.5, windows can now be rolled up.

2.  Command-line Options

	GNU-Style Flag		Description
	+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-
	-display		Use aewm on a display other than the
				DISPLAY variable
	-fn			Specify a font to be used on the titlebar
	-bw			Specify a border width, in pixels
	-new1			Specify a program to use on left-click on
				root window
	-new2			Specify a program to use on right-click on
				root window
	-fg			Specify the font colour of the titlebar
	-bg			Specify the background colour of the
				titlebar
	-bc			Specify a colour for the border
	-bc2			Specify an inner border colour
	
3.  Configuration

Most of the configuration is achieved by editing the aewm.h C header file.
In order for you to get a better understanding of what each C definition
does, I have a little table of them for you (each are defaults after
compile time, most have command-line equivalents, above.)

	Definitions		Description
	+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-
	DEF_FONT		Define a titlebar font to use at compile
				time.  Default value is lucidasans-10.
	DEF_FG			Define the font colour on the titlebar.
				Default is #000000.
	DEF_BG			Define the background colour on the
				titlebar.  Default is #b0b0b0.
	DEF_BC			Define the colour of the border drawn
				around the widgets.
	DEF_BC2			Define the inner border colour, default is
				#ffffff.			
	DEF_NEW1		Define the program to be run on left click
				on root window.  Default is gtk-panel.
	DEF_NEW2		Define the program to be run on right
				click on root window.  Default is
				gtk-switch.
	DEF_BW			Define the width of the border drawn
				around the widgets.
	DEF_OPAQUE		Contents of windows are drawn when window is
				moved.  Default is 1.
	DEF_RESIZEBAR		Draw a NeXT-style resize bar on the bottom.
				Default is 1.
	SPACE			Space (in pixels) around the titlebar
				text, also defines a size value of the
				titlebar.  Default is 3.
	MINSIZE			Define the minimal size of titlebars.
				Default is 15.
	CLICKFOCUS		Focus is given to window when titlebar is
				clicked.  Default is 1.
	MOUSEFOCUS		Focus is given to window when mouse enters
				the window.  Default is 0.
	DEBUG			Enable console debugging.  Default is 0.

4.  Miscellaneous

If you would like to create a distribution-specific package (so far, Slackware,
Debian, and mu2Linux), just run buildpkg, with --prefix=<some-dir> in order
to build the package.  Use --mu2linux, --debian, or --slackware to generate
either of those packages.

I've kept the original goodies (as in, the directory) intact, because they
are somewhat outside of the scope of what I'm developing.  Instructions in
installing these are in section 3.3, "Compiling".

If you wish to have a root window (for use with gtk-panel and xaw-panel),
you will have to make a ~/.paletterc file, in this format:

	LABEL=COMMAND (i.e. Netscape Navigator=netscape)

5.  Keyboard Control
Thanks to Ciaran Anscomb for evilwm, implementing keyboard control has never
been easier.  Well, here's the breakdown.

Ctrl+Alt+Return
	Spawn xterm (definable in src/alloywm.h under DEF_TERM)
Alt+Leftmouse, Ctrl+Alt+[HJKL]
	Move a window, along with giving it input focus
Alt+Middlemouse
	Resize window
Alt+Rightmouse, Ctrl+Alt+Keypad-Insert
	Lower window
Ctrl+Alt+[YUBN]
	Move a window to the corner of the screen
Alt+Tab
	Cycle through windows by order of realisation
Ctrl+Alt+Esc
	Kill a raised client

IV.  Foreclosure
-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+-=+

1.  Bugs

No real majour bugs, other than the fact that I still can't get the focusing
just right.  Also, when you minimise/maximise, or draw something over a
titlebar of an aterm window, the titlebar goes "transparent".  I'll fix that
soon enough.

2.  Changelog

The Changelog is no longer maintained inside of the README file.  If you would
like to see it, simply crack open Changelog.

3.  To Do

Creating an alloywm-exclusive root menu is imperative.  The Gtk+ program is
too slow.  But...Though, I will probably end up using Gtk+ for the new
toolbar anyways.

Highlighted and not-so-highlighted windows will soon come into play, as well.

4.  About the Author

I'm only 14 years old, at the time of writing (July 3, 2000).  I have been
using UNIX operating systems since January 14, 2000 (ask me not how I
remember the exact date).  I've been a rather good webmaster ever since I
stopped using AOL, and just as good as a programmer ever since I got a PC.
My original box was a Macintosh Performa 631CD, 8MB of RAM, 68040 Motorola
processor, 2x CD-ROM drive, 500MB SCSI hard drive.

The programming languages I know are as followed:
C, Object C, C++ (some), Java, JavaScript, HTML (not programming, but
markup, bah), Bourne-again shell, some c shell (never really got to know
it well), rudimentary Perl, good Tcl/Tk, x86 assembler, Sinclair Z80/GameBoy
Z80assembler, OPL (organiser programming language, used in Psion portables),
Pascal, Object Pascal/Delphi, AppleScript, PostScript, BASIC, rudimentary
Python, and *SOME* (I reapeat) *SOME* Visual Basic (refrained from it to
succumb to the superiority of Delphi when I used Windoze).

Questions?  Comments?  Flames?  Snapshots of your beautified alloywm
desktop?  Send 'em over to kensuke@phreaker.net.  Or, check out either
of my web sites, http://www.phatboydesigns.net/, or
http://epyon.homeip.net/ (my latest masterpiece).

5.  Mindless Legal Garbage

Copyright 2002 (c), Kensuke Otake

THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS", WITHOUT ANY EXPRESS
OR IMPLIED WARRANTIES OF ANY KIND. IN NO EVENT SHALL THE AUTHOR BE
HELD LIABLE FOR ANY DAMAGES CONNECTED WITH THE USE OF THIS PROGRAM.

This program is free software. You are granted permission, free of
charge, to copy this program, modify it, and distribute/publish/sell
copies of it, but this license may not be modified or removed from the
copyright notice. You may also use parts of this program's code in
your own software, if you agree to distribute it under this license.
