Commit Graph

61 Commits

Author SHA1 Message Date
Don Stewart
c023e9a681 make 'tall' layout the default on startup. more useful for new users 2007-05-29 01:46:11 +00:00
Don Stewart
5818e5a7fc ensure !! won't go out of bounds in modifyGap 2007-05-28 07:06:09 +00:00
Don Stewart
94b64e7035 help man script 2007-05-28 03:38:46 +00:00
Spencer Janssen
257aa4776f Document mod-n 2007-05-28 03:35:36 +00:00
Don Stewart
c613073cb6 support per-screen gap settings. you can have different gaps on individual screens now 2007-05-28 03:15:01 +00:00
Don Stewart
1d2c5ca35a Use (Int,Int,Int,Int) for arbitrary gaps on any side of the screen 2007-05-28 02:51:35 +00:00
Don Stewart
bb4bd97c87 mod-b, toggle on or off the status bar gap 2007-05-27 12:59:28 +00:00
Don Stewart
a64c9f1856 Add new config value, defaultMenuGap, for specifying a gap for a status bar
By default, it is 0 (set in Config.hs), but set this to a pixel count to
get a permanent gap at the top of the screen. You can then at startup
launch dzen, and it will run in this gap, and not be obscured by other
windows.

Perfect for a persistant status bar.
2007-05-27 12:27:02 +00:00
Jason Creighton
8cfe050be7 Generate keybindings section in manpage from Config.hs 2007-05-27 06:29:14 +00:00
Don Stewart
60f4f4e5e4 HEADS UP: change key binding for swapLeft/Right and IncMaster
The use of arrow keys for swapLeft/Right clash with firefox's back
button. Use the more intuitive mod-shift-jk for this. (It's a movement
operation, after all).

This clashes with IncMaster, so we use mod+comma and mod+period for
these (i.e. the keys mod < and mod > , to move windows to and from the
master area).

While we're here, replace the use of the terms 'left' and 'right' for
navigation, in comments and identifiers, with 'up' and 'down' instead.
Hence mod-j == focusDown. Far more intuitive for people (dons) who live
in fullscreen mode and have vim movement wired into their central
nervous system.

