xmonad-contrib-0.18.1: Community-maintained extensions for xmonad

Copyright | (c) Joe Thornber <joe.thornber@gmail.com>
License | BSD3-style (see LICENSE)
Maintainer | Joe Thornber <joe.thornber@gmail.com>
Stability | stable
Portability | portable
Safe Haskell | None
Language | Haskell2010

XMonad.Layout.Spiral

Contents

- Usage

Description

A spiral tiling layout.

Synopsis

- spiral :: Rational -> SpiralWithDir a
- spiralWithDir :: Direction -> Rotation -> Rational -> SpiralWithDir a
- data Rotation
  - = CW
  - | CCW
- data Direction
  - = East
  - | South
  - | West
  - | North
- data SpiralWithDir a

# Usage

You can use this module with the following in your `xmonad.hs`:

    import XMonad.Layout.Spiral

Then edit your `layoutHook` by adding the Spiral layout:

    myLayout =  spiral (6/7) ||| etc..
    main = xmonad def { layoutHook = myLayout }

For more detailed instructions on editing the layoutHook see the tutorial and XMonad.Doc.Extending.

spiral :: Rational -> SpiralWithDir a #

A spiral layout. The parameter controls the size ratio between successive windows in the spiral. Sensible values range from 0 up to the aspect ratio of your monitor (often 4/3).

By default, the spiral is counterclockwise, starting to the east. See also `spiralWithDir`.

spiralWithDir :: Direction -> Rotation -> Rational -> SpiralWithDir a #

Create a spiral layout, specifying the starting cardinal direction, the spiral direction (clockwise or counterclockwise), and the size ratio.

data Rotation #

Constructors

CW |
CCW |

#### Instances

Instances details

Read Rotation # |
Instance details Defined in XMonad.Layout.Spiral Methods readsPrec :: Int -> ReadS Rotation # readList :: ReadS [Rotation] # readPrec :: ReadPrec Rotation # readListPrec :: ReadPrec [Rotation] #
Show Rotation # |
Instance details Defined in XMonad.Layout.Spiral Methods showsPrec :: Int -> Rotation -> ShowS # show :: Rotation -> String # showList :: [Rotation] -> ShowS #

data Direction #

Constructors

East |
South |
West |
North |

#### Instances

Instances details

Enum Direction # |

Instance details

Defined in XMonad.Layout.Spiral

Methods

succ :: Direction -> Direction #

pred :: Direction -> Direction #

toEnum :: Int -> Direction #

fromEnum :: Direction -> Int #

enumFrom :: Direction -> [Direction] #

enumFromThen :: Direction -> Direction -> [Direction] #

enumFromTo :: Direction -> Direction -> [Direction] #

enumFromThenTo :: Direction -> Direction -> Direction -> [Direction] #

Read Direction # |
Instance details Defined in XMonad.Layout.Spiral Methods readsPrec :: Int -> ReadS Direction # readList :: ReadS [Direction] # readPrec :: ReadPrec Direction # readListPrec :: ReadPrec [Direction] #
Show Direction # |
Instance details Defined in XMonad.Layout.Spiral Methods showsPrec :: Int -> Direction -> ShowS # show :: Direction -> String # showList :: [Direction] -> ShowS #
Eq Direction # |
Instance details Defined in XMonad.Layout.Spiral Methods (==) :: Direction -> Direction -> Bool # (/=) :: Direction -> Direction -> Bool #

data SpiralWithDir a #

#### Instances

Instances details

LayoutClass SpiralWithDir a # |

Instance details

Defined in XMonad.Layout.Spiral

Methods

runLayout :: Workspace WorkspaceId (SpiralWithDir a) a -> Rectangle -> X ([(a, Rectangle)], Maybe (SpiralWithDir a)) #

doLayout :: SpiralWithDir a -> Rectangle -> Stack a -> X ([(a, Rectangle)], Maybe (SpiralWithDir a)) #

pureLayout :: SpiralWithDir a -> Rectangle -> Stack a -> [(a, Rectangle)] #

emptyLayout :: SpiralWithDir a -> Rectangle -> X ([(a, Rectangle)], Maybe (SpiralWithDir a)) #

handleMessage :: SpiralWithDir a -> SomeMessage -> X (Maybe (SpiralWithDir a)) #

pureMessage :: SpiralWithDir a -> SomeMessage -> Maybe (SpiralWithDir a) #

description :: SpiralWithDir a -> String #

Read (SpiralWithDir a) # |
Instance details Defined in XMonad.Layout.Spiral Methods readsPrec :: Int -> ReadS (SpiralWithDir a) # readList :: ReadS [SpiralWithDir a] # readPrec :: ReadPrec (SpiralWithDir a) # readListPrec :: ReadPrec [SpiralWithDir a] #
Show (SpiralWithDir a) # |
Instance details Defined in XMonad.Layout.Spiral Methods showsPrec :: Int -> SpiralWithDir a -> ShowS # show :: SpiralWithDir a -> String # showList :: [SpiralWithDir a] -> ShowS #