mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-09-01 03:43:47 -07:00
No more tabs
This commit is contained in:
@@ -16,9 +16,9 @@
|
|||||||
-----------------------------------------------------------------------------
|
-----------------------------------------------------------------------------
|
||||||
|
|
||||||
module XMonad.Actions.ConstrainedResize (
|
module XMonad.Actions.ConstrainedResize (
|
||||||
-- * Usage
|
-- * Usage
|
||||||
-- $usage
|
-- $usage
|
||||||
XMonad.Actions.ConstrainedResize.mouseResizeWindow
|
XMonad.Actions.ConstrainedResize.mouseResizeWindow
|
||||||
) where
|
) where
|
||||||
|
|
||||||
import XMonad
|
import XMonad
|
||||||
|
@@ -17,9 +17,9 @@
|
|||||||
-- Based on the FlexibleResize code by Lukas Mai (mauke).
|
-- Based on the FlexibleResize code by Lukas Mai (mauke).
|
||||||
|
|
||||||
module XMonad.Actions.FlexibleManipulate (
|
module XMonad.Actions.FlexibleManipulate (
|
||||||
-- * Usage
|
-- * Usage
|
||||||
-- $usage
|
-- $usage
|
||||||
mouseWindow, discrete, linear, resize, position
|
mouseWindow, discrete, linear, resize, position
|
||||||
) where
|
) where
|
||||||
|
|
||||||
import XMonad
|
import XMonad
|
||||||
|
@@ -13,9 +13,9 @@
|
|||||||
-----------------------------------------------------------------------------
|
-----------------------------------------------------------------------------
|
||||||
|
|
||||||
module XMonad.Actions.FlexibleResize (
|
module XMonad.Actions.FlexibleResize (
|
||||||
-- * Usage
|
-- * Usage
|
||||||
-- $usage
|
-- $usage
|
||||||
XMonad.Actions.FlexibleResize.mouseResizeWindow
|
XMonad.Actions.FlexibleResize.mouseResizeWindow
|
||||||
) where
|
) where
|
||||||
|
|
||||||
import XMonad
|
import XMonad
|
||||||
|
@@ -38,12 +38,13 @@ focusNth :: Int -> X ()
|
|||||||
focusNth = windows . modify' . focusNth'
|
focusNth = windows . modify' . focusNth'
|
||||||
|
|
||||||
focusNth' :: Int -> Stack a -> Stack a
|
focusNth' :: Int -> Stack a -> Stack a
|
||||||
focusNth' n s@(Stack _ ls rs) | (n < 0) || (n > length(ls) + length(rs)) = s
|
focusNth' n s@(Stack _ ls rs) | (n < 0) || (n > length(ls) + length(rs)) = s
|
||||||
| otherwise = listToStack n (integrate s)
|
| otherwise = listToStack n (integrate s)
|
||||||
|
|
||||||
listToStack :: Int -> [a] -> Stack a
|
listToStack :: Int -> [a] -> Stack a
|
||||||
listToStack n l = Stack t ls rs
|
listToStack n l = Stack t ls rs
|
||||||
where (t:rs) = drop n l
|
where
|
||||||
ls = reverse (take n l)
|
(t:rs) = drop n l
|
||||||
|
ls = reverse (take n l)
|
||||||
|
|
||||||
|
|
||||||
|
@@ -15,7 +15,7 @@
|
|||||||
module XMonad.Actions.MouseGestures (
|
module XMonad.Actions.MouseGestures (
|
||||||
-- * Usage
|
-- * Usage
|
||||||
-- $usage
|
-- $usage
|
||||||
Direction(..),
|
Direction(..),
|
||||||
mouseGesture
|
mouseGesture
|
||||||
) where
|
) where
|
||||||
|
|
||||||
|
@@ -12,10 +12,10 @@
|
|||||||
-- place.
|
-- place.
|
||||||
-----------------------------------------------------------------------------
|
-----------------------------------------------------------------------------
|
||||||
module XMonad.Actions.RotSlaves (
|
module XMonad.Actions.RotSlaves (
|
||||||
-- $usage
|
-- $usage
|
||||||
rotSlaves', rotSlavesUp, rotSlavesDown,
|
rotSlaves', rotSlavesUp, rotSlavesDown,
|
||||||
rotAll', rotAllUp, rotAllDown
|
rotAll', rotAllUp, rotAllDown
|
||||||
) where
|
) where
|
||||||
|
|
||||||
import XMonad.StackSet
|
import XMonad.StackSet
|
||||||
import XMonad
|
import XMonad
|
||||||
|
@@ -107,7 +107,7 @@ doLay mirror (DragPane mw ty delta split) r s = do
|
|||||||
mirror $ Rectangle x y (w-halfHandleWidth) h
|
mirror $ Rectangle x y (w-halfHandleWidth) h
|
||||||
right = case right' of
|
right = case right' of
|
||||||
Rectangle x y w h ->
|
Rectangle x y w h ->
|
||||||
mirror $ Rectangle (x+halfHandleWidth) y (w-halfHandleWidth) h
|
mirror $ Rectangle (x+halfHandleWidth) y (w-halfHandleWidth) h
|
||||||
handr = case left' of
|
handr = case left' of
|
||||||
Rectangle x y w h ->
|
Rectangle x y w h ->
|
||||||
mirror $ Rectangle (x + fromIntegral w - halfHandleWidth) y (2*halfHandleWidth) h
|
mirror $ Rectangle (x + fromIntegral w - halfHandleWidth) y (2*halfHandleWidth) h
|
||||||
|
@@ -17,7 +17,7 @@
|
|||||||
module XMonad.Layout.Grid (
|
module XMonad.Layout.Grid (
|
||||||
-- * Usage
|
-- * Usage
|
||||||
-- $usage
|
-- $usage
|
||||||
Grid(..)
|
Grid(..)
|
||||||
) where
|
) where
|
||||||
|
|
||||||
import XMonad
|
import XMonad
|
||||||
|
@@ -204,8 +204,8 @@ updateTab ishr c fs wh (tabw,ow) = do
|
|||||||
dpy <- asks display
|
dpy <- asks display
|
||||||
let s = shrinkIt ishr
|
let s = shrinkIt ishr
|
||||||
name <- shrinkWhile s (\n -> do
|
name <- shrinkWhile s (\n -> do
|
||||||
size <- io $ textWidthXMF dpy fs n
|
size <- io $ textWidthXMF dpy fs n
|
||||||
return $ size > fromIntegral wh - fromIntegral (ht `div` 2)) (show nw)
|
return $ size > fromIntegral wh - fromIntegral (ht `div` 2)) (show nw)
|
||||||
paintAndWrite tabw fs wh ht 1 bc' borderc' tc' bc' AlignCenter name
|
paintAndWrite tabw fs wh ht 1 bc' borderc' tc' bc' AlignCenter name
|
||||||
|
|
||||||
shrink :: TConf -> Rectangle -> Rectangle
|
shrink :: TConf -> Rectangle -> Rectangle
|
||||||
@@ -217,10 +217,10 @@ shrinkWhile sh p x = sw $ sh x
|
|||||||
where sw [n] = return n
|
where sw [n] = return n
|
||||||
sw [] = return ""
|
sw [] = return ""
|
||||||
sw (n:ns) = do
|
sw (n:ns) = do
|
||||||
cond <- p n
|
cond <- p n
|
||||||
if cond
|
if cond
|
||||||
then sw ns
|
then sw ns
|
||||||
else return n
|
else return n
|
||||||
|
|
||||||
data CustomShrink = CustomShrink
|
data CustomShrink = CustomShrink
|
||||||
instance Show CustomShrink where show _ = ""
|
instance Show CustomShrink where show _ = ""
|
||||||
|
@@ -22,7 +22,7 @@ module XMonad.Util.XUtils (
|
|||||||
, deleteWindow
|
, deleteWindow
|
||||||
, paintWindow
|
, paintWindow
|
||||||
, paintAndWrite
|
, paintAndWrite
|
||||||
, stringToPixel
|
, stringToPixel
|
||||||
) where
|
) where
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user