Don't export TConf anymore and export DeConfig instead

WARNING: this patch may be breaking your configuration. While it is
still possible to use:

tabbed shrinkText defaultTConf

updating the fields of the defaultTConf record is not possible
anymore, since the type TConf is now hidden.

WARNING: "tabSize" has been substituted by "decoHeight"

You can change your configuration this way:
myTConf :: TConf
myTConf = defaultTConf
       { tabSize = 15
       , etc....

becomes:
myTConf :: DeConfig TabbedDecoration Window
myTConf = defaultTabbedConfig
       { decoHeight = 15
       , etc....

and
tabbed shrinkText myTConf

becomes:
tabDeco shrinkText myTConf
This commit is contained in:
Andrea Rossato 2008-01-26 09:21:41 +00:00
parent baca0e98d1
commit 041eb5dc18
3 changed files with 15 additions and 14 deletions

View File

@ -76,16 +76,16 @@ import XMonad.Prompt.XMonad
-- | My configuration for the Tabbed Layout. Basically this is the
-- Ion3 clean style.
arossatoTabbedConfig :: TConf
arossatoTabbedConfig =
defaultTConf { activeColor = "#8a999e"
, inactiveColor = "#545d75"
, activeBorderColor = "white"
, inactiveBorderColor = "grey"
, activeTextColor = "white"
, inactiveTextColor = "grey"
, tabSize = 15
}
arossatoTabbedConfig :: DeConfig TabbedDecoration Window
arossatoTabbedConfig = defaultTabbedConfig
{ activeColor = "#8a999e"
, inactiveColor = "#545d75"
, activeBorderColor = "white"
, inactiveBorderColor = "grey"
, activeTextColor = "white"
, inactiveTextColor = "grey"
, decoHeight = 15
}
arossatoConfig = defaultConfig
{ workspaces = ["home","var","dev","mail","web","doc"] ++
@ -106,7 +106,7 @@ arossatoConfig = defaultConfig
}
where
-- layouts
mytab = tabbed shrinkText arossatoTabbedConfig
mytab = tabDeco shrinkText arossatoTabbedConfig
tiled = Tall 1 (3/100) (1/2)
-- manageHook

View File

@ -29,7 +29,7 @@ sjanssenConfig = do
, ((modm, button2), (\w -> focus w >> windows W.swapMaster))
, ((modm.|. shiftMask, button1), (\w -> focus w >> mouseResizeWindow w)) ]
, keys = \c -> mykeys c `M.union` keys defaultConfig c
, layoutHook = avoidStruts $ smartBorders (tiled Tall ||| tiled Wide ||| Full ||| tabbed shrinkText myTConf)
, layoutHook = avoidStruts $ smartBorders (tiled Tall ||| tiled Wide ||| Full ||| tabDeco shrinkText myTConf)
, manageHook = manageHook defaultConfig <+> manageDocks
}
where
@ -44,7 +44,7 @@ sjanssenConfig = do
]
myFont = "xft:Bitstream Vera Sans Mono:pixelsize=10"
myTConf = defaultTConf { fontName = myFont }
myTConf = defaultTabbedConfig { fontName = myFont }
myPromptConfig = defaultXPConfig
{ position = Top
, font = myFont

View File

@ -25,7 +25,8 @@ module XMonad.Layout.Tabbed
-- $usage
tabbed
, tabDeco
, TConf (..), defaultTConf
, defaultTConf
, DeConfig (..)
, TabbedDecoration (..), defaultTabbedConfig
, shrinkText, CustomShrink(CustomShrink)
, Shrinker(..)