Giter VIP home page Giter VIP logo

xmonad-layout-padding's Introduction

xmonad-layout-padding

A layout module for xmonad featuring window padding

Usage

Since this is not yet included in Xmonad-Contrib, simply download Padding.hs and place it in your '~/.xmonad/lib/' folder (create it if it doesn't exist). Then it can be imported with

import Padding

The Padding module only exports a single function: padding, which takes two arguments: the first is the amount of padding for the top/bottom of windows, the second is for the sides (just as with css).

Example

-- File: xmonad.hs
import XMonad

import Padding

main = xmonad $ defaultConfig
	{ -- Whatever your usual configs are
      layoutHook = myLayoutHook
	}


-- Use whatever layouts you want
myLayoutHook = centered ||| tiled ||| Full
    where  
        -- Padding modifies a layout
        -- the centered layout is like Full, except with 175 pixels of
        -- space on the left and right sides.
        centered = padding 0 175 $ Full

        -- the tiled layout is like Tall, except each window will have 5
        -- pixels of space on top and 2 on the sides
        tiled = padding 5 2 $ Tall 1 (5/8) (5/100)

Acknowledgements

This module is based extremely heavily (as in - I barely changed anything at all) on Xmonad.Layout.Spacing, (c) Brent Yorgey, originally (and still) licensed under a BSD3 license.

xmonad-layout-padding's People

Contributors

brianshourd avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

Forkers

lordi

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.