aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrent Yorgey <byorgey@gmail.com>2007-11-24 03:22:49 +0100
committerBrent Yorgey <byorgey@gmail.com>2007-11-24 03:22:49 +0100
commit17f297a62ce0ce391fc7ca883bec4c4bb7a676de (patch)
tree74e5b3a75daefa83978c9d48aeea55efbb4cd5c3
parentfadaa2d612b69fb0ddd05bc1cc6d08e86d993b51 (diff)
downloadXMonadContrib-17f297a62ce0ce391fc7ca883bec4c4bb7a676de.tar.gz
XMonadContrib-17f297a62ce0ce391fc7ca883bec4c4bb7a676de.tar.xz
XMonadContrib-17f297a62ce0ce391fc7ca883bec4c4bb7a676de.zip
FocusNth: haddock updates
darcs-hash:20071124022249-bd4d7-9ba118dcfe257f1e2f5fc12d34fb068405a789ad.gz
-rw-r--r--XMonad/Actions/FocusNth.hs20
1 files changed, 11 insertions, 9 deletions
diff --git a/XMonad/Actions/FocusNth.hs b/XMonad/Actions/FocusNth.hs
index 42336ef..b82736d 100644
--- a/XMonad/Actions/FocusNth.hs
+++ b/XMonad/Actions/FocusNth.hs
@@ -8,7 +8,7 @@
-- Stability : unstable
-- Portability : unportable
--
--- Focus the nth window on the screen.
+-- Focus the nth window of the current workspace.
-----------------------------------------------------------------------------
module XMonad.Actions.FocusNth (
@@ -21,18 +21,20 @@ import XMonad.Operations
import XMonad
-- $usage
+-- Add the import to your @~\/.xmonad\/xmonad.hs@:
+--
-- > import XMonad.Actions.FocusNth
-
+--
+-- Then add appropriate keybindings, for example:
+--
-- > -- mod4-[1..9] @@ Switch to window N
--- > ++ [((mod4Mask, k), focusNth i)
+-- > ++ [((modMask x, k), focusNth i)
-- > | (i, k) <- zip [0 .. 8] [xK_1 ..]]
+--
+-- For detailed instructions on editing your key bindings, see
+-- "XMonad.Doc.Extending#Editing_key_bindings".
--- %import XMonad.Actions.FocusNth
--- %keybdindextra ++
--- %keybdindextra -- mod4-[1..9] @@ Switch to window N
--- %keybdindextra [((mod4Mask, k), focusNth i)
--- %keybdindextra | (i, k) <- zip [0 .. 8] [xK_1 ..]]
-
+-- | Give focus to the nth window of the current workspace.
focusNth :: Int -> X ()
focusNth = windows . modify' . focusNth'