tv xmonad: queryPrefix -> (=??)
This commit is contained in:
parent
f9bc618fad
commit
662c2c6f90
@ -60,9 +60,8 @@ main = getArgs >>= \case
|
|||||||
args -> hPutStrLn stderr ("bad arguments: " <> show args) >> exitFailure
|
args -> hPutStrLn stderr ("bad arguments: " <> show args) >> exitFailure
|
||||||
|
|
||||||
|
|
||||||
queryPrefix :: Query String -> String -> Query Bool
|
(=??) :: Query a -> (a -> Bool) -> Query Bool
|
||||||
queryPrefix query prefix =
|
(=??) x p = fmap p x
|
||||||
fmap (Data.List.isPrefixOf prefix) query
|
|
||||||
|
|
||||||
|
|
||||||
mainNoArgs :: IO ()
|
mainNoArgs :: IO ()
|
||||||
@ -88,7 +87,7 @@ mainNoArgs = do
|
|||||||
, manageHook =
|
, manageHook =
|
||||||
composeAll
|
composeAll
|
||||||
[ appName =? "fzmenu-urxvt" --> doCenterFloat
|
[ appName =? "fzmenu-urxvt" --> doCenterFloat
|
||||||
, appName `queryPrefix` "pinentry" --> doCenterFloat
|
, appName =?? Data.List.isPrefixOf "pinentry" --> doCenterFloat
|
||||||
, title =? "Upload to Imgur" -->
|
, title =? "Upload to Imgur" -->
|
||||||
doRectFloat (W.RationalRect 0 0 (1 % 8) (1 % 8))
|
doRectFloat (W.RationalRect 0 0 (1 % 8) (1 % 8))
|
||||||
, placeHook (smart (1,0))
|
, placeHook (smart (1,0))
|
||||||
|
Loading…
Reference in New Issue
Block a user