Principle of least VI surprise: movement down or up means using j and k.
2007-05-26 11:14:53 +00:00
Spencer Janssen
8d6b914409 Formatting only 2007-05-25 21:44:14 +00:00
Spencer Janssen
654e64b772 Use --resume by default 2007-05-23 19:14:18 +00:00
bobstopper
bcf305cd1e add swapLeft and swapRight 2007-05-22 05:00:08 +00:00
Spencer Janssen
a9d7b7ef49 Experimental support for a beefier restart. 2007-05-21 19:46:53 +00:00
Spencer Janssen
3c2ad2509e Put restart in the X monad 2007-05-21 19:07:49 +00:00
Spencer Janssen
1c4b0a51d8 Fix mod-j/k bindings 2007-05-21 03:02:53 +00:00
Don Stewart
77e46027ed HEADS UP: Rewrite StackSet as a Zipper
In order to give a better account of how focus and master interact, and
how each operation affects focus, we reimplement the StackSet type as a
two level nested 'Zipper'. To quote Oleg:

    A Zipper is essentially an `updateable' and yet pure functional
    cursor into a data structure. Zipper is also a delimited
    continuation reified as a data structure.

That is, we use the Zipper as a cursor which encodes the window which is
in focus. Thus our data structure tracks focus correctly by
construction! We then get simple, obvious semantics for e.g. insert, in
terms of how it affects focus/master. Our transient-messes-with-focus
bug evaporates. 'swap' becomes trivial.

By moving focus directly into the stackset, we can toss some QC
properties about focus handling: it is simply impossible now for focus
to go wrong. As a benefit, we get a dozen new QC properties for free,
governing how master and focus operate.

The encoding of focus in the data type also simplifies the focus
handling in Operations: several operations affecting focus are now
simply wrappers over StackSet.

For the full story, please read the StackSet module, and the QC
properties.

Finally, we save ~40 lines with the simplified logic in Operations.hs

For more info, see the blog post on the implementation,

    http://cgi.cse.unsw.edu.au/~dons/blog/2007/05/17#xmonad_part1b_zipper
2007-05-20 07:00:53 +00:00
Jason Creighton
4206c4bae9 variable number of windows in master area 2007-05-16 03:14:37 +00:00
Don Stewart
0928bb484a Constrain layout messages to be members of a Message class
Using Typeables as the only constraint on layout messages is a bit
scary, as a user can send arbitrary values to layoutMsg, whether they
make sense or not: there's basically no type feedback on the values you
supply to layoutMsg.

Folloing Simon Marlow's dynamically extensible exceptions paper, we use
an existential type, and a Message type class, to constrain valid
arguments to layoutMsg to be valid members of Message.

That is, a user writes some data type for messages their layout
algorithm accepts:

  data MyLayoutEvent = Zoom
                     | Explode
                     | Flaming3DGlassEffect
                     deriving (Typeable)

and they then add this to the set of valid message types:

  instance Message MyLayoutEvent

Done. We also reimplement the dynamic type check while we're here, to
just directly use 'cast', rather than expose a raw fromDynamic/toDyn.

With this, I'm much happier about out dynamically extensible layout
event subsystem.
2007-05-04 08:16:49 +00:00
Spencer Janssen
9d3d2f8503 More Config.hs bugs 2007-05-03 23:46:07 +00:00
Spencer Janssen
204c90b072 Revert accidental change to Config.hs 2007-05-03 23:31:48 +00:00
David Roundy
ea1134db26 add support for extensible layouts. 2007-05-03 14:47:50 +00:00
Don Stewart
08ce2a5efa elaborate documentation in Config.hs 2007-05-03 07:48:43 +00:00
Spencer Janssen
3416eceb5d Add 'mod-n': refreshes current layout 2007-05-03 00:22:52 +00:00
Spencer Janssen
3586379ecc Make border width configurable 2007-04-30 16:35:15 +00:00
Spencer Janssen
08e514b28f Add Config.hs-boot, remove defaultLayoutDesc from XConf 2007-04-30 16:26:47 +00:00
Jason Creighton
bdbca84bcd configurable border colors
This also fixes a bug where xmonad was assuming a 24-bit display, and just
using, eg, 0xff0000 as an index into a colormap without querying the X server
to determine the proper pixel value for "red".
2007-04-30 04:38:59 +00:00
Spencer Janssen
0dd75f9d68 Further refactoring 2007-04-26 21:22:57 +00:00
Spencer Janssen
bd41b81c16 Refactor in Config.hs (no real changes) 2007-04-26 21:14:07 +00:00
Jason Creighton
767bc68acf Ignore numlock and capslock in keybindings 2007-04-24 01:33:57 +00:00
Jason Creighton
62acb87662 added comment about windows key (mod4Mask) 2007-04-15 23:36:35 +00:00
Jason Creighton
4b291d7e8a remove unused sizeDelta setting 2007-04-15 23:32:44 +00:00
Jason Creighton
899d470c4d added warning re: xmonad in path to mod-shift-q docs 2007-04-13 23:30:19 +00:00
Spencer Janssen
5fb81a781d Clear up documentation on mod-h/l 2007-04-13 23:07:06 +00:00
Alec Berryman
39cf207766 mod-wer for Xinerama was inadvertently changed 2007-04-12 13:20:33 +00:00
Don Stewart
a37193f2a6 add license headers to two missing files 2007-04-11 08:10:42 +00:00
Don Stewart
56c4a62468 explain what mod-return now does. it cycles 2007-04-11 07:36:36 +00:00
Don Stewart
e9597b4899 Change semantics of 'promote'.
Previously 'promote' would move the currently focused window into the
master position in tiled mode. This was *almost* a cycle of the windows,
but not quite (depending on where the focus was, it was in fact a
cycle).

Now we do the obvious generalisation, and just cycle the current window
stack. Simpler to understand, simpler to reason about.
2007-04-11 07:34:56 +00:00
Don Stewart
c490333d12 Statically distinguish Workspace and Screen indices 2007-04-11 06:04:56 +00:00
Spencer Janssen
be223c35f4 Move workspace fetching logic from Config.hs to Operations.hs 2007-04-10 06:47:14 +00:00
Jason Creighton
0c95f0c143 moved screen <-> workspace mapping from XMonad to StackSet 2007-04-10 06:27:31 +00:00
Don Stewart
89dbd331dc summarise key bindings in a table in Config.hs 2007-04-04 01:14:41 +00:00
Spencer Janssen
3a592d2df8 Use Tall and Wide for split screen layouts. This should be less confusing. 2007-04-03 05:06:10 +00:00
Alec Berryman
8c58c998db Comment typo: more -> move 2007-04-02 22:19:48 +00:00
Spencer Janssen
93be71bb88 Revert to the old layout code. 2007-04-02 04:51:14 +00:00
Alec Berryman
8d1deb69eb Type error: lockMask :: KeyMask, not KeySym
Error prevents compilation on 64-bit systems.
2007-04-01 14:34:16 +00:00
Alec Berryman
14282027e6 Suggest an alternative modMask for emacs users 2007-04-01 16:10:27 +00:00
Jason Creighton
b4076c2ac2 Config.hs comment formatting/typo 2007-04-01 05:57:11 +00:00
Don Stewart
bb1c1cf062 sanitize key bindings
Changes mean:

* gmrun is like the dmenu key, but with shift set. 
    -    , ((modMask .|. shiftMask, xK_F11   ), spawn "gmrun")
    +    , ((modMask .|. shiftMask, xK_p     ), spawn "gmrun")

 If no one actually uses both gmrun and dmenu, we should consider only
 using mod-p for this.

* restart is like quit, but with 'ctrl' set:
    +    , ((modMask .|. shiftMask, xK_q                     ), io $ exitWith ExitSuccess)
    +    , ((modMask .|. shiftMask .|. controlMask, xK_q     ), io restart)

* revert to 'wer' ordering for xinerama screens:
    -        | (key, sc) <- zip [xK_e, xK_r, xK_t] [1..]
    +        | (key, sc) <- zip [xK_w, xK_e, xK_r] [1..]

that's the only binding order that makes sense, since they're meant to
refer to screens 1 2 and 3, hence 'wer' (look at the keyboard to see why)
2007-04-01 03:35:22 +00:00
Don Stewart
cf91d8aa53 restore dwm-style keybindings. mod-shift-{j,k} resize in vert mode 2007-04-01 02:54:33 +00:00