mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-08-06 06:51:55 -07:00
Structure L.MouseResizableTile documentation.
This commit is contained in:
@@ -20,13 +20,16 @@ module XMonad.Layout.MouseResizableTile (
|
|||||||
mouseResizableTile,
|
mouseResizableTile,
|
||||||
mouseResizableTileMirrored,
|
mouseResizableTileMirrored,
|
||||||
MRTMessage (ShrinkSlave, ExpandSlave),
|
MRTMessage (ShrinkSlave, ExpandSlave),
|
||||||
DraggerType (..),
|
|
||||||
|
-- * Parameters
|
||||||
|
-- $mrtParameters
|
||||||
nmaster,
|
nmaster,
|
||||||
masterFrac,
|
masterFrac,
|
||||||
slaveFrac,
|
slaveFrac,
|
||||||
fracIncrement,
|
fracIncrement,
|
||||||
|
isMirrored,
|
||||||
draggerType,
|
draggerType,
|
||||||
isMirrored
|
DraggerType (..),
|
||||||
) where
|
) where
|
||||||
|
|
||||||
import XMonad hiding (tile, splitVertically, splitHorizontallyBy)
|
import XMonad hiding (tile, splitVertically, splitHorizontallyBy)
|
||||||
@@ -46,15 +49,6 @@ import Control.Applicative((<$>))
|
|||||||
-- > myLayout = mouseResizableTile ||| etc..
|
-- > myLayout = mouseResizableTile ||| etc..
|
||||||
-- > main = xmonad defaultConfig { layoutHook = myLayout }
|
-- > main = xmonad defaultConfig { layoutHook = myLayout }
|
||||||
--
|
--
|
||||||
-- or
|
|
||||||
--
|
|
||||||
-- > myLayout = mouseResizableTileMirrored ||| etc..
|
|
||||||
-- > main = xmonad defaultConfig { layoutHook = myLayout }
|
|
||||||
--
|
|
||||||
-- Additionally, some parameters may be tweaked (see the rest of this document
|
|
||||||
-- for a list of them):
|
|
||||||
--
|
|
||||||
-- > myLayout = mouseResizableTile { draggerType = BordersDragger } ||| etc..
|
|
||||||
--
|
--
|
||||||
-- For more detailed instructions on editing the layoutHook see:
|
-- For more detailed instructions on editing the layoutHook see:
|
||||||
--
|
--
|
||||||
@@ -69,6 +63,17 @@ import Control.Applicative((<$>))
|
|||||||
--
|
--
|
||||||
-- "XMonad.Doc.Extending#Editing_key_bindings".
|
-- "XMonad.Doc.Extending#Editing_key_bindings".
|
||||||
|
|
||||||
|
-- $mrtParameters
|
||||||
|
-- The following functions are also labels for updating the @data@ (whose
|
||||||
|
-- representation is otherwise hidden) produced by 'mouseResizableTile'.
|
||||||
|
--
|
||||||
|
-- Usage:
|
||||||
|
--
|
||||||
|
-- > myLayout = mouseResizableTile{ masterFrac = 0.7,
|
||||||
|
-- > fracIncrement = 0.05,
|
||||||
|
-- > draggerType = BordersDragger }
|
||||||
|
-- > ||| etc..
|
||||||
|
|
||||||
data MRTMessage = SetMasterFraction Rational
|
data MRTMessage = SetMasterFraction Rational
|
||||||
| SetLeftSlaveFraction Int Rational
|
| SetLeftSlaveFraction Int Rational
|
||||||
| SetRightSlaveFraction Int Rational
|
| SetRightSlaveFraction Int Rational
|
||||||
@@ -96,43 +101,30 @@ type DraggerGeometry = (Position, Dimension, Position, Dimension)
|
|||||||
|
|
||||||
data MouseResizableTile a = MRT { nmaster :: Int,
|
data MouseResizableTile a = MRT { nmaster :: Int,
|
||||||
-- ^ Get/set the number of windows in
|
-- ^ Get/set the number of windows in
|
||||||
-- master pane (default: 1). Usage:
|
-- master pane (default: 1).
|
||||||
--
|
|
||||||
-- > mouseResizableTile { nmaster = ... }
|
|
||||||
masterFrac :: Rational,
|
masterFrac :: Rational,
|
||||||
-- ^ Get/set the proportion of screen
|
-- ^ Get/set the proportion of screen
|
||||||
-- occupied by master pane (default: 1/2).
|
-- occupied by master pane (default: 1/2).
|
||||||
-- Usage:
|
|
||||||
--
|
|
||||||
-- > mouseResizableTile { masterFrac = ... }
|
|
||||||
slaveFrac :: Rational,
|
slaveFrac :: Rational,
|
||||||
-- ^ Get/set the proportion of remaining
|
-- ^ Get/set the proportion of remaining
|
||||||
-- space in a column occupied by a slave
|
-- space in a column occupied by a slave
|
||||||
-- window (default: 1/2). Usage:
|
-- window (default: 1/2).
|
||||||
--
|
|
||||||
-- > mouseResizableTile { slaveFrac = ... }
|
|
||||||
fracIncrement :: Rational,
|
fracIncrement :: Rational,
|
||||||
-- ^ Get/set the increment used when
|
-- ^ Get/set the increment used when
|
||||||
-- modifying masterFrac/slaveFrac by the
|
-- modifying masterFrac/slaveFrac by the
|
||||||
-- Shrink, Expand, etc. messages (default:
|
-- Shrink, Expand, etc. messages (default:
|
||||||
-- 3/100). Usage:
|
-- 3/100).
|
||||||
--
|
|
||||||
-- > mouseResizableTile { fracIncrement = ... }
|
|
||||||
leftFracs :: [Rational],
|
leftFracs :: [Rational],
|
||||||
rightFracs :: [Rational],
|
rightFracs :: [Rational],
|
||||||
draggers :: [DraggerWithWin],
|
draggers :: [DraggerWithWin],
|
||||||
draggerType :: DraggerType,
|
draggerType :: DraggerType,
|
||||||
-- ^ Get/set dragger and gap dimensions
|
-- ^ Get/set dragger and gap dimensions
|
||||||
-- (default: FixedDragger 6 6). Usage:
|
-- (default: FixedDragger 6 6).
|
||||||
--
|
|
||||||
-- > mouseResizableTile { draggerType = ... }
|
|
||||||
focusPos :: Int,
|
focusPos :: Int,
|
||||||
numWindows :: Int,
|
numWindows :: Int,
|
||||||
isMirrored :: Bool
|
isMirrored :: Bool
|
||||||
-- ^ Get/set whether the layout is
|
-- ^ Get/set whether the layout is
|
||||||
-- mirrored (default: False). Usage:
|
-- mirrored (default: False).
|
||||||
--
|
|
||||||
-- > mouseResizableTile { isMirrored = ... }
|
|
||||||
} deriving (Show, Read)
|
} deriving (Show, Read)
|
||||||
|
|
||||||
mouseResizableTile :: MouseResizableTile a
|
mouseResizableTile :: MouseResizableTile a
|
||||||
|
Reference in New Issue
Block a user