Sophie

Sophie

distrib > Fedora > 18 > i386 > by-pkgid > 16551e78563a5b49ff9624ee1c8b8101 > files > 707

ghc-xmonad-contrib-devel-0.11-1.1.fc18.i686.rpm

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>XMonad.Actions.DynamicWorkspaces</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_XMonad-Actions-DynamicWorkspaces.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="src/XMonad-Actions-DynamicWorkspaces.html">Source</a></li><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">xmonad-contrib-0.11: Third party extensions for xmonad</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Portability</th><td>unportable</td></tr><tr><th>Stability</th><td>unstable</td></tr><tr><th>Maintainer</th><td>none</td></tr><tr><th>Safe Haskell</th><td>Safe-Infered</td></tr></table><p class="caption">XMonad.Actions.DynamicWorkspaces</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Usage
</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Provides bindings to add and delete workspaces.
</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:addWorkspace">addWorkspace</a> :: <a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:addWorkspacePrompt">addWorkspacePrompt</a> :: <a href="XMonad-Prompt.html#t:XPConfig">XPConfig</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:removeWorkspace">removeWorkspace</a> :: <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:removeEmptyWorkspace">removeEmptyWorkspace</a> :: <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:removeEmptyWorkspaceAfter">removeEmptyWorkspaceAfter</a> :: <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:removeEmptyWorkspaceAfterExcept">removeEmptyWorkspaceAfterExcept</a> :: [<a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:addHiddenWorkspace">addHiddenWorkspace</a> :: <a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:withWorkspace">withWorkspace</a> :: <a href="XMonad-Prompt.html#t:XPConfig">XPConfig</a> -&gt; (<a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a>) -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:selectWorkspace">selectWorkspace</a> :: <a href="XMonad-Prompt.html#t:XPConfig">XPConfig</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:renameWorkspace">renameWorkspace</a> :: <a href="XMonad-Prompt.html#t:XPConfig">XPConfig</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:renameWorkspaceByName">renameWorkspaceByName</a> :: <a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:toNthWorkspace">toNthWorkspace</a> :: (<a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a>) -&gt; <a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li><li class="src short"><a href="#v:withNthWorkspace">withNthWorkspace</a> :: (<a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:WindowSet">WindowSet</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:WindowSet">WindowSet</a>) -&gt; <a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a></li></ul></div><div id="interface"><h1 id="g:1">Usage
</h1><div class="doc"><p>You can use this module with the following in your <code>~/.xmonad/xmonad.hs</code> file:
</p><pre> import XMonad.Actions.DynamicWorkspaces
 import XMonad.Actions.CopyWindow(copy)
</pre><p>Then add keybindings like the following:
</p><pre>   , ((modm .|. shiftMask, xK_BackSpace), removeWorkspace)
   , ((modm .|. shiftMask, xK_v      ), selectWorkspace defaultXPConfig)
   , ((modm, xK_m                    ), withWorkspace defaultXPConfig (windows . W.shift))
   , ((modm .|. shiftMask, xK_m      ), withWorkspace defaultXPConfig (windows . copy))
   , ((modm .|. shiftMask, xK_r      ), renameWorkspace defaultXPConfig)
</pre><pre> -- mod-[1..9]       %! Switch to workspace N
 -- mod-shift-[1..9] %! Move client to workspace N
    ++
    zip (zip (repeat (modm)) [xK_1..xK_9]) (map (withNthWorkspace W.greedyView) [0..])
    ++
    zip (zip (repeat (modm .|. shiftMask)) [xK_1..xK_9]) (map (withNthWorkspace W.shift) [0..])
</pre><p>For detailed instructions on editing your key bindings, see
 <a href="XMonad-Doc-Extending.html#Editing_key_bindings">XMonad.Doc.Extending</a>. See also the documentation for
 <a href="XMonad-Actions-CopyWindow.html">XMonad.Actions.CopyWindow</a>, <code><a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Operations.html#v:windows">windows</a></code>, <code><a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-StackSet.html#v:shift">shift</a></code>, and <code>defaultXPConfig</code>.
</p></div><div class="top"><p class="src"><a name="v:addWorkspace" class="def">addWorkspace</a> :: <a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#addWorkspace" class="link">Source</a></p><div class="doc"><p>Add a new workspace with the given name, or do nothing if a
   workspace with the given name already exists; then switch to the
   newly created workspace.
</p></div></div><div class="top"><p class="src"><a name="v:addWorkspacePrompt" class="def">addWorkspacePrompt</a> :: <a href="XMonad-Prompt.html#t:XPConfig">XPConfig</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#addWorkspacePrompt" class="link">Source</a></p><div class="doc"><p>Prompt for the name of a new workspace, add it if it does not
   already exist, and switch to it.
</p></div></div><div class="top"><p class="src"><a name="v:removeWorkspace" class="def">removeWorkspace</a> :: <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#removeWorkspace" class="link">Source</a></p><div class="doc"><p>Remove the current workspace.
</p></div></div><div class="top"><p class="src"><a name="v:removeEmptyWorkspace" class="def">removeEmptyWorkspace</a> :: <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#removeEmptyWorkspace" class="link">Source</a></p><div class="doc"><p>Remove the current workspace if it contains no windows.
</p></div></div><div class="top"><p class="src"><a name="v:removeEmptyWorkspaceAfter" class="def">removeEmptyWorkspaceAfter</a> :: <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#removeEmptyWorkspaceAfter" class="link">Source</a></p><div class="doc"><p>Remove the current workspace after an operation if it is empty and hidden.
   Can be used to remove a workspace if it is empty when leaving it. The
   operation may only change workspace once, otherwise the workspace will not
   be removed.
</p></div></div><div class="top"><p class="src"><a name="v:removeEmptyWorkspaceAfterExcept" class="def">removeEmptyWorkspaceAfterExcept</a> :: [<a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#removeEmptyWorkspaceAfterExcept" class="link">Source</a></p><div class="doc"><p>Like <code><a href="XMonad-Actions-DynamicWorkspaces.html#v:removeEmptyWorkspaceAfter">removeEmptyWorkspaceAfter</a></code> but use a list of sticky workspaces,
   whose entries will never be removed.
</p></div></div><div class="top"><p class="src"><a name="v:addHiddenWorkspace" class="def">addHiddenWorkspace</a> :: <a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#addHiddenWorkspace" class="link">Source</a></p><div class="doc"><p>Add a new hidden workspace with the given name, or do nothing if
   a workspace with the given name already exists.
</p></div></div><div class="top"><p class="src"><a name="v:withWorkspace" class="def">withWorkspace</a> :: <a href="XMonad-Prompt.html#t:XPConfig">XPConfig</a> -&gt; (<a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a>) -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#withWorkspace" class="link">Source</a></p></div><div class="top"><p class="src"><a name="v:selectWorkspace" class="def">selectWorkspace</a> :: <a href="XMonad-Prompt.html#t:XPConfig">XPConfig</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#selectWorkspace" class="link">Source</a></p></div><div class="top"><p class="src"><a name="v:renameWorkspace" class="def">renameWorkspace</a> :: <a href="XMonad-Prompt.html#t:XPConfig">XPConfig</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#renameWorkspace" class="link">Source</a></p></div><div class="top"><p class="src"><a name="v:renameWorkspaceByName" class="def">renameWorkspaceByName</a> :: <a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#renameWorkspaceByName" class="link">Source</a></p></div><div class="top"><p class="src"><a name="v:toNthWorkspace" class="def">toNthWorkspace</a> :: (<a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a>) -&gt; <a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#toNthWorkspace" class="link">Source</a></p></div><div class="top"><p class="src"><a name="v:withNthWorkspace" class="def">withNthWorkspace</a> :: (<a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-String.html#t:String">String</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:WindowSet">WindowSet</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:WindowSet">WindowSet</a>) -&gt; <a href="/usr/share/doc/ghc/html/libraries/base-4.5.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="/usr/share/doc/ghc/html/libraries/xmonad-0.11/XMonad-Core.html#t:X">X</a> <a href="/usr/share/doc/ghc/html/libraries/ghc-prim-0.2.0.0/GHC-Tuple.html#t:-40--41-">()</a><a href="src/XMonad-Actions-DynamicWorkspaces.html#withNthWorkspace" class="link">Source</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.10.0</p></div></body></html>