From d5ef958f82520a392c77ace3df5ea398c133b81c Mon Sep 17 00:00:00 2001 From: Spencer Janssen Date: Wed, 20 Jun 2007 17:08:58 +0200 Subject: Update Layout documentation darcs-hash:20070620150858-a5988-761f067579d6df331fd868db2bc010590a0a7939 --- XMonad.hs | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'XMonad.hs') diff --git a/XMonad.hs b/XMonad.hs index b6e9f91..6242b40 100644 --- a/XMonad.hs +++ b/XMonad.hs @@ -116,8 +116,15 @@ atom_WM_STATE = getAtom "WM_STATE" -- | Layout handling -- The different layout modes --- 'doLayout', a pure function to layout a Window set 'modifyLayout', --- 'modifyLayout' can be considered a branch of an exception handler. +-- 'doLayout': given a Rectangle and a Stack, layout the stack elements +-- inside the given Rectangle. If an element is not given a Rectangle +-- by 'doLayout', then it is not shown on screen. Windows are restacked +-- according to the order they are returned by 'doLayout'. +-- +-- 'modifyLayout' performs message handling for that layout. If +-- 'modifyLayout' returns Nothing, then the layout did not respond to +-- that message and the screen is not refreshed. Otherwise, 'modifyLayout' +-- returns an updated 'Layout' and the screen is refreshed. -- data Layout a = Layout { doLayout :: Rectangle -> Stack a -> X [(a, Rectangle)] , modifyLayout :: SomeMessage -> X (Maybe (Layout a)) } -- cgit v1.2.3