aboutsummaryrefslogtreecommitdiffstats
path: root/XMonad
diff options
context:
space:
mode:
authorAndrea Rossato <andrea.rossato@unibz.it>2008-02-08 00:21:55 +0100
committerAndrea Rossato <andrea.rossato@unibz.it>2008-02-08 00:21:55 +0100
commita2c68eb4d0616e856ecc3fb775ff5d6517becbda (patch)
tree2582ddf42d27a17140ca5dd423b8d7b0d19a7368 /XMonad
parentc740a14690d225e7686e10201cef9b821f722298 (diff)
downloadXMonadContrib-a2c68eb4d0616e856ecc3fb775ff5d6517becbda.tar.gz
XMonadContrib-a2c68eb4d0616e856ecc3fb775ff5d6517becbda.tar.xz
XMonadContrib-a2c68eb4d0616e856ecc3fb775ff5d6517becbda.zip
Prompt.Theme: comments and some point-free
darcs-hash:20080207232155-32816-b33ac4902f1f2c2cfef11570edea06fab9ad5cf4.gz
Diffstat (limited to 'XMonad')
-rw-r--r--XMonad/Prompt/Theme.hs12
1 files changed, 6 insertions, 6 deletions
diff --git a/XMonad/Prompt/Theme.hs b/XMonad/Prompt/Theme.hs
index 6392f41..a1f25be 100644
--- a/XMonad/Prompt/Theme.hs
+++ b/XMonad/Prompt/Theme.hs
@@ -8,8 +8,7 @@
-- Stability : unstable
-- Portability : unportable
--
--- A prompt for chnaging the theme of the current workspace
---
+-- A prompt for changing the theme of the current workspace
-----------------------------------------------------------------------------
module XMonad.Prompt.Theme
@@ -27,7 +26,8 @@ import XMonad.Layout.Decoration
import XMonad.Util.Themes
-- $usage
--- You can use this module with the following in your @~\/.xmonad\/xmonad.hs@:
+-- You can use this module with the following in your
+-- @~\/.xmonad\/xmonad.hs@:
--
-- > import XMonad.Prompt
-- > import XMonad.Prompt.Theme
@@ -45,8 +45,8 @@ instance XPrompt ThemePrompt where
showXPrompt ThemePrompt = "Select a theme: "
themePrompt :: XPConfig -> X ()
-themePrompt c = mkXPrompt ThemePrompt c (const $ return (map fst $ M.toList mapOfThemes)) changeTheme
- where changeTheme t = sendMessage . SetTheme $ fromMaybe defaultTheme (M.lookup t mapOfThemes)
+themePrompt c = mkXPrompt ThemePrompt c (const . return . map themeName $ listOfThemes) changeTheme
+ where changeTheme t = sendMessage . SetTheme . fromMaybe defaultTheme $ M.lookup t mapOfThemes
mapOfThemes :: M.Map String Theme
-mapOfThemes = M.fromList . uncurry zip . (map themeName &&& map theme) $ listOfThemes \ No newline at end of file
+mapOfThemes = M.fromList . uncurry zip . (map themeName &&& map theme) $ listOfThemes