Xmonad

Dynamic window manager for X Window System


title: "Xmonad" type: doc version: 1 created: 2026-02-28 author: "Wikipedia contributors" status: active scope: public tags: ["free-software-programmed-in-haskell", "free-x-window-managers", "tiling-window-managers", "x-window-managers-extensible-by-scripting", "software-using-the-bsd-license"] description: "Dynamic window manager for X Window System" topic_path: "general/free-software-programmed-in-haskell" source: "https://en.wikipedia.org/wiki/Xmonad" license: "CC BY-SA 4.0" wikipedia_page_id: 0 wikipedia_revision_id: 0

::summary Dynamic window manager for X Window System ::

::data[format=table title="Infobox software"]

FieldValue
namexmonad
logoXmonad-2022-new-logo.svg
screenshotXmonad screenshot.png
screenshot_altXMonad in tiling mode with two URXVT terminals and pcmanFM open
captionxmonad in tiling mode
authorSpencer Janssen, Don Stewart, Jason Creighton
released
latest release version
latest release date
latest preview version
latest preview date
programming languageHaskell
operating systemPOSIX compatible
platformCross-platform; requires an X Window System and GHC
size56 KB (source code)
languageEnglish
genreWindow manager
licenseBSD 3-clause
::

| name = xmonad | logo = Xmonad-2022-new-logo.svg | screenshot = Xmonad screenshot.png | screenshot_alt = XMonad in tiling mode with two URXVT terminals and pcmanFM open | caption = xmonad in tiling mode | author = Spencer Janssen, Don Stewart, Jason Creighton | released = | latest release version = | latest release date = | latest preview version = | latest preview date = | programming language = Haskell | operating system = POSIX compatible | platform = Cross-platform; requires an X Window System and GHC | size = 56 KB (source code) | language = English | genre = Window manager | license = BSD 3-clause ::figure[src="https://upload.wikimedia.org/wikipedia/commons/7/71/Xmonad-screen-triplehead-dons.png" caption="xmonad's [[Xinerama]] support: tiling on three screens simultaneously."] ::

::figure[src="https://upload.wikimedia.org/wikipedia/commons/6/64/Xmonad-tall-status-dons.png" caption="tiling mode"] ::

xmonad is a dynamic window manager (tiling) for the X Window System, noted for being written in the functional programming language Haskell.

Window manager

Begun in March 2007, version 0.1 was announced in April 2007 as 500 lines of Haskell{{cite web |url=http://www.osnews.com/story/17744/Xmonad-a-Tiling-Window-Manager-Written-in-Haskell |title=Xmonad: a Tiling Window Manager Written in Haskell |publisher=OSNews |date=2007-05-22 |access-date=2007-09-23 |archive-url=https://web.archive.org/web/20080411134807/http://www.osnews.com/story/17744/Xmonad-a-Tiling-Window-Manager-Written-in-Haskell/ |archive-date=2008-04-11 |url-status=live

While originally a clone of dwm (derivative in areas such as default keybindings), xmonad now supports features unavailable to dwm users{{cite web |url=http://www.osnews.com/story.php/18009/Keyboard-Driven-Environments-Open-a-New-Window/ |title=Keyboard-Driven Environments Open a New Window |publisher=OSNews |date=2007-05-31 |access-date=2007-05-31 |archive-url=https://web.archive.org/web/20070604030724/http://www.osnews.com/story.php/18009/Keyboard-Driven-Environments-Open-a-New-Window |archive-date=2007-06-04 |url-status=live |url=http://osnews.com/story.php/18794/xmonad-0.4-Released |title=xmonad 0.4 Released |publisher=OSNews |date=2007-10-19 |access-date=2007-12-23 |archive-url=https://web.archive.org/web/20071222205622/http://www.osnews.com/story.php/18794/xmonad-0.4-Released |archive-date=2007-12-22 |url-status=live |url=http://sequence.complete.org/hwn/20070427 |title=Haskell Weekly News: April 27, 2007 |publisher=Haskell Weekly News |date=2007-04-27 |access-date=2007-05-23 |archive-url=https://web.archive.org/web/20070529082510/http://sequence.complete.org/hwn/20070427 |archive-date=2007-05-29 |url-status=dead

Haskell project

In 2023 the man page stated: {{Blockquote|By utilising the expressivity of a modern functional language with a rich static type system, xmonad provides a complete, featureful window manager [...], with an emphasis on correctness and robustness. Internal properties of the window manager are checked using a combination of static guarantees provided by the type system, and type-based automated testing. A benefit of this is that the code is simple to understand, and easy to modify.{{cite web |url=http://www.xmonad.org/manpage.html |title=Manpage of xmonad |publisher=xmonad.org |date=2021-10-27 |access-date=2023-09-01 |archive-url=https://web.archive.org/web/20230813203216/https://xmonad.org/manpage.html |archive-date=2023-08-13 |url-status=live

Since xmonad's inception, when its small source code size of 500 lines of code was advertised, it has grown to about 2,000 lines .

Extensions to the core system, including emulation of other window managers, and unusual layout algorithms, such as window tiling based on the Fibonacci spiral—have been implemented by the active community and are available as a library.{{cite web |url=http://xmonad.org/contrib.html |title=xmonad: Contributed code |publisher=xmonad.org |date=2007-05-22 |access-date=2007-05-23 |archive-url=https://web.archive.org/web/20070916213057/http://xmonad.org/contrib.html |archive-date=2007-09-16 |url-status=live

Along with obviating the need for a mouse, the xmonad developers make heavy use of semi-formal methods and program derivation for improving reliability and enabling a total line of code count less than 1200, as of version 0.7; window manager properties (such as the behavior of window focus) are checked through use of QuickCheck. This emphasis makes xmonad unusual in a number of ways; besides being the first window manager written in Haskell, it is also the first to use the zipper data structure for automatically managing focus, and its core has been proven to be safe with respect to pattern matches, contributing further to reliability. The developers write: ::quote xmonad is a tiling window manager for the X Window system, implemented, configured and dynamically extensible in Haskell. This demonstration presents the case that software dominated by side effects can be developed with the precision and efficiency we expect from Haskell by utilising purely functional data structures, an expressive type system, extended static checking and property-based testing. In addition, we describe the use of Haskell as an application configuration and extension language. ::

The code is separated into side-effect free code, and a thin wrapper for the side-effects. According to Alejandro Serrano Mena, there are two ways to implement domain-specific languages for actions in Haskell applications and libraries: "developing a combinator library" or "rolling your own monad", with xmonad being a successful example of the latter. xmonad was regarded as one of the most well known Haskell projects in a 2013 functional programming book.

Reception

Linux Magazine included xmonad in a list of "My Top Resources of 2009". In 2012, How-To Geek described xmonad as having good, but complex, ability to be configured, and it was included in a 2013 list of eight desktop environments for Linux. Lifehacker wrote that the basic operations of xmonad's user interface can be taught using a small set of instructions. A high level of customisation and speed were noted by Network World, and in MakeUseOf xmonad was reviewed positively compared to Openbox.

In 2016 Ars Technica said xmonad and Awesome had more advanced tiling ability than Cinnamon. In 2017 it was described as powerful, with application as a window manager for big data, while in an article on opensource.com on the other hand, dwm was chosen over xmonad. A TechRadar review of the "Best Linux desktop of 2018" said "If there's one desktop environment that stands out from all the others we have here, it's this one."

Due to the small number of source lines of code of the Xmonad application, the use of the purely functional programming language Haskell, and recorded use of a rigorous software testing procedure, it is sometimes used as a baseline application in other research projects. This has included re-implementing xmonad using the Rocq proof assistant, a determination xmonad is an imperative program, and studies of package management relating to a Linux distribution NixOS that is based on the package manager Nix.

References

Works cited

References

  1. "Initial import: xmonad/xmonad@b2c1430".
  2. "xmonad: download". suckless.org.
  3. Janssen, Spencer. (2007-04-22). "Announce: xmonad 0.1".
  4. link. (2018-09-18 on the dwm mailing list)
  5. [http://dwm.suckless.org/patches/fibonacci Suckless.org: Fibonacci layouts patch] {{Webarchive. link. (2013-04-13 to dwm)
  6. xmonad users generate significant traffic in the [http://gogloom.com/FreeNode/xmonad/ #xmonad] {{Webarchive. link. (2007-12-29 [[Internet Relay Chat]] (IRC) channel and the xmonad mailing list; also, there are many commits to the extension library from non-core devs (see the [http://xmonad.org/statistics.html xmonad statistic page] {{Webarchive). link. (2007-12-23))
  7. Mitchell, Neil. (9 May 2007). "Neil Mitchell's Haskell Blog: Does XMonad crash?".
  8. Stewart & Janssen, 2007
  9. Mena, Alejandro Serrano. (5 March 2014). "Beginning Haskell: A Project-Based Approach". [[Apress]].
  10. (24 September 2018). "Das Curry-Buch – Funktional programmieren lernen mit JavaScript". [[O'Reilly Media.
  11. Zawodny, Jeremy. (2009-12-06). "My Top Resources of 2009". [[Linux Magazine]].
  12. Hoffman, Chris. (2012-05-24). "How to Use Xmonad, a Tiling Window Manager for Linux". How-To Geek.
  13. Hoffman, Chris. (2013-05-18). "Linux Users Have a Choice: 8 Linux Desktop Environments". How-To Geek.
  14. Stieben, Danny. (2018-09-18). "Need A Fresh Desktop Environment for Linux? Try Openbox Or xmonad".
  15. (2016-08-04). "Mint 18 review: "Just works" Linux doesn't get any better than this". [[Ars Technica]].
  16. (2017-07-18). "Top 4 reasons I use dwm for my Linux window manager". [[Red Hat]].
  17. (2018-01-15). "Best Linux desktop of 2018". [[Future plc]].
  18. (2009). "Masterminds of Programming: Conversations with the Creators of Major Programming Languages". [[O'Reilly Media]].
  19. Mitchell, Neil. (June 2008). "Transformation and Analysis". University of York.
  20. (14 September 2017). "Practical Concurrent Haskell: With Big Data Applications". [[Apress]].
  21. Lunduke, Bryan. (15 May 2013). "10 amazing Linux desktop environments you've probably never seen". [[Network World]].
  22. Goerzen, John. (2013-01-08). "I Raised My Kids On the Command Line...and They Love It". [[Univision Communications]].
  23. (2015). "How functional programming mattered". National Science Review.
  24. Swierstra, Wouter. (13 September 2012). "xmonad in Coq (Experience Report) Programming a Window Manager with a Proof Assistant". [[Association for Computing Machinery]].
  25. (November 2010). "NixOS: A Purely Functional Linux Distribution". [[Journal of Functional Programming]].
  26. Lippmeier, Ben. (May 2010). "Type Inference and Optimisation for an Impure World". Australian National University.

::callout[type=info title="Wikipedia Source"] This article was imported from Wikipedia and is available under the Creative Commons Attribution-ShareAlike 4.0 License. Content has been adapted to SurfDoc format. Original contributors can be found on the article history page. ::

free-software-programmed-in-haskellfree-x-window-managerstiling-window-managersx-window-managers-extensible-by-scriptingsoftware-using-the-bsd-license