mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-05-19 11:30:22 -07:00
Merge pull request #349 from sergeykish/master
Use XFT fonts if available
This commit is contained in:
commit
1726bdb67b
10
CHANGES.md
10
CHANGES.md
@ -4,6 +4,16 @@
|
|||||||
|
|
||||||
### Breaking Changes
|
### Breaking Changes
|
||||||
|
|
||||||
|
* All modules that export bitmap fonts as their default
|
||||||
|
|
||||||
|
- If xmonad is compiled with XFT support (the default), use an XFT
|
||||||
|
font instead. The previous default expected an X11 misc font
|
||||||
|
(PCF), which is not supported in pango 1.44 anymore and thus some
|
||||||
|
distributions have stopped shipping these.
|
||||||
|
|
||||||
|
This fixes the silent `user error (createFontSet)`; this would
|
||||||
|
break the respective modules.
|
||||||
|
|
||||||
* `XMonad.Prompt`
|
* `XMonad.Prompt`
|
||||||
|
|
||||||
- Now `mkComplFunFromList` and `mkComplFunFromList'` take an
|
- Now `mkComplFunFromList` and `mkComplFunFromList'` take an
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
{-# LANGUAGE DeriveDataTypeable #-}
|
{-# LANGUAGE DeriveDataTypeable #-}
|
||||||
|
{-# LANGUAGE CPP #-}
|
||||||
-----------------------------------------------------------------------------
|
-----------------------------------------------------------------------------
|
||||||
-- |
|
-- |
|
||||||
-- Module : XMonad.Actions.ShowText
|
-- Module : XMonad.Actions.ShowText
|
||||||
@ -74,7 +75,11 @@ data ShowTextConfig =
|
|||||||
|
|
||||||
instance Default ShowTextConfig where
|
instance Default ShowTextConfig where
|
||||||
def =
|
def =
|
||||||
|
#ifdef XFT
|
||||||
|
STC { st_font = "xft:monospace-20"
|
||||||
|
#else
|
||||||
STC { st_font = "-misc-fixed-*-*-*-*-20-*-*-*-*-*-*-*"
|
STC { st_font = "-misc-fixed-*-*-*-*-20-*-*-*-*-*-*-*"
|
||||||
|
#endif
|
||||||
, st_bg = "black"
|
, st_bg = "black"
|
||||||
, st_fg = "white"
|
, st_fg = "white"
|
||||||
}
|
}
|
||||||
|
@ -1,4 +1,10 @@
|
|||||||
{-# LANGUAGE DeriveDataTypeable, FlexibleContexts, FlexibleInstances, MultiParamTypeClasses, PatternGuards, TypeSynonymInstances #-}
|
{-# LANGUAGE DeriveDataTypeable #-}
|
||||||
|
{-# LANGUAGE FlexibleContexts #-}
|
||||||
|
{-# LANGUAGE FlexibleInstances #-}
|
||||||
|
{-# LANGUAGE MultiParamTypeClasses #-}
|
||||||
|
{-# LANGUAGE PatternGuards #-}
|
||||||
|
{-# LANGUAGE TypeSynonymInstances #-}
|
||||||
|
{-# LANGUAGE CPP #-}
|
||||||
-----------------------------------------------------------------------------
|
-----------------------------------------------------------------------------
|
||||||
-- |
|
-- |
|
||||||
-- Module : XMonad.Layout.Decoration
|
-- Module : XMonad.Layout.Decoration
|
||||||
@ -104,7 +110,11 @@ instance Default Theme where
|
|||||||
, activeTextColor = "#FFFFFF"
|
, activeTextColor = "#FFFFFF"
|
||||||
, inactiveTextColor = "#BFBFBF"
|
, inactiveTextColor = "#BFBFBF"
|
||||||
, urgentTextColor = "#FF0000"
|
, urgentTextColor = "#FF0000"
|
||||||
|
#ifdef XFT
|
||||||
|
, fontName = "xft:monospace"
|
||||||
|
#else
|
||||||
, fontName = "-misc-fixed-*-*-*-*-10-*-*-*-*-*-*-*"
|
, fontName = "-misc-fixed-*-*-*-*-10-*-*-*-*-*-*-*"
|
||||||
|
#endif
|
||||||
, decoWidth = 200
|
, decoWidth = 200
|
||||||
, decoHeight = 20
|
, decoHeight = 20
|
||||||
, windowTitleAddons = []
|
, windowTitleAddons = []
|
||||||
|
@ -1,4 +1,7 @@
|
|||||||
{-# LANGUAGE PatternGuards, FlexibleInstances, MultiParamTypeClasses #-}
|
{-# LANGUAGE FlexibleInstances #-}
|
||||||
|
{-# LANGUAGE MultiParamTypeClasses #-}
|
||||||
|
{-# LANGUAGE PatternGuards #-}
|
||||||
|
{-# LANGUAGE CPP #-}
|
||||||
-----------------------------------------------------------------------------
|
-----------------------------------------------------------------------------
|
||||||
-- |
|
-- |
|
||||||
-- Module : XMonad.Layout.ShowWName
|
-- Module : XMonad.Layout.ShowWName
|
||||||
@ -62,7 +65,11 @@ data SWNConfig =
|
|||||||
|
|
||||||
instance Default SWNConfig where
|
instance Default SWNConfig where
|
||||||
def =
|
def =
|
||||||
|
#ifdef XFT
|
||||||
|
SWNC { swn_font = "xft:monospace-20"
|
||||||
|
#else
|
||||||
SWNC { swn_font = "-misc-fixed-*-*-*-*-20-*-*-*-*-*-*-*"
|
SWNC { swn_font = "-misc-fixed-*-*-*-*-20-*-*-*-*-*-*-*"
|
||||||
|
#endif
|
||||||
, swn_bgcolor = "black"
|
, swn_bgcolor = "black"
|
||||||
, swn_color = "white"
|
, swn_color = "white"
|
||||||
, swn_fade = 1
|
, swn_fade = 1
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
{-# LANGUAGE MultiWayIf #-}
|
{-# LANGUAGE MultiWayIf #-}
|
||||||
{-# LANGUAGE FlexibleContexts #-}
|
{-# LANGUAGE FlexibleContexts #-}
|
||||||
{-# LANGUAGE ExistentialQuantification #-}
|
{-# LANGUAGE ExistentialQuantification #-}
|
||||||
|
{-# LANGUAGE CPP #-}
|
||||||
-----------------------------------------------------------------------------
|
-----------------------------------------------------------------------------
|
||||||
-- |
|
-- |
|
||||||
-- Module : XMonad.Prompt
|
-- Module : XMonad.Prompt
|
||||||
@ -312,7 +313,11 @@ instance Default XPColor where
|
|||||||
|
|
||||||
instance Default XPConfig where
|
instance Default XPConfig where
|
||||||
def =
|
def =
|
||||||
|
#ifdef XFT
|
||||||
|
XPC { font = "xft:monospace-12"
|
||||||
|
#else
|
||||||
XPC { font = "-misc-fixed-*-*-*-*-12-*-*-*-*-*-*-*"
|
XPC { font = "-misc-fixed-*-*-*-*-12-*-*-*-*-*-*-*"
|
||||||
|
#endif
|
||||||
, bgColor = bgNormal def
|
, bgColor = bgNormal def
|
||||||
, fgColor = fgNormal def
|
, fgColor = fgNormal def
|
||||||
, bgHLight = bgHighlight def
|
, bgHLight = bgHighlight def
|
||||||
|
Loading…
x
Reference in New Issue
Block a user