Commit Graph

311 Commits

Author SHA1 Message Date
David Roundy
54ee507cca keep focus stack. 2007-05-10 13:16:37 +00:00
Jason Creighton
378aa87173 bump LOC limit to 550 2007-05-10 03:27:31 +00:00
Spencer Janssen
47ae5e4ea5 Remove broken prop_promoterotate, replace it with prop_promote_raise_id 2007-05-08 21:19:07 +00:00
Spencer Janssen
c4030d45e2 Disable shift_reversible until focus issues are decided. 2007-05-08 21:09:52 +00:00
Spencer Janssen
f5b0df6a73 Disable delete.push until focus issues are decided 2007-05-08 20:49:21 +00:00
Spencer Janssen
c5c958dc2c Remove unsafe fromJust 2007-05-08 16:38:22 +00:00
Neil Mitchell
626d25bb3a Add the initial Catch testing framework for StackSet 2007-05-08 15:46:21 +00:00
Neil Mitchell
97141b9a07 Work around the fact that Yhc gets defaulting a bit wrong 2007-05-08 12:49:49 +00:00
Spencer Janssen
4afb251f41 Make tests typecheck 2007-05-08 15:24:49 +00:00
Spencer Janssen
a846eb18ff Remove unsafe use of head 2007-05-08 15:21:16 +00:00
Spencer Janssen
f03ca10714 Make 'index' return Nothing, rather than error 2007-05-08 15:12:00 +00:00
Spencer Janssen
ba9e15e772 Use 'drop 1' rather than tail, skip equality check. 2007-05-08 15:09:43 +00:00
Spencer Janssen
70fe61971b Redundant parens 2007-05-08 15:04:12 +00:00
Spencer Janssen
1276edc861 StackSet.view: ignore invalid indices 2007-05-08 14:39:51 +00:00
Neil Mitchell
27f1f50071 Change the swap function so its Haskell 98, by using list-comps instead of pattern-guards. 2007-05-08 12:31:58 +00:00
Don Stewart
9f4fd822b6 Arbitrary instance for StackSet must set random focus on each workspace
When focus was separated from the stack order on each workspace, we
forgot to update the Arbitrary instance to set random focus. As spotted
by David R, this then invalidates 4 of our QC properties. In particular,
the property involving where focus goes after a random transient
(annoying behaviour) appeared to be correct, but wasn't, due to
inadequate coverage.

This patch sets focus to a random window on each workspace. As a result,
we now catch the focus/raise/delete issue people have been complaining
about.

Lesson: make sure your QuickCheck generators are doing what you think
they are.
2007-05-08 05:11:26 +00:00
David Roundy
ab27c7d48d make quickcheck tests friendlier to read. 2007-05-05 17:54:15 +00:00
Jason Creighton
ab0f3be0af make Properties.hs exit with failure on test failure 2007-05-05 17:43:57 +00:00
Don Stewart
7a56422491 since we just ignore type errors, no need to derive Show 2007-05-04 09:41:43 +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
72e7bed426 Handle empty layout lists 2007-05-04 04:56:44 +00:00
Don Stewart
d0ef78e5c3 refactoring, style, comments on new layout code 2007-05-04 02:36:18 +00:00
Jason Creighton
b5ed587f2e use anyKey constant instead of magic number 2007-05-04 01:50:43 +00:00
Jason Creighton
7a89f431b1 added mirrorLayout to mirror arbitrary layouts 2007-05-04 01:46:53 +00:00
Spencer Janssen
a5e0e2458d Fix layout switching order 2007-05-03 23:56:32 +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
Spencer Janssen
bedc069143 Add -fglasgow-exts for pattern guards. Properties.hs doesn't complain anymore 2007-05-03 21:42:21 +00:00
Spencer Janssen
5b7c6c8631 Avoid the unsafe pattern match, in case Config.hs has no layouts 2007-05-03 21:40:07 +00:00
David Roundy
ea1134db26 add support for extensible layouts. 2007-05-03 14:47:50 +00:00
Don Stewart
f0df95da72 comments. and stop tracing events to stderr 2007-05-03 07:58:21 +00:00
Don Stewart
f5e8b2b6a8 -Wall police 2007-05-03 07:49:37 +00:00
Don Stewart
08ce2a5efa elaborate documentation in Config.hs 2007-05-03 07:48:43 +00:00
Spencer Janssen
b63e8c029e Use updated refreshKeyboardMapping. Requires latest X11-extras 2007-05-03 03:20:40 +00:00
Jason Creighton
fa271e00ce run QC tests in addition to LOC test 2007-05-03 00:32:02 +00:00
Spencer Janssen
3416eceb5d Add 'mod-n': refreshes current layout 2007-05-03 00:22:52 +00:00
Spencer Janssen
833d5ae357 Fix tests after StackSet changes 2007-05-02 20:16:22 +00:00
Spencer Janssen
1dff21001c First steps to adding floating layer 2007-05-02 19:59:17 +00:00
Don Stewart
0c569a64e1 update motivational text using xmonad.org 2007-05-02 06:18:59 +00:00
Spencer Janssen
c0266c0cb8 Sort dependencies in installation order 2007-05-01 20:42:49 +00:00
Spencer Janssen
56a4164a90 Recommend X11-extras 0.1 2007-05-01 20:41:21 +00:00
Don Stewart
fdc73b4cb1 elaborate description in .cabal 2007-05-01 03:54:14 +00:00
Don Stewart
121e20d342 use -fasm by default. Much faster 2007-05-01 03:12:20 +00:00
Don Stewart
af7c76d3fe check we never generate invalid stack sets 2007-04-30 06:59:46 +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
Spencer Janssen
ecbff364c9 Comment only 2007-04-30 16:16:35 +00:00
Spencer Janssen
1e83de8cde Comment only 2007-04-30 16:15:11 +00:00
Don Stewart
4d9fa8bc98 view n . shift n . view i . shift i) x == x --> shift + view is invertible 2007-04-30 06:29:01 +00:00
Don Stewart
17f70344ec add rotate all and view idempotency tests 2007-04-30 05:57:51 +00:00