diff options
author | Daniel Wagner <daniel@wagner-home.com> | 2013-05-28 03:39:09 +0200 |
---|---|---|
committer | Daniel Wagner <daniel@wagner-home.com> | 2013-05-28 03:39:09 +0200 |
commit | 6769de07f7e06ddf6eea728bd7072ebfe6eff017 (patch) | |
tree | f234bf0cac01538fbc1acab1a668ac61b9ab8074 /XMonad/Actions/ShowText.hs | |
parent | fe066e8e9ca5326dd146630a6d729fae51af12cf (diff) | |
download | XMonadContrib-6769de07f7e06ddf6eea728bd7072ebfe6eff017.tar.gz XMonadContrib-6769de07f7e06ddf6eea728bd7072ebfe6eff017.tar.xz XMonadContrib-6769de07f7e06ddf6eea728bd7072ebfe6eff017.zip |
use Data.Default wherever possible, and deprecate the things it replaces
Ignore-this: 898458b1d2868a70dfb09faf473dc7aa
darcs-hash:20130528013909-76d51-863278165b6f149c47b08b31b34e85ddcab19f1f.gz
Diffstat (limited to 'XMonad/Actions/ShowText.hs')
-rw-r--r-- | XMonad/Actions/ShowText.hs | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/XMonad/Actions/ShowText.hs b/XMonad/Actions/ShowText.hs index e0a64cb..77d7244 100644 --- a/XMonad/Actions/ShowText.hs +++ b/XMonad/Actions/ShowText.hs @@ -16,7 +16,8 @@ module XMonad.Actions.ShowText ( -- * Usage -- $usage - defaultSTConfig + def + , defaultSTConfig , handleTimerEvent , flashText , ShowTextConfig(..) @@ -52,7 +53,7 @@ import qualified XMonad.Util.ExtensibleState as ES -- -- You can then use flashText in your keybindings: -- --- > ((modMask, xK_Right), flashText defaultSTConfig 1 "->" >> nextWS) +-- > ((modMask, xK_Right), flashText def 1 "->" >> nextWS) -- -- | ShowText contains the map with timers as keys and created windows as values @@ -72,13 +73,17 @@ data ShowTextConfig = , st_fg :: String -- ^ Foreground color } -defaultSTConfig :: ShowTextConfig -defaultSTConfig = +instance Default ShowTextConfig where + def = STC { st_font = "-misc-fixed-*-*-*-*-20-*-*-*-*-*-*-*" , st_bg = "black" , st_fg = "white" } +{-# DEPRECATED defaultSTConfig "Use def (from Data.Default, and re-exported by XMonad.Actions.ShowText) instead." #-} +defaultSTConfig :: ShowTextConfig +defaultSTConfig = def + -- | Handles timer events that notify when a window should be removed handleTimerEvent :: Event -> X All handleTimerEvent (ClientMessageEvent _ _ _ dis _ mtyp d) = do |