Tags in xmonad?

Is it possible to get dwm-style tags in xmonad instead of conventional workspaces?

Between these two extensions, I think that you can get dwm-style tagging
http://xmonad.org/xmonad-docs/xmonad-co … ndows.html
http://xmonad.org/xmonad-docs/xmonad-co … indow.html

Similar Messages

  • On the search for a(nother) tiling-wm

    hi everybody.
    i've been using wmii for a couple of month now and i am quite happy, except for a few little things. however, these things irritated me more and more over time, so i decided to look for alternatives. i have the following requirements:
    - wmii-like dynamic tagging
    - a "tabbed-layout" (ie, h-tab layout, fullscreen with only tabs shown needs to exist)
    - it should be possible to have a second statusbar showing information piped in from any source (i don't care if its conky, xmobar, dzen, whatever).
    first i thought that it would be easy to find another tiling wm, however after reading through the comparison table at the wiki i found that it is not that easy.
    wmii misses the tabbed-layout feature which exists in i3. i3 misses the dynamic tagging unfortunately.
    xmonad has the tabbed layout and the second statusbar (at least i think so since i saw screenshots with two status-bars), however i did not manage to get xmonad.actions.tagwindows (which i think may be used to do something like dynamic tagging) to work at all.
    stumpwm (which seems to be great btw) just as awesome lacks as most other tiling wms listed in the comparison table in the wiki the tabbed layout feature i am looking for.
    i'd love to use dwm, however i didn't find any patches flying around providing the functionality i need.
    so, fellow archers. has anybody a configuration in any tiling-wm that achieves these three goals (dynamic tags aka workspaces, tabbed layout and a second statusbar)? if so, please step forward and show me your config

    Ashren wrote:dw: Have you read the comments in the xmonad.actions.tagwindows code? Look here: http://code.haskell.org/XMonadContrib/X … Windows.hs
    hi ashren, first of, thanks for replying.
    i did have a look at the comments provided in tagwindows and i realized that at least it does something. i did come so far that i could assign tags to windows (which is good).
    i am still struggeling however to get keybindings done in a wmii way. which means tagging a window also removes the current tag and basically "hides" the active client from the current workspace by "moving" it to the newly assigned tag). tagwindows currently only adds the additional tag and i am not able to generate a keybinding that lets me cycle through tags and if i choose a tag showing only those clients being tagged with the chosen tag. difficult to explain somehow.
    anyone here uses tagwindows? or would i be better off asking in #xmonad?

  • Xmonad.hs file: I need a template, but the official one gives errors

    I just installed Xmonad and I am LOVING it, but I need some help setting up an xmonad.hs file. I created one in ~/.xmonad/xmonad.hs and looked for a well-commented template since I don't know any Haskell (or any programming language, for that matter). This is the one I copied to the file:
    http://www.haskell.org/haskellwiki/Xmon … _xmonad.hs
    Which gives:
    -- xmonad example config file.
    -- A template showing all available configuration hooks,
    -- and how to override the defaults in your own xmonad.hs conf file.
    -- Normally, you'd only override those defaults you care about.
    import XMonad
    import System.Exit
    import qualified XMonad.StackSet as W
    import qualified Data.Map as M
    -- The preferred terminal program, which is used in a binding below and by
    -- certain contrib modules.
    myTerminal = "xterm"
    -- Width of the window border in pixels.
    myBorderWidth = 1
    -- modMask lets you specify which modkey you want to use. The default
    -- is mod1Mask ("left alt"). You may also consider using mod3Mask
    -- ("right alt"), which does not conflict with emacs keybindings. The
    -- "windows key" is usually mod4Mask.
    myModMask = mod1Mask
    -- The mask for the numlock key. Numlock status is "masked" from the
    -- current modifier status, so the keybindings will work with numlock on or
    -- off. You may need to change this on some systems.
    -- You can find the numlock modifier by running "xmodmap" and looking for a
    -- modifier with Num_Lock bound to it:
    -- > $ xmodmap | grep Num
    -- > mod2 Num_Lock (0x4d)
    -- Set numlockMask = 0 if you don't have a numlock key, or want to treat
    -- numlock status separately.
    myNumlockMask = mod2Mask
    -- The default number of workspaces (virtual screens) and their names.
    -- By default we use numeric strings, but any string may be used as a
    -- workspace name. The number of workspaces is determined by the length
    -- of this list.
    -- A tagging example:
    -- > workspaces = ["web", "irc", "code" ] ++ map show [4..9]
    myWorkspaces = ["1","2","3","4","5","6","7","8","9"]
    -- Border colors for unfocused and focused windows, respectively.
    myNormalBorderColor = "#dddddd"
    myFocusedBorderColor = "#ff0000"
    -- Default offset of drawable screen boundaries from each physical
    -- screen. Anything non-zero here will leave a gap of that many pixels
    -- on the given edge, on the that screen. A useful gap at top of screen
    -- for a menu bar (e.g. 15)
    -- An example, to set a top gap on monitor 1, and a gap on the bottom of
    -- monitor 2, you'd use a list of geometries like so:
    -- > defaultGaps = [(18,0,0,0),(0,18,0,0)] -- 2 gaps on 2 monitors
    -- Fields are: top, bottom, left, right.
    myDefaultGaps = [(0,0,0,0)]
    -- Key bindings. Add, modify or remove key bindings here.
    myKeys conf@(XConfig {XMonad.modMask = modMask}) = M.fromList $
    -- launch a terminal
    [ ((modMask .|. shiftMask, xK_Return), spawn $ XMonad.terminal conf)
    -- launch dmenu
    , ((modMask, xK_p ), spawn "exe=`dmenu_path | dmenu` && eval \"exec $exe\"")
    -- launch gmrun
    , ((modMask .|. shiftMask, xK_p ), spawn "gmrun")
    -- close focused window
    , ((modMask .|. shiftMask, xK_c ), kill)
    -- Rotate through the available layout algorithms
    , ((modMask, xK_space ), sendMessage NextLayout)
    -- Reset the layouts on the current workspace to default
    , ((modMask .|. shiftMask, xK_space ), setLayout $ XMonad.layoutHook conf)
    -- Resize viewed windows to the correct size
    , ((modMask, xK_n ), refresh)
    -- Move focus to the next window
    , ((modMask, xK_Tab ), windows W.focusDown)
    -- Move focus to the next window
    , ((modMask, xK_j ), windows W.focusDown)
    -- Move focus to the previous window
    , ((modMask, xK_k ), windows W.focusUp )
    -- Move focus to the master window
    , ((modMask, xK_m ), windows W.focusMaster )
    -- Swap the focused window and the master window
    , ((modMask, xK_Return), windows W.swapMaster)
    -- Swap the focused window with the next window
    , ((modMask .|. shiftMask, xK_j ), windows W.swapDown )
    -- Swap the focused window with the previous window
    , ((modMask .|. shiftMask, xK_k ), windows W.swapUp )
    -- Shrink the master area
    , ((modMask, xK_h ), sendMessage Shrink)
    -- Expand the master area
    , ((modMask, xK_l ), sendMessage Expand)
    -- Push window back into tiling
    , ((modMask, xK_t ), withFocused $ windows . W.sink)
    -- Increment the number of windows in the master area
    , ((modMask , xK_comma ), sendMessage (IncMasterN 1))
    -- Deincrement the number of windows in the master area
    , ((modMask , xK_period), sendMessage (IncMasterN (-1)))
    -- toggle the status bar gap
    , ((modMask , xK_b ),
    modifyGap (\i n -> let x = (XMonad.defaultGaps conf ++ repeat (0,0,0,0)) !! i
    in if n == x then (0,0,0,0) else x))
    -- Quit xmonad
    , ((modMask .|. shiftMask, xK_q ), io (exitWith ExitSuccess))
    -- Restart xmonad
    , ((modMask , xK_q ),
    broadcastMessage ReleaseResources >> restart "xmonad" True)
    ++
    -- mod-[1..9], Switch to workspace N
    -- mod-shift-[1..9], Move client to workspace N
    [((m .|. modMask, k), windows $ f i)
    | (i, k) <- zip (XMonad.workspaces conf) [xK_1 .. xK_9]
    , (f, m) <- [(W.greedyView, 0), (W.shift, shiftMask)]]
    ++
    -- mod-{w,e,r}, Switch to physical/Xinerama screens 1, 2, or 3
    -- mod-shift-{w,e,r}, Move client to screen 1, 2, or 3
    [((m .|. modMask, key), screenWorkspace sc >>= flip whenJust (windows . f))
    | (key, sc) <- zip [xK_w, xK_e, xK_r] [0..]
    , (f, m) <- [(W.view, 0), (W.shift, shiftMask)]]
    -- Mouse bindings: default actions bound to mouse events
    myMouseBindings (XConfig {XMonad.modMask = modMask}) = M.fromList $
    -- mod-button1, Set the window to floating mode and move by dragging
    [ ((modMask, button1), (\w -> focus w >> mouseMoveWindow w))
    -- mod-button2, Raise the window to the top of the stack
    , ((modMask, button2), (\w -> focus w >> windows W.swapMaster))
    -- mod-button3, Set the window to floating mode and resize by dragging
    , ((modMask, button3), (\w -> focus w >> mouseResizeWindow w))
    -- you may also bind events to the mouse scroll wheel (button4 and button5)
    -- Layouts:
    -- You can specify and transform your layouts by modifying these values.
    -- If you change layout bindings be sure to use 'mod-shift-space' after
    -- restarting (with 'mod-q') to reset your layout state to the new
    -- defaults, as xmonad preserves your old layout settings by default.
    -- The available layouts. Note that each layout is separated by |||,
    -- which denotes layout choice.
    myLayout = tiled ||| Mirror tiled ||| Full
    where
    -- default tiling algorithm partitions the screen into two panes
    tiled = Tall nmaster delta ratio
    -- The default number of windows in the master pane
    nmaster = 1
    -- Default proportion of screen occupied by master pane
    ratio = 1/2
    -- Percent of screen to increment by when resizing panes
    delta = 3/100
    -- Window rules:
    -- Execute arbitrary actions and WindowSet manipulations when managing
    -- a new window. You can use this to, for example, always float a
    -- particular program, or have a client always appear on a particular
    -- workspace.
    -- To find the property name associated with a program, use
    -- > xprop | grep WM_CLASS
    -- and click on the client you're interested in.
    -- To match on the WM_NAME, you can use 'title' in the same way that
    -- 'className' and 'resource' are used below.
    myManageHook = composeAll
    [ className =? "MPlayer" --> doFloat
    , className =? "Gimp" --> doFloat
    , resource =? "desktop_window" --> doIgnore
    , resource =? "kdesktop" --> doIgnore ]
    -- Whether focus follows the mouse pointer.
    myFocusFollowsMouse :: Bool
    myFocusFollowsMouse = True
    -- Status bars and logging
    -- Perform an arbitrary action on each internal state change or X event.
    -- See the 'DynamicLog' extension for examples.
    -- To emulate dwm's status bar
    -- > logHook = dynamicLogDzen
    myLogHook = return ()
    -- Now run xmonad with all the defaults we set up.
    -- Run xmonad with the settings you specify. No need to modify this.
    main = xmonad defaults
    -- A structure containing your configuration settings, overriding
    -- fields in the default config. Any you don't override, will
    -- use the defaults defined in xmonad/XMonad/Config.hs
    -- No need to modify this.
    defaults = defaultConfig {
    -- simple stuff
    terminal = myTerminal,
    focusFollowsMouse = myFocusFollowsMouse,
    borderWidth = myBorderWidth,
    modMask = myModMask,
    numlockMask = myNumlockMask,
    workspaces = myWorkspaces,
    normalBorderColor = myNormalBorderColor,
    focusedBorderColor = myFocusedBorderColor,
    defaultGaps = myDefaultGaps,
    -- key bindings
    keys = myKeys,
    mouseBindings = myMouseBindings,
    -- hooks, layouts
    layoutHook = myLayout,
    manageHook = myManageHook,
    logHook = myLogHook
    So I copied all this into my new xmonad.hs file and then restarted xmonad with mod+q, but a window popped up giving me this error:
    Error detected while loading xmonad configuration file: /home/agi/.xmonad/xmonad.hs
    on the commandline:
    Warning: -no-recomp is deprecated: Use -fforce-recomp instead
    xmonad.hs:141:10: Not in scope: `modifyGap'
    xmonad.hs:141:38: Not in scope: `XMonad.defaultGaps'
    xmonad.hs:273:8: Not in scope: `defaultGaps'
    Please check the file for errors.
    I'm not exactly sure what any of this means. If someone could help me decipher this or, better yet, post a better (well-commented so I can understand it) default xmonad.hs file that I can use, that would be great.

    Alright! I've got xmonad almost set up! One major thing I still want to do is add some sort of pager-like display in the top left of xmobar. Just to show workspaces 1-9 and highlight the one I'm in (giving a preview of my windows or telling me which ones I have windows in would be great, but not absolutely necessary).
    I can't find anything (that I understand) online. Help?
    Here's my xmonad.hs:
    import XMonad
    import XMonad.Hooks.DynamicLog
    import XMonad.Hooks.ManageDocks
    import XMonad.Util.Run(spawnPipe)
    import XMonad.Util.EZConfig(additionalKeys)
    import System.IO
    myManageHook = composeAll
    [ className =? "Gimp" --> doFloat
    main = do
    xmproc <- spawnPipe "/path/to/xmobarbinary /home/jgoerzen/.xmobarrc"
    -- make sure to edit paths to xmobar and .xmobarrc to match your system.
    -- If xmobar is in your $PATH, with config ~/.xmobarrc you don't need the
    -- xmobar path or config file, use: xmproc <- spawnPipe "xmobar"
    xmonad $ defaultConfig
    { manageHook = manageDocks <+> manageHook defaultConfig
    , layoutHook = avoidStruts $ layoutHook defaultConfig
    , logHook = dynamicLogWithPP $ xmobarPP
    { ppOutput = hPutStrLn xmproc
    , ppTitle = xmobarColor "green" "" . shorten 50
    , modMask = mod1Mask
    } `additionalKeys`
    [ ((mod1Mask .|. shiftMask, xK_z), spawn "xscreensaver-command -lock")
    , ((controlMask, xK_Print), spawn "scrot -s")
    , ((0, xK_Print), spawn "scrot")
    and here's my xmobarrc:
    Config { font = "-Misc-Fixed-Bold-R-Normal--13-120-75-75-C-70-ISO8859-1"
    , bgColor = "black"
    , fgColor = "grey"
    , position = TopW L 90
    , commands = [ Run Cpu ["-L","3","-H","50","--normal","green","--high","red"] 10
    , Run Memory ["-t","Mem: <usedratio>%"] 10
    , Run Swap [] 10
    , Run Date "%a %b %_d %l:%M" "date" 10
    , Run StdinReader
    , sepChar = "%"
    , alignSep = "}{"
    , template = "%StdinReader% }{ %cpu% | %memory% * %swap% <fc=#ee9a00>%date%</fc> |"

  • Xmonad and Xmobar: avoidStruts no longer exposes Xmobar

    I've been using Xmonad with the same config for months now. I reinstalled Arch recently, and ever since then avoidStruts no longer keeps Xmobar from being hidden behind windows.
    I have installed the xmonad and xmonad-contrib packages; my config compiles without errors. I'm at a loss here because I can't identify any changes that may have been made to either of the aforementioned packages that might cause this issue.
    xmonad.hs
    import XMonad
    import Data.Monoid
    import Data.Ratio ((%))
    import System.Exit
    import XMonad.Hooks.EwmhDesktops
    import XMonad.Hooks.DynamicLog
    import XMonad.Hooks.ManageDocks
    import XMonad.Hooks.UrgencyHook
    import XMonad.Layout.NoBorders
    import XMonad.Layout.Named
    import XMonad.Layout.Grid
    import XMonad.Layout.IM
    import XMonad.Util.Run(spawnPipe)
    import System.IO
    import qualified XMonad.StackSet as W
    import qualified Data.Map as M
    -- The preferred terminal program, which is used in a binding below and by
    -- certain contrib modules.
    myTerminal = "urxvt"
    -- Whether focus follows the mouse pointer.
    myFocusFollowsMouse :: Bool
    myFocusFollowsMouse = True
    -- Width of the window border in pixels.
    myBorderWidth = 2
    -- modMask lets you specify which modkey you want to use. The default
    -- is mod1Mask ("left alt"). You may also consider using mod3Mask
    -- ("right alt"), which does not conflict with emacs keybindings. The
    -- "windows key" is usually mod4Mask.
    myModMask = mod4Mask
    -- The default number of workspaces (virtual screens) and their names.
    -- By default we use numeric strings, but any string may be used as a
    -- workspace name. The number of workspaces is determined by the length
    -- of this list.
    -- A tagging example:
    -- > workspaces = ["web", "irc", "code" ] ++ map show [4..9]
    myWorkspaces = ["1","2","3","4","5","6","7","8","9"]
    -- Border colors for unfocused and focused windows, respectively.
    myNormalBorderColor = "#404040"
    -- myFocusedBorderColor = "#0080ff"
    myFocusedBorderColor = "#ff0000"
    -- Key bindings. Add, modify or remove key bindings here.
    myKeys conf@(XConfig {XMonad.modMask = modm}) = M.fromList $
    -- launch a terminal
    [ ((modm .|. shiftMask, xK_Return), spawn $ XMonad.terminal conf)
    -- launch dmenu
    , ((modm, xK_p ), spawn "dmenu_run")
    -- launch gmrun
    , ((modm .|. shiftMask, xK_p ), spawn "gmrun")
    -- close focused window
    , ((modm .|. shiftMask, xK_c ), kill)
    -- close focused window (2)
    , ((modm, xK_z ), kill)
    -- close focused window (3)
    , ((modm, xK_Escape), kill)
    -- Rotate through the available layout algorithms
    , ((modm, xK_space ), sendMessage NextLayout)
    -- Reset the layouts on the current workspace to default
    , ((modm .|. shiftMask, xK_space ), setLayout $ XMonad.layoutHook conf)
    -- Resize viewed windows to the correct size
    , ((modm, xK_n ), refresh)
    -- Move focus to the next window
    , ((modm, xK_Tab ), windows W.focusDown)
    -- Move focus to the next window
    , ((modm, xK_j ), windows W.focusDown)
    -- Move focus to the previous window
    , ((modm, xK_k ), windows W.focusUp )
    -- Move focus to the master window
    , ((modm, xK_m ), windows W.focusMaster )
    -- Swap the focused window and the master window
    , ((modm, xK_Return), windows W.swapMaster)
    -- Swap the focused window with the next window
    , ((modm .|. shiftMask, xK_j ), windows W.swapDown )
    -- Swap the focused window with the previous window
    , ((modm .|. shiftMask, xK_k ), windows W.swapUp )
    -- Shrink the master area
    , ((modm, xK_h ), sendMessage Shrink)
    -- Expand the master area
    , ((modm, xK_l ), sendMessage Expand)
    -- Push window back into tiling
    , ((modm, xK_t ), withFocused $ windows . W.sink)
    -- Increment the number of windows in the master area
    , ((modm , xK_comma ), sendMessage (IncMasterN 1))
    -- Deincrement the number of windows in the master area
    , ((modm , xK_period), sendMessage (IncMasterN (-1)))
    -- Toggle the status bar gap
    -- Use this binding with avoidStruts from Hooks.ManageDocks.
    -- See also the statusBar function from Hooks.DynamicLog.
    -- , ((modm , xK_b ), sendMessage ToggleStruts)
    -- Quit xmonad
    , ((modm .|. shiftMask, xK_q ), io (exitWith ExitSuccess))
    -- Restart xmonad
    , ((modm , xK_q ), spawn "xmonad --recompile; xmonad --restart")
    -- Start Opera
    , ((modm .|. shiftMask, xK_i ), spawn "chromium")
    -- Start Thunar
    , ((modm .|. shiftMask, xK_f ), spawn "pcmanfm")
    -- Start networking gui
    , ((modm .|. shiftMask, xK_o ), spawn "wicd-gtk --no-tray")
    -- Video Settings
    , ((modm .|. shiftMask, xK_v ), spawn "nvidia-settings")
    ++
    -- mod-[1..9], Switch to workspace N
    -- mod-shift-[1..9], Move client to workspace N
    [((m .|. modm, k), windows $ f i)
    | (i, k) <- zip (XMonad.workspaces conf) [xK_1 .. xK_9]
    , (f, m) <- [(W.greedyView, 0), (W.shift, shiftMask)]]
    ++
    -- mod-{w,e,r}, Switch to physical/Xinerama screens 1, 2, or 3
    -- mod-shift-{w,e,r}, Move client to screen 1, 2, or 3
    [((m .|. modm, key), screenWorkspace sc >>= flip whenJust (windows . f))
    | (key, sc) <- zip [xK_w, xK_e, xK_r] [0..]
    , (f, m) <- [(W.view, 0), (W.shift, shiftMask)]]
    -- Mouse bindings: default actions bound to mouse events
    myMouseBindings (XConfig {XMonad.modMask = modm}) = M.fromList $
    -- mod-button1, Set the window to floating mode and move by dragging
    [ ((modm, button1), (\w -> focus w >> mouseMoveWindow w
    >> windows W.shiftMaster))
    -- mod-button2, Raise the window to the top of the stack
    , ((modm, button2), (\w -> focus w >> windows W.shiftMaster))
    -- mod-button3, Set the window to floating mode and resize by dragging
    , ((modm, button3), (\w -> focus w >> mouseResizeWindow w
    >> windows W.shiftMaster))
    -- you may also bind events to the mouse scroll wheel (button4 and button5)
    -- Layouts:
    -- You can specify and transform your layouts by modifying these values.
    -- If you change layout bindings be sure to use 'mod-shift-space' after
    -- restarting (with 'mod-q') to reset your layout state to the new
    -- defaults, as xmonad preserves your old layout settings by default.
    -- The available layouts. Note that each layout is separated by |||,
    -- which denotes layout choice.
    myLayout = tall ||| grid ||| full
    where
    -- default tiling algorithm partitions the screen into two panes
    tiled = Tall nmaster delta ratio
    -- The default number of windows in the master pane
    nmaster = 1
    -- Default proportion of screen occupied by master pane
    ratio = 65/100
    -- Percent of screen to increment by when resizing panes
    delta = 5/100
    tall = named "Tall"
    $ avoidStruts
    $ Tall nmaster delta ratio
    grid = named "Grid"
    $ avoidStruts
    $ withIM (1%7) (Role "buddy_list") (GridRatio (4/3))
    full = named "Full"
    $ noBorders
    $ Full
    -- Window rules:
    -- Execute arbitrary actions and WindowSet manipulations when managing
    -- a new window. You can use this to, for example, always float a
    -- particular program, or have a client always appear on a particular
    -- workspace.
    -- To find the property name associated with a program, use
    -- > xprop | grep WM_CLASS
    -- and click on the client you're interested in.
    -- To match on the WM_NAME, you can use 'title' in the same way that
    -- 'className' and 'resource' are used below.
    myManageHook = composeAll
    [ className =? "MPlayer" --> doFloat
    , className =? "Gimp" --> doFloat
    -- , className =? "Nm-connection-editor" --> doFloat
    -- , className =? "Wicd-client.py" --> doFloat
    , resource =? "desktop_window" --> doIgnore
    , resource =? "kdesktop" --> doIgnore
    -- , className =? "Xfce4-notifyd" --> doIgnore
    -- Event handling
    -- * EwmhDesktops users should change this to ewmhDesktopsEventHook
    -- Defines a custom handler function for X Events. The function should
    -- return (All True) if the default handler is to be run afterwards. To
    -- combine event hooks use mappend or mconcat from Data.Monoid.
    -- myEventHook = mempty
    myEventHook = fullscreenEventHook
    -- Status bars and logging
    -- Perform an arbitrary action on each internal state change or X event.
    -- See the 'XMonad.Hooks.DynamicLog' extension for examples.
    myLogHook h = dynamicLogWithPP $ xmobarPP
    { ppOutput = hPutStrLn h
    , ppTitle = xmobarColor "green" "" . shorten 200
    , ppUrgent = xmobarColor "white" "red" . wrap "" ""
    -- Startup hook
    -- Perform an arbitrary action each time xmonad starts or is restarted
    -- with mod-q. Used by, e.g., XMonad.Layout.PerWorkspace to initialize
    -- per-workspace layout choices.
    -- By default, do nothing.
    myStartupHook = return ()
    -- Run xmonad with the settings you specify.
    main = do
    xmproc <- spawnPipe "/usr/bin/xmobar /home/chris/.xmonad/xmobarrc"
    xmonad $ withUrgencyHook NoUrgencyHook $ defaultConfig
    { terminal = myTerminal
    , focusFollowsMouse = myFocusFollowsMouse
    , borderWidth = myBorderWidth
    , modMask = myModMask
    , workspaces = myWorkspaces
    , normalBorderColor = myNormalBorderColor
    , focusedBorderColor = myFocusedBorderColor
    , keys = myKeys
    , mouseBindings = myMouseBindings
    , layoutHook = myLayout
    , manageHook = myManageHook
    , handleEventHook = myEventHook
    , logHook = myLogHook xmproc
    , startupHook = myStartupHook
    xmobarrc
    Config
    { font = "xft:ProFont:pixelsize=12"
    , bgColor = "#000000"
    -- used to make the bar appear correctly after Mod-q in older xmonad implementations (0.9.x)
    -- doesn't seem to do anything anymore (0.10, darcs)
    -- , lowerOnStart = False
    , commands =
    [ Run Wireless "wlan0" ["-t", "<essid> <quality>%"] 10
    , Run CommandReader "/home/chris/.xmonad/volume-listener.sh" "vol"
    , Run CommandReader "/home/chris/.xmonad/hdaps-listener.sh" "hdaps"
    , Run Battery
    [ "-t", "<acstatus> <left>%"
    , "-f", "AC/online"
    , "-o", "Bat"
    , "-O", "AC"
    20
    , Run Date "%a %b %_d %H:%M" "date" 10
    , Run StdinReader
    , sepChar = "%"
    , alignSep = "}{"
    , template = "%StdinReader% }{ <fc=#ff0000>%hdaps%</fc> %wlan0wi% Vol %vol% %battery% <fc=#ee9a00>%date%</fc> "
    Last edited by cheese, lol (2012-10-26 03:15:39)

    Downgrade to xmobar-0.15. See here.

  • Get VLC to do fullscreen float in Xmonad

    Hi,
    Short background: I have started to use XBMC for watching and organizing videos. Everything works great except playing the videos. I have a constant stutter about every 3-4 seconds and from time to time the picture freeze but the movie running in the background with sound OK, moving the mouse take away the freeze.
    I do not have thous problems with VLC. I have configured XBMC to use VLC to play videos.
    I have two monitors, one for movies. Using a Nvidia-card in TwinView.
    My problem is that when I start a movie VLC starts and XMONAD tiling it as it should. But of cause I do not want VLC and XBMC side by side on the monitor. I would like VLC fullscreen on top of XBMC.
    I have tried to solve it by using  XMonad.Hooks.ManageHelpers but no luck.
    My xmonad.hs looks like this.
    -- xmonad example config file.
    -- A template showing all available configuration hooks,
    -- and how to override the defaults in your own xmonad.hs conf file.
    -- Normally, you'd only override those defaults you care about.
    import XMonad
    import Data.Monoid
    import System.Exit
    import XMonad.Hooks.ManageDocks
    import XMonad.Util.Run(spawnPipe)
    import XMonad.Hooks.DynamicLog
    import System.IO
    import XMonad.Hooks.ManageHelpers
    import qualified XMonad.StackSet as W
    import qualified Data.Map as M
    main = do
    xmproc <- spawnPipe "/usr/bin/xmobar /home/christer/.xmonad/xmobarrc"
    xmonad defaults
    -- { manageHook = manageDocks <+> manageHook defaultConfig
    { manageHook = myManageHook
    , layoutHook = avoidStruts $ layoutHook defaultConfig
    , logHook = dynamicLogWithPP xmobarPP
    { ppOutput = hPutStrLn xmproc
    , ppTitle = xmobarColor "green" "" . shorten 100
    myManageHook = composeOne
    [ className =? "vlc" -?> doFullFloat
    , className =? "skype" -?> doFloat
    , resource =? "desktop_window" -?> doIgnore
    , resource =? "kdesktop" -?> doIgnore ]
    -- The preferred terminal program, which is used in a binding below and by
    -- certain contrib modules.
    -- myTerminal = "xterm"
    myTerminal = "urxvt"
    -- Whether focus follows the mouse pointer.
    myFocusFollowsMouse :: Bool
    myFocusFollowsMouse = True
    -- Width of the window border in pixels.
    myBorderWidth = 3
    -- modMask lets you specify which modkey you want to use. The default
    -- is mod1Mask ("left alt"). You may also consider using mod3Mask
    -- ("right alt"), which does not conflict with emacs keybindings. The
    -- "windows key" is usually mod4Mask.
    myModMask = mod4Mask
    -- The default number of workspaces (virtual screens) and their names.
    -- By default we use numeric strings, but any string may be used as a
    -- workspace name. The number of workspaces is determined by the length
    -- of this list.
    -- A tagging example:
    -- > workspaces = ["web", "irc", "code" ] ++ map show [4..9]
    myWorkspaces = ["1","2","3","4","5","6","7","8","9"]
    -- Border colors for unfocused and focused windows, respectively.
    -- myNormalBorderColor = "#dddddd"
    myNormalBorderColor = "#000000"
    myFocusedBorderColor = "#ff0000"
    -- Key bindings. Add, modify or remove key bindings here.
    myKeys conf@(XConfig {XMonad.modMask = modm}) = M.fromList $
    -- launch a terminal
    [ ((modm .|. shiftMask, xK_Return), spawn $ XMonad.terminal conf)
    -- launch dmenu
    , ((modm, xK_p ), spawn "dmenu_run -b")
    -- launch gmrun
    , ((modm .|. shiftMask, xK_p ), spawn "gmrun")
    -- close focused window
    , ((modm .|. shiftMask, xK_c ), kill)
    -- Rotate through the available layout algorithms
    , ((modm, xK_space ), sendMessage NextLayout)
    -- Reset the layouts on the current workspace to default
    , ((modm .|. shiftMask, xK_space ), setLayout $ XMonad.layoutHook conf)
    -- Resize viewed windows to the correct size
    , ((modm, xK_n ), refresh)
    -- Move focus to the next window
    , ((modm, xK_Tab ), windows W.focusDown)
    -- Move focus to the next window
    , ((modm, xK_j ), windows W.focusDown)
    -- Move focus to the previous window
    , ((modm, xK_k ), windows W.focusUp )
    -- Move focus to the master window
    , ((modm, xK_m ), windows W.focusMaster )
    -- Swap the focused window and the master window
    , ((modm, xK_Return), windows W.swapMaster)
    -- Swap the focused window with the next window
    , ((modm .|. shiftMask, xK_j ), windows W.swapDown )
    -- Swap the focused window with the previous window
    , ((modm .|. shiftMask, xK_k ), windows W.swapUp )
    -- Shrink the master area
    , ((modm, xK_h ), sendMessage Shrink)
    -- Expand the master area
    , ((modm, xK_l ), sendMessage Expand)
    -- Push window back into tiling
    , ((modm, xK_t ), withFocused $ windows . W.sink)
    -- Increment the number of windows in the master area
    , ((modm , xK_comma ), sendMessage (IncMasterN 1))
    -- Deincrement the number of windows in the master area
    , ((modm , xK_period), sendMessage (IncMasterN (-1)))
    -- Toggle the status bar gap
    -- Use this binding with avoidStruts from Hooks.ManageDocks.
    -- See also the statusBar function from Hooks.DynamicLog.
    -- , ((modm , xK_b ), sendMessage ToggleStruts)
    -- Quit xmonad
    , ((modm .|. shiftMask, xK_q ), io (exitWith ExitSuccess))
    -- Restart xmonad
    , ((modm , xK_q ), spawn "xmonad --recompile; xmonad --restart")
    -- mod-[1..9], Switch to workspace N
    -- mod-shift-[1..9], Move client to workspace N
    [((m .|. modm, k), windows $ f i)
    | (i, k) <- zip (XMonad.workspaces conf) [xK_1 .. xK_9]
    , (f, m) <- [(W.greedyView, 0), (W.shift, shiftMask)]]
    ++
    -- mod-{w,e,r}, Switch to physical/Xinerama screens 1, 2, or 3
    -- mod-shift-{w,e,r}, Move client to screen 1, 2, or 3
    [((m .|. modm, key), screenWorkspace sc >>= flip whenJust (windows . f))
    | (key, sc) <- zip [xK_w, xK_e, xK_r] [0..]
    , (f, m) <- [(W.view, 0), (W.shift, shiftMask)]]
    -- Mouse bindings: default actions bound to mouse events
    myMouseBindings (XConfig {XMonad.modMask = modm}) = M.fromList $
    -- mod-button1, Set the window to floating mode and move by dragging
    [ ((modm, button1), (\w -> focus w >> mouseMoveWindow w
    >> windows W.shiftMaster))
    -- mod-button2, Raise the window to the top of the stack
    , ((modm, button2), (\w -> focus w >> windows W.shiftMaster))
    -- mod-button3, Set the window to floating mode and resize by dragging
    , ((modm, button3), (\w -> focus w >> mouseResizeWindow w
    >> windows W.shiftMaster))
    -- you may also bind events to the mouse scroll wheel (button4 and button5)
    -- Layouts:
    -- You can specify and transform your layouts by modifying these values.
    -- If you change layout bindings be sure to use 'mod-shift-space' after
    -- restarting (with 'mod-q') to reset your layout state to the new
    -- defaults, as xmonad preserves your old layout settings by default.
    -- The available layouts. Note that each layout is separated by |||,
    -- which denotes layout choice.
    myLayout = tiled ||| Mirror tiled ||| Full
    where
    -- default tiling algorithm partitions the screen into two panes
    tiled = Tall nmaster delta ratio
    -- The default number of windows in the master pane
    nmaster = 1
    -- Default proportion of screen occupied by master pane
    ratio = 1/4
    -- Percent of screen to increment by when resizing panes
    delta = 3/100
    -- Window rules:
    -- Execute arbitrary actions and WindowSet manipulations when managing
    -- a new window. You can use this to, for example, always float a
    -- particular program, or have a client always appear on a particular
    -- workspace.
    -- To find the property name associated with a program, use
    -- > xprop | grep WM_CLASS
    -- and click on the client you're interested in.
    -- To match on the WM_NAME, you can use 'title' in the same way that
    -- 'className' and 'resource' are used below.
    -- Event handling
    -- * EwmhDesktops users should change this to ewmhDesktopsEventHook
    -- Defines a custom handler function for X Events. The function should
    -- return (All True) if the default handler is to be run afterwards. To
    -- combine event hooks use mappend or mconcat from Data.Monoid.
    myEventHook = mempty
    -- Status bars and logging
    -- Perform an arbitrary action on each internal state change or X event.
    -- See the 'XMonad.Hooks.DynamicLog' extension for examples.
    myLogHook = return ()
    -- Startup hook
    -- Perform an arbitrary action each time xmonad starts or is restarted
    -- with mod-q. Used by, e.g., XMonad.Layout.PerWorkspace to initialize
    -- per-workspace layout choices.
    -- By default, do nothing.
    myStartupHook = return ()
    -- Now run xmonad with all the defaults we set up.
    -- Run xmonad with the settings you specify. No need to modify this.
    -- main = xmonad defaults
    -- A structure containing your configuration settings, overriding
    -- fields in the default config. Any you don't override, will
    -- use the defaults defined in xmonad/XMonad/Config.hs
    -- No need to modify this.
    defaults = defaultConfig {
    -- simple stuff
    terminal = myTerminal,
    focusFollowsMouse = myFocusFollowsMouse,
    borderWidth = myBorderWidth,
    modMask = myModMask,
    workspaces = myWorkspaces,
    normalBorderColor = myNormalBorderColor,
    focusedBorderColor = myFocusedBorderColor,
    -- key bindings
    keys = myKeys,
    mouseBindings = myMouseBindings,
    -- hooks, layouts
    layoutHook = myLayout,
    manageHook = myManageHook,
    handleEventHook = myEventHook,
    logHook = myLogHook,
    startupHook = myStartupHook
    Any idea what I missed?
    Best regards.
    Christer

    Try this, it works very well for me.
    import XMonad.Hooks.ManageHelpers (composeOne, isFullscreen, isDialog, doFullFloat, doCenterFloat)
    myManageHook = composeAll. concat $
    [ [ className =? c --> doCenterFloat| c <- floats]
    , [ resource =? r --> doIgnore | r <- ignore]
    , [ resource =? "gecko" --> doF (W.shift "net") ]
    , [ isFullscreen --> doFullFloat]
    , [ isDialog --> doCenterFloat]]
    where floats = ["sdlpal", "MPlayer", "Gimp", "qemu-system-x86_64", "Gnome-typing-monitor", "Vlc", "Dia", "DDMS", "Audacious", "Wine"]
    ignore = []
    myLayout = tall ||| Mirror tall||| Full ||| tab ||| float
    where
    tall = named "Tall" $ limitWindows 4 $ minimize $ Tall 1 (3/100) (1/2)
    tab = named "Tab" simpleTabbedBottom
    float = named "Float" simpleFloat
    main = do
    myStatusBarPipe <- spawnPipe myBar
    conkyBarProc <- spawnPipe conkyBar
    trayproc <- spawnPipe myTrayer
    xmonad $ ewmh $ withUrgencyHook NoUrgencyHook $ defaultConfig {
    terminal = "urxvt"
    , manageHook = manageDocks <+> myManageHook <+> manageHook defaultConfig
    Last edited by helloworld1 (2012-08-14 05:20:56)

  • A little help for my xmonad configuration???

    i'm totally new with xmonad, and i'm all confused with this problem...
    it says that the last statement in a 'do' block must be an expression or something...
    i'm just following http://thinkingeek.com/2011/11/21/simpl … en2-conky/,
    everything goes right except the "log hook" part...
    i don't really know Haskell code,
    thanks for the help and sorry for my bad English,
    here's the code...
    -- import stuffs {
    import XMonad
    import XMonad.Actions.CycleWS
    import XMonad.Hooks.ManageDocks
    import XMonad.Hooks.ManageHelpers
    import XMonad.Hooks.SetWMName
    import XMonad.Hooks.DynamicLog
    import XMonad.Hooks.UrgencyHook
    import XMonad.Hooks.FadeInactive
    import XMonad.Hooks.EwmhDesktops
    import XMonad.Layout.SimpleFloat
    import XMonad.Layout.NoBorders (smartBorders, noBorders)
    import XMonad.Layout.PerWorkspace (onWorkspace, onWorkspaces)
    import XMonad.Layout.Reflect (reflectHoriz)
    import XMonad.Layout.IM
    import XMonad.Layout.SimpleFloat
    import XMonad.Layout.Spacing
    import XMonad.Layout.ResizableTile
    import XMonad.Layout.LayoutHints
    import XMonad.Layout.LayoutModifier
    import XMonad.Layout.Grid
    import XMonad.Operations
    import XMonad.Prompt
    import XMonad.Prompt.RunOrRaise (runOrRaisePrompt)
    import XMonad.Prompt.AppendFile (appendFilePrompt)
    import XMonad.Util.Run
    import Control.Monad
    import Data.Ratio ((%))
    import System.IO
    import System.Exit
    import qualified XMonad.StackSet as W
    import qualified Data.Map as M
    -- end of import stuffs }
    -- default terminal {
    myTerm = "urxvt"
    -- end of default terminal }
    -- workspaces {
    myWork = ["home", "surf", "devs", "ofce", "play", "misc"]
    -- end of workspaces }
    -- mod key {
    myModm = mod4Mask
    -- end of modkey }
    -- window border {
    myBord = 1
    myNorm = "#272727"
    myFocu = "#5387BF"
    -- end of window border }
    -- keybinding {
    -- key to add
    addKeys x = [
    -- closing window
    ((modMask x, xK_c), kill)
    -- key to remove
    removeKeys x = [
    -- gmrun
    (modMask x .|. shiftMask, xK_p),
    -- closing window
    (modMask x .|. shiftMask, xK_c)
    -- strip the key to remove
    strippedKeys x = foldr M.delete (keys defaultConfig x) (removeKeys x)
    -- merging keys
    myKeys x = M.union (strippedKeys x) (M.fromList (addKeys x))
    -- end of keybinding }
    -- layout hooks {
    defaultLayouts = tiled ||| Mirror tiled ||| simpleFloat ||| Full
    where
    -- tiling algorithm
    tiled = Tall nmaster delta ratio
    -- master window count
    nmaster = 1
    -- master pane portion
    ratio = 2/3
    -- increment/decrement resize
    delta = 3/100
    -- specific workspaces
    miscLayout = noBorders $ Full
    -- merging layout
    myLayo = onWorkspace "misc" miscLayout $ defaultLayouts
    -- end of layout hooks }
    -- log hooks
    myLogh :: Handle -> X ()
    myLogh h = dynamicLogWithPP $ defaultPP {
    ppCurrent = dzenColor "#ebac54" "#1B1D1E" . pad,
    ppVisible = dzenColor "white" "#1B1D1E" . pad,
    ppHidden = dzenColor "white" "#1B1D1E" . pad,
    ppHiddenNoWindows = dzenColor "#7b7b7b" "#1B1D1E" . pad,
    ppUrgent = dzenColor "#ff0000" "#1B1D1E" . pad,
    ppWsSep = " ",
    ppSep = " | ",
    ppLayout = dzenColor "#ebac54" "#1B1D1E" . (
    \x -> case x of
    "ResizableTall" -> "^i(" ++ myBitmapsDir ++ "/tall.xbm)"
    "Mirror ResizableTall" -> "^i(" ++ myBitmapsDir ++ "/mtall.xbm)"
    "Full" -> "^i(" ++ myBitmapsDir ++ "/full.xbm)"
    "Simple Float" -> "~"
    _ -> x
    ppTitle = (" " ++) . dzenColor "white" "#1B1D1E" . dzenEscape,
    ppOutput = hPutStrLn h
    -- end of log hooks
    -- manage hooks {
    myMana = composeAll . concat $ [
    -- apps to surf
    [ className =? t --> shiftWin "surf" | t <- mySurfClass ],
    -- apps to devs
    [ className =? t --> shiftWin "devs" | t <- myDevsClass ],
    -- apps to float
    [ className =? f --> doFloat | f <- myFloatClass ]
    where
    shiftWin = doF . liftM2 (.) W.greedyView W.shift
    mySurfClass = ["Luakit", "luakit", "Chromium"]
    myDevsClass = ["Geany", "Gedit", "Netbeans"]
    myFloatClass = ["Gimp"]
    -- end of manage hooks }
    -- dzen bar
    myDzen = "dzen2 -x '1440' -y '0' -h '24' -w '640' -ta 'l' -fg '#FFFFFF' -bg '#1B1D1E'"
    myBitmapsDir = "/home/perud/.xmonad/dzen2"
    -- end of dzen bar
    -- status bar
    myStat = "conky -c /home/perud/.xmonad/.conky_dzen | dzen2 -x '2080' -w '1040' -h '24' -ta 'r' -bg '#1B1D1E' -fg '#FFFFFF' -y '0'"
    -- end of status bar
    -- MAIN METHOD
    main = do
    dzenLeftBar <- spawnPipe myDzen
    dzenRightBar <- spawnPipe myStat
    xmonad $ defaultConfig {
    terminal = myTerm,
    workspaces = myWork,
    modMask = myModm,
    borderWidth = myBord,
    normalBorderColor = myNorm,
    focusedBorderColor = myFocu,
    keys = myKeys,
    layoutHook = myLayo,
    logHook = myLogh dzenLeft >> fadeInactiveLogHook 0xdddddddd,
    manageHook = myMana
    -- END OF MAIN METHOD
    Last edited by perud (2013-02-14 02:28:03)

    Please use code tags when pasting to the boards:
    https://wiki.archlinux.org/index.php/Fo … s_and_Code

  • Xmonad dual head

    In xmonad dual head setup, xmonad just shows two tag, one for each monitor, how can I switch between tag 1-9 of a perticular sreen. One more thing, my laptop screen looks hazy compared to the other monitor.

    jaideep_jdof wrote:In xmonad dual head setup, xmonad just shows two tag, one for each monitor, how can I switch between tag 1-9 of a perticular sreen. One more thing, my laptop screen looks hazy compared to the other monitor.
    In xmonad, even if you have 2 monitors, there are only 9 workspaces in total. There is no workspace 1-9 for monitor A and a separate workspace 1-9 for monitor B. By default, when you load up xmonad one monitor will be showing workspace 1, and the second monitor will show workspace 2.

  • Session Manager with i3/Awesome/Xmonad?

    Hello, First post here so let me know if I am doing anything wrong,
    I recently started using i3 and I could not recommend it more, I have given xmonad a shot and was a big fan and I know a lot of people seem to like Awesome, my only question is...
    Are there any session managers that would work for any of them?
    I love them but I spend a lot of time getting things just right so I have a nice flow at work (I loooooove i3 once I have everything where I want it). Before switching to xmonad from xfce4 I always had my work from office session, my work from home session, and one or two others. Anyone know of any way to save sessions in one of the mentioned window managers? Or are there any other window managers I should look into for this feature?
    Thanks!!

    I think this session thing is about stopping the applications in a way that you can start them again.
    1. Different users/computers - It's very static and doesn't really scale.
    2. Any X11 Session Manager - You have to log out of X11 and you can only have one session open.
    3. My super script - For sessions on a tag/workspace level. Sorry for the bad english and bash. I'm about to rewrite it, it will support i3 and openbox. But maybe I should wait for wayland.
    I have read that systemd article more than once, but I didn't understand if it's limited to 2 or not?

  • Xmonad Status Bar Not Appearing

    Hey guys I've been reading through posts and trying to get dzen2 to appear. But it simply doesn't show up.
    So I tried using a default status bar
    main = xmonad $ defaultConfig {
    logHook = dynamicLog
    Provided from
    http://xmonad.org/xmonad-docs/xmonad-co … icLog.html
    and I still do not have any status bars appearing.
    Refer Below, changed my current xmonad configuration.
    My xmonad.hs is based of thayer's configuration.
    Last edited by Jabrick (2011-10-30 22:01:26)

    Ok I've finally got a dzen bar to appear.
    In my xinitrc where i normally start xmonad
    I now have the line
    exec xmonad | dzen2
    But nothing appears in the bar I've tried several examples and it doesn't seem to work.
    Is there something I'm missing?
    I do have a ~/.conkyrc file
    That looks like
    # Conky Config File
    # just log everything to the desktop
    # Main options (alphabetically)
    alignment bl
    background yes
    default_color 606060
    draw_outline no
    draw_shades no
    double_buffer yes
    gap_x 10
    gap_y 10
    minimum_size 100 100
    own_window yes
    own_window_type override
    own_window_transparent yes
    total_run_times 0
    update_interval 1
    use_xft yes
    xftalpha 0.7
    xftfont Verdana:size=8
    # After TEXT is formatted on screen
    TEXT
    ${tail /var/log/everything.log 20}
    This is my  xmonad config file right now....
    If I could just get this to work I can finally tinker around.
    Been frustrating! Urgh!
    --Imports--
    import XMonad
    --Actions--
    import XMonad.Actions.CycleWindows -- classic alt-tab
    import XMonad.Actions.CycleWS -- cycle thru WS', toggle last WS
    import XMonad.Actions.DwmPromote -- swap master like dwm
    --Hooks--
    import XMonad.Hooks.DynamicLog -- statusbar
    import XMonad.Hooks.EwmhDesktops -- fullscreenEventHook fixes chrome fullscreen
    import XMonad.Hooks.ManageDocks -- dock/tray mgmt
    import XMonad.Hooks.UrgencyHook -- window alert bells
    import XMonad.Hooks.SetWMName -- matlab fix
    --Layouts--
    import XMonad.Layout.Named -- custom layout names
    import XMonad.Layout.NoBorders -- smart borders on solo clients
    --Utils--
    import XMonad.Util.EZConfig -- append key/mouse bindings
    import XMonad.Util.Run(spawnPipe) -- spawnPipe and hPutStrLn
    import System.IO -- hPutStrLn scope
    import qualified XMonad.StackSet as W -- manageHook rules
    main = do
    status <- spawnPipe myDzenStatus -- xmonad status on the left
    conky <- spawnPipe myDzenConky -- conky stats on the right
    xmonad $ withUrgencyHook NoUrgencyHook $ defaultConfig
    { modMask = mod4Mask
    , borderWidth = 2
    , normalBorderColor = "#dddddd"
    , focusedBorderColor = "#0000ff"
    -- , handleEventHook = fullscreenEventHook
    , workspaces = myWorkspaces
    , layoutHook = myLayoutHook
    , manageHook = manageDocks <+> myManageHook
    <+> manageHook defaultConfig
    ,logHook = myLogHook status
    , startupHook= setWMName "LG3D"
    `additionalKeysP` myKeys
    -- Tags/Workspaces
    -- clickable workspaces via dzen/xdotool
    myWorkspaces :: [String]
    myWorkspaces = clickable . (map dzenEscape) $ ["1","2","3","4","5"]
    where clickable l = [ "^ca(1,xdotool key super+" ++ show (n) ++ ")" ++ ws ++ "^ca()" |
    (i,ws) <- zip [1..] l,
    let n = i ]
    -- Layouts
    -- the default layout is fullscreen with smartborders applied to all
    myLayoutHook = avoidStruts $ smartBorders ( full ||| mtiled ||| tiled )
    where
    full = named "X" $ Full
    mtiled = named "M" $ Mirror tiled
    tiled = named "T" $ Tall 1 (5/100) (2/(1+(toRational(sqrt(5)::Double))))
    -- sets default tile as: Tall nmaster (delta) (golden ratio)
    -- Window management
    myManageHook = composeAll
    [ className =? "MPlayer" --> doFloat
    , className =? "Vlc" --> doFloat
    , className =? "Gimp" --> doFloat
    , className =? "XCalc" --> doFloat
    , className =? "Chromium" --> doF (W.shift (myWorkspaces !! 1)) -- send to ws 2
    , className =? "Nautilus" --> doF (W.shift (myWorkspaces !! 2)) -- send to ws 3
    , className =? "Gimp" --> doF (W.shift (myWorkspaces !! 3)) -- send to ws 4
    , className =? "stalonetray" --> doIgnore
    -- Statusbar
    myLogHook h = dynamicLogWithPP $ myDzenPP { ppOutput = hPutStrLn h }
    myDzenStatus = "dzen2 -w '320' -ta 'l'" ++ myDzenStyle
    myDzenConky = "conky -c ~/.conkyrc | dzen2 -x '320' -w '704' -ta 'r'" ++ myDzenStyle
    myDzenStyle = " -h '20' -fg '#777777' -bg '#222222' -fn 'arial:bold:size=11'"
    myDzenPP = dzenPP
    { ppCurrent = dzenColor "#3399ff" "" . wrap " " " "
    , ppHidden = dzenColor "#dddddd" "" . wrap " " " "
    , ppHiddenNoWindows = dzenColor "#777777" "" . wrap " " " "
    , ppUrgent = dzenColor "#ff0000" "" . wrap " " " "
    , ppSep = " "
    , ppLayout = dzenColor "#aaaaaa" "" . wrap "^ca(1,xdotool key super+space)· " " ·^ca()"
    , ppTitle = dzenColor "#ffffff" ""
    . wrap "^ca(1,xdotool key super+k)^ca(2,xdotool key super+shift+c)"
    " ^ca()^ca()" . shorten 20 . dzenEscape
    -- Key bindings
    myKeys = [ ("M1-<Tab>" , cycleRecentWindows [xK_Alt_L] xK_Tab xK_Tab ) -- classic alt-tab behaviour
    , ("M-b" , sendMessage ToggleStruts ) -- toggle the status bar gap
    , ("M-<Tab>" , toggleWS ) -- toggle last workspace (super-tab)
    , ("M-<Right>" , nextWS ) -- go to next workspace
    , ("M-<Left>" , prevWS ) -- go to prev workspace
    , ("M-S-<Right>", shiftToNext ) -- move client to next workspace
    , ("M-S-<Left>" , shiftToPrev ) -- move client to prev workspace
    , ("M-r" , spawn "xmonad --restart" ) -- restart xmonad w/o recompiling
    , ("M-x" , spawn "chromium" ) -- launch browser
    , ("M-S-x" , spawn "chromium --incognito" ) -- launch private browser
    , ("C-M1-<Delete>" , spawn "sudo shutdown -r now" ) -- reboot
    , ("C-M1-<End>" , spawn "sudo shutdown -h now" ) -- poweroff
    , ("<XF86AudioMute>" , spawn "amixer -q sset Master toggle") --Toggle Volume
    , ("<XF86AudioLowerVolume>", spawn "amixer -q sset Master 2- unmute") -- lower volume
    , ("<XF86AudioRaiseVolume>", spawn "amixer -q sset Master 2+ unmute") -- raise volume
    , ("<Print>" , spawn "import -window root `date '+%Y%m%d-%H%M%S'`.png") --Take a Screenshot

  • [solved] xmonad issue

    I'm trying to get it so that when I open a new program, it is set as the slave and not the master. I did this by putting "insertPosition Below Newer" into my manageHook, and it works well except this causes dialog boxes to be opened up behind the active window and I have to move the window in order to find them. A good example of this is in GIMP; when I go to open a file, the open file dialog box can't be seen because the main GIMP windowis blocking it. If I remove the insertPosition line, it goes back to normal. Is there anyway for me to make only new instances of urxvt to be inserted Below Newer? I tried className =? "urxvt" --> insertPosition Below Newer, but that didn't work.
    Edit: here's my entire xmonad.hs
    import XMonad
    import XMonad.Actions.GridSelect
    import XMonad.Hooks.DynamicLog -- statusbar
    import XMonad.Hooks.EwmhDesktops -- fullscreenEventHook fixes chrome fullscreen
    import XMonad.Hooks.ManageDocks -- dock/tray mgmt
    import XMonad.Hooks.ManageHelpers
    import XMonad.Hooks.UrgencyHook -- window alert bells
    import XMonad.Hooks.InsertPosition
    import XMonad.Layout.NoBorders
    import XMonad.Layout.ResizableTile
    import XMonad.Layout.Named
    import XMonad.Layout.Tabbed
    import XMonad.Layout.Spiral
    import XMonad.Util.Run(spawnPipe) -- spawnPipe and hPutStrLn
    import XMonad.Util.Cursor
    import System.IO -- hPutStrLn scope
    import System.Exit
    import qualified XMonad.StackSet as W -- manageHook rules
    import qualified Data.Map as M
    main = do
    status <- spawnPipe myDzenStatus -- xmonad status on the left
    conky <- spawnPipe myDzenConky -- conky stats on the right
    xmonad $ withUrgencyHook NoUrgencyHook $ defaultConfig
    { modMask = mod4Mask
    , terminal = "urxvtc"
    , borderWidth = 1
    , normalBorderColor = "#333333"
    , focusedBorderColor = "#AFAF97"
    , handleEventHook = fullscreenEventHook
    , workspaces = myWorkspaces
    , layoutHook = myLayoutHook
    , manageHook = manageDocks <+> myManageHook
    <+> manageHook defaultConfig
    , logHook = myLogHook status
    , keys = myKeys
    , startupHook = setDefaultCursor xC_left_ptr
    -- Tags/Workspaces
    -- clickable workspaces via dzen/xdotool
    myWorkspaces :: [String]
    myWorkspaces = clickable . (map dzenEscape) $ ["1-main","2-web","3-dev","4-games","5","6","7","8","9"]
    where clickable l = [ "^ca(1,xdotool key super+" ++ show (n) ++ ")" ++ ws ++ "^ca()" |
    (i,ws) <- zip [1..] l,
    let n = i ]
    -- Layouts
    -- the default layout is fullscreen with smartborders applied to all
    myLayoutHook = avoidStruts $ tile ||| mtile ||| fib ||| tab ||| full
    where
    rt = ResizableTall 1 (2/100) (1/2) []
    tile = named "[]=" $ smartBorders rt
    mtile = named "M[]=" $ smartBorders $ Mirror rt
    fib = named "[F]" $ smartBorders $ spiral (6/7)
    tab = named "T" $ noBorders $ tabbed shrinkText tabTheme1
    full = named "[]" $ noBorders Full
    -- Window management
    myManageHook = composeAll
    [ isFullscreen --> doFullFloat
    , isDialog --> doCenterFloat
    , className =? "MPlayer" --> doCenterFloat
    , className =? "Vlc" --> doCenterFloat
    , className =? "Gimp" --> doFloat
    --, insertPosition Below Newer
    , transience'
    -- tabs
    tabTheme1 = defaultTheme { decoHeight = 16
    , activeColor = "#a6c292"
    , activeBorderColor = "#a6c292"
    , activeTextColor = "#000000"
    , inactiveBorderColor = "#000000"
    -- Statusbar
    myLogHook h = dynamicLogWithPP $ myDzenPP { ppOutput = hPutStrLn h }
    cleanDzen = "killall dzen2"
    myDzenStatus = "dzen2 -w '500' -ta 'l'" ++ myDzenStyle
    myDzenConky = "conky -c ~/.xmonad/conkyrc | dzen2 -x '500' -w '866' -ta 'r'" ++ myDzenStyle
    myDzenStyle = " -h '20' -fg '#777777' -bg '#222222' -fn 'terminus:size=9'"
    myDzenPP = dzenPP
    { ppCurrent = dzenColor "#65ac35" "" . wrap "<" ">"
    , ppHidden = dzenColor "#f85708" "" . wrap " " " "
    , ppHiddenNoWindows = dzenColor "#a8a8a8" "" . wrap " " " "
    , ppUrgent = dzenColor "#18618f" "" . wrap "[" "]"
    , ppSep = dzenColor "#18618f" "" " | "
    , ppLayout = dzenColor "#65ac35" "" . wrap "^ca(1,xdotool key super+space)· " " ·^ca()"
    , ppTitle = dzenColor "#f85708" ""
    . wrap "^ca(1,xdotool key super+k)^ca(2,xdotool key super+shift+c)"
    " ^ca()^ca()" . shorten 20 . dzenEscape
    myGSConfig = defaultGSConfig { gs_cellwidth = 160 }
    -- Key bindings
    myModMask = mod4Mask
    secModMask = mod1Mask
    toggleStrutsKey :: XConfig Layout -> (KeyMask, KeySym)
    toggleStrutsKey XConfig {XMonad.modMask = modMask} = (modMask, xK_b)
    myKeys :: XConfig Layout -> M.Map (KeyMask, KeySym) (X ())
    myKeys conf@(XConfig {XMonad.modMask = modMask}) = M.fromList $
    -- launching and killing programs
    [ ((modMask, xK_Return), spawn $ XMonad.terminal conf)
    , ((modMask, xK_r ), spawn "dmenu_run")
    , ((modMask, xK_d ), spawn "dwb")
    , ((modMask .|. shiftMask, xK_m ), spawn "claws-mail")
    , ((modMask .|. shiftMask, xK_c ), kill)
    , ((0, xK_Print), spawn "scrot '%Y-%m-%d-$wx$h.png' -e 'mv $f ~/pictures/screens/'")
    , ((modMask .|. secModMask, xK_space ), spawn "/home/bslackr/bin/toggletouchpad")
    -- grid
    , ((modMask, xK_g ), goToSelected myGSConfig)
    -- layouts
    , ((modMask, xK_space ), sendMessage NextLayout)
    , ((modMask .|. shiftMask, xK_space ), setLayout $ XMonad.layoutHook conf)
    -- floating layer stuff
    , ((modMask, xK_t ), withFocused $ windows . W.sink)
    -- refresh
    , ((modMask, xK_n ), refresh)
    -- focus
    , ((modMask, xK_Tab ), windows W.focusDown)
    , ((modMask, xK_j ), windows W.focusDown)
    , ((modMask, xK_k ), windows W.focusUp)
    , ((modMask, xK_m ), windows W.focusMaster)
    -- swapping
    , ((modMask .|. shiftMask, xK_Return), windows W.swapMaster)
    , ((modMask .|. shiftMask, xK_j ), windows W.swapDown )
    , ((modMask .|. shiftMask, xK_k ), windows W.swapUp )
    -- increase or decrease number of windows in the master area
    , ((modMask , xK_comma ), sendMessage (IncMasterN 1))
    , ((modMask , xK_period), sendMessage (IncMasterN (-1)))
    -- resizing
    , ((modMask, xK_h ), sendMessage Shrink)
    , ((modMask, xK_l ), sendMessage Expand)
    , ((modMask .|. shiftMask, xK_h ), sendMessage MirrorShrink)
    , ((modMask .|. shiftMask, xK_l ), sendMessage MirrorExpand)
    -- brightness
    , ((0, 0x1008FF02), spawn "/home/bslackr/bin/bsetbacklight inc")
    , ((0, 0x1008FF03), spawn "/home/bslackr/bin/bsetbacklight dec")
    -- volume
    , ((0, 0x1008FF11), spawn "amixer set Master 10%-")
    , ((0, 0x1008FF12), spawn "amixer set Master toggle")
    , ((0, 0x1008FF13), spawn "amixer set Master 10%+")
    -- quit, or restart
    , ((modMask .|. shiftMask, xK_q ), io (exitWith ExitSuccess))
    , ((modMask , xK_q ), spawn "xmonad --recompile; killall dzen2; xmonad --restart")
    ++
    -- mod-[1..9] %! Switch to workspace N
    -- mod-shift-[1..9] %! Move client to workspace N
    [((m .|. modMask, k), windows import XMonad
    import XMonad.Actions.GridSelect
    import XMonad.Hooks.DynamicLog -- statusbar
    import XMonad.Hooks.EwmhDesktops -- fullscreenEventHook fixes chrome fullscreen
    import XMonad.Hooks.ManageDocks -- dock/tray mgmt
    import XMonad.Hooks.ManageHelpers
    import XMonad.Hooks.UrgencyHook -- window alert bells
    import XMonad.Hooks.InsertPosition
    import XMonad.Layout.NoBorders
    import XMonad.Layout.ResizableTile
    import XMonad.Layout.Named
    import XMonad.Layout.Tabbed
    import XMonad.Layout.Spiral
    import XMonad.Util.Run(spawnPipe) -- spawnPipe and hPutStrLn
    import XMonad.Util.Cursor
    import System.IO -- hPutStrLn scope
    import System.Exit
    import qualified XMonad.StackSet as W -- manageHook rules
    import qualified Data.Map as M
    main = do
    status <- spawnPipe myDzenStatus -- xmonad status on the left
    conky <- spawnPipe myDzenConky -- conky stats on the right
    xmonad $ withUrgencyHook NoUrgencyHook $ defaultConfig
    { modMask = mod4Mask
    , terminal = "urxvtc"
    , borderWidth = 1
    , normalBorderColor = "#333333"
    , focusedBorderColor = "#AFAF97"
    , handleEventHook = fullscreenEventHook -- Only in darcs xmonad-contrib
    , workspaces = myWorkspaces
    , layoutHook = myLayoutHook
    , manageHook = manageDocks <+> myManageHook
    <+> manageHook defaultConfig
    , logHook = myLogHook status
    , keys = myKeys
    , startupHook = setDefaultCursor xC_left_ptr
    -- Tags/Workspaces
    -- clickable workspaces via dzen/xdotool
    myWorkspaces :: [String]
    myWorkspaces = clickable . (map dzenEscape) $ ["1-main","2-web","3-dev","4-games","5","6","7","8","9"]
    where clickable l = [ "^ca(1,xdotool key super+" ++ show (n) ++ ")" ++ ws ++ "^ca()" |
    (i,ws) <- zip [1..] l,
    let n = i ]
    -- Layouts
    -- the default layout is fullscreen with smartborders applied to all
    myLayoutHook = avoidStruts $ tile ||| mtile ||| fib ||| tab ||| full
    where
    rt = ResizableTall 1 (2/100) (1/2) []
    tile = named "[]=" $ smartBorders rt
    mtile = named "M[]=" $ smartBorders $ Mirror rt
    fib = named "[F]" $ smartBorders $ spiral (6/7)
    tab = named "T" $ noBorders $ tabbed shrinkText tabTheme1
    full = named "[]" $ noBorders Full
    -- Window management
    myManageHook = composeAll
    [ isFullscreen --> doFullFloat
    , isDialog --> doCenterFloat
    , className =? "MPlayer" --> doCenterFloat
    , className =? "Vlc" --> doCenterFloat
    , className =? "Gimp" --> doFloat
    --, insertPosition Below Newer
    , transience'
    -- tabs
    tabTheme1 = defaultTheme { decoHeight = 16
    , activeColor = "#a6c292"
    , activeBorderColor = "#a6c292"
    , activeTextColor = "#000000"
    , inactiveBorderColor = "#000000"
    -- Statusbar
    myLogHook h = dynamicLogWithPP $ myDzenPP { ppOutput = hPutStrLn h }
    cleanDzen = "killall dzen2"
    myDzenStatus = "dzen2 -w '500' -ta 'l'" ++ myDzenStyle
    myDzenConky = "conky -c ~/.xmonad/conkyrc | dzen2 -x '500' -w '866' -ta 'r'" ++ myDzenStyle
    myDzenStyle = " -h '20' -fg '#777777' -bg '#222222' -fn 'terminus:size=9'"
    myDzenPP = dzenPP
    { ppCurrent = dzenColor "#65ac35" "" . wrap "<" ">"
    , ppHidden = dzenColor "#f85708" "" . wrap " " " "
    , ppHiddenNoWindows = dzenColor "#a8a8a8" "" . wrap " " " "
    , ppUrgent = dzenColor "#18618f" "" . wrap "[" "]"
    , ppSep = dzenColor "#18618f" "" " | "
    , ppLayout = dzenColor "#65ac35" "" . wrap "^ca(1,xdotool key super+space)· " " ·^ca()"
    , ppTitle = dzenColor "#f85708" ""
    . wrap "^ca(1,xdotool key super+k)^ca(2,xdotool key super+shift+c)"
    " ^ca()^ca()" . shorten 20 . dzenEscape
    myGSConfig = defaultGSConfig { gs_cellwidth = 160 }
    -- Key bindings
    myModMask = mod4Mask
    secModMask = mod1Mask
    toggleStrutsKey :: XConfig Layout -> (KeyMask, KeySym)
    toggleStrutsKey XConfig {XMonad.modMask = modMask} = (modMask, xK_b)
    myKeys :: XConfig Layout -> M.Map (KeyMask, KeySym) (X ())
    myKeys conf@(XConfig {XMonad.modMask = modMask}) = M.fromList $
    -- launching and killing programs
    [ ((modMask, xK_Return), spawn $ XMonad.terminal conf)
    , ((modMask, xK_r ), spawn "dmenu_run")
    , ((modMask, xK_d ), spawn "dwb")
    , ((modMask .|. shiftMask, xK_m ), spawn "claws-mail")
    , ((modMask .|. shiftMask, xK_c ), kill)
    , ((0, xK_Print), spawn "scrot '%Y-%m-%d-$wx$h.png' -e 'mv $f ~/pictures/screens/'")
    , ((modMask .|. secModMask, xK_space ), spawn "/home/bslackr/bin/toggletouchpad")
    -- grid
    , ((modMask, xK_g ), goToSelected myGSConfig)
    -- layouts
    , ((modMask, xK_space ), sendMessage NextLayout)
    , ((modMask .|. shiftMask, xK_space ), setLayout $ XMonad.layoutHook conf)
    -- floating layer stuff
    , ((modMask, xK_t ), withFocused $ windows . W.sink)
    -- refresh
    , ((modMask, xK_n ), refresh)
    -- focus
    , ((modMask, xK_Tab ), windows W.focusDown)
    , ((modMask, xK_j ), windows W.focusDown)
    , ((modMask, xK_k ), windows W.focusUp)
    , ((modMask, xK_m ), windows W.focusMaster)
    -- swapping
    , ((modMask .|. shiftMask, xK_Return), windows W.swapMaster)
    , ((modMask .|. shiftMask, xK_j ), windows W.swapDown )
    , ((modMask .|. shiftMask, xK_k ), windows W.swapUp )
    -- increase or decrease number of windows in the master area
    , ((modMask , xK_comma ), sendMessage (IncMasterN 1))
    , ((modMask , xK_period), sendMessage (IncMasterN (-1)))
    -- resizing
    , ((modMask, xK_h ), sendMessage Shrink)
    , ((modMask, xK_l ), sendMessage Expand)
    , ((modMask .|. shiftMask, xK_h ), sendMessage MirrorShrink)
    , ((modMask .|. shiftMask, xK_l ), sendMessage MirrorExpand)
    -- brightness
    , ((0, 0x1008FF02), spawn "/home/bslackr/bin/bsetbacklight inc")
    , ((0, 0x1008FF03), spawn "/home/bslackr/bin/bsetbacklight dec")
    -- volume
    , ((0, 0x1008FF11), spawn "amixer set Master 10%-")
    , ((0, 0x1008FF12), spawn "amixer set Master toggle")
    , ((0, 0x1008FF13), spawn "amixer set Master 10%+")
    -- quit, or restart
    , ((modMask .|. shiftMask, xK_q ), io (exitWith ExitSuccess))
    , ((modMask , xK_q ), spawn "xmonad --recompile; killall dzen2; xmonad --restart")
    ++
    -- mod-[1..9] %! Switch to workspace N
    -- mod-shift-[1..9] %! Move client to workspace N
    [((m .|. modMask, k), windows $ f i)
    | (i, k) <- zip (XMonad.workspaces conf) [xK_1 .. xK_9]
    , (f, m) <- [(W.greedyView, 0), (W.shift, shiftMask)]]
    ++
    -- mod-[w,e] %! switch to twinview screen 1/2
    -- mod-shift-[w,e] %! move window to screen 1/2
    [((m .|. modMask, key), screenWorkspace sc >>= flip whenJust (windows . f))
    | (key, sc) <- zip [xK_w, xK_e] [0..]
    , (f, m) <- [(W.view, 0), (W.shift, shiftMask)]]
    -- vim:sw=4 sts=4 ts=4 tw=0 et ai
    $ f i)
    | (i, k) <- zip (XMonad.workspaces conf) [xK_1 .. xK_9]
    , (f, m) <- [(W.greedyView, 0), (W.shift, shiftMask)]]
    ++
    -- mod-[w,e] %! switch to twinview screen 1/2
    -- mod-shift-[w,e] %! move window to screen 1/2
    [((m .|. modMask, key), screenWorkspace sc >>= flip whenJust (windows . f))
    | (key, sc) <- zip [xK_w, xK_e] [0..]
    , (f, m) <- [(W.view, 0), (W.shift, shiftMask)]]
    -- vim:sw=4 sts=4 ts=4 tw=0 et ai
    Last edited by bslackr (2012-03-20 21:37:04)

    I use avoidMaster from the xmonad FAQ to do this. Mine is a little modified though.
    http://www.haskell.org/haskellwiki/Xmon … s_normally
    Here's the relevent parts from my xmonad.hs as well:
    myManageHook = composeOne . concat $
    [ [ title =? c -?> doF (avoidMaster) | c <- myAMTitle ]
    where
    myAMTitle = ["xterm", "urxvt", "mrxvt", "gnome-terminal", "Gnome-terminal"]
    -- here's the part from the xmonad faq
    avoidMaster :: W.StackSet i l a s sd -> W.StackSet i l a s sd
    avoidMaster = W.modify' $ \c -> case c of
    W.Stack t [] (r:rs) -> W.Stack t [r] rs
    otherwise -> c
    Hope that helps
    Last edited by vernonrj (2012-03-20 04:19:49)

  • Xmonad questions

    so i got so tired of awesome constantly breaking my config that i switched to xmonad. ive got pretty much everything working the way i like it. just a few things though..
    1.)  does anyone have a battery script for xmobar? ive searched and cant find anything
    2.)  i want to be able to click my wifi applet in xmobar and it launch urxvt -e wicd-curses. possible?
    3.)  in awesome, i had a function to send an application to workspace X or to take it to workspace X with me. is there anyway i can do that with xmonad? heres the lua code for a frame of reference:
    -- Take client to tag i
    awful.key({ modkey, "Control" }, i,
    function ()
    if client.focus then
    if tags[client.focus.screen][i] then
    awful.client.movetotag(tags[client.focus.screen][i])
    local screen = mouse.screen
    if tags[screen][i] then
    awful.tag.viewonly(tags[screen][i])
    end
    end
    end
    end),
    -- Send client to tag i
    awful.key({ modkey, "Shift" }, i,
    function ()
    if client.focus and tags[client.focus.screen][i] then
    awful.client.movetotag(tags[client.focus.screen][i])
    end
    end),
    thanks.

    vogt wrote:1) one of the default plugins for xmobar is battery...
    PEBCAK
    vogt wrote:2) xmobar doesn't provide any ability to respond to clicks afaik. Perhaps it wouldn't be so difficult to add such a feature?
    do you know if it supports a popup feature like awesome's naughty?
    vogt wrote:
    3) The default keybindings M-S-n where n is 1...9 seem to do the first part.
    For the second part, you can accomplish this with the following codes, I've also included some stuff for including it with the rest of your config... which probably needs to be adapted:
    -- imports you might have to add
    import qualified XMonad.StackSet as W
    import Data.Monoid
    import qualified Data.Map as M
    viewShift :: WorkspaceId -> X ()
    viewShift ws = windows $ W.greedyView ws . W.shift ws
    And then to set up the keybindings for all 1..9 keys the following list comprehension (here you hold you mod4 and controlMask):
    shiftFollowKeys :: XConfig Layout -> M.Map (KeyMask,KeySym) (X ())
    shiftFollowKeys conf = M.fromList [ ((modMask conf .|. controlMask, k), viewShift $ show n)
    | (k,n) <- zip [xK_0 .. xK_9] [1..9] ]
    Then you've specified additional keybindings somewhere and you can just append the shiftFollowKeys using the ++ operator, otherwise you can do something like:
    main :: IO ()
    main = xmonad $ defaultConfig { keys = mconcat [shiftFollowKeys,myKeys,keys defaultConfig] }
    Depending if you've defined myKeys and what type it has (that is, if it is a M.Map or a list), you can leave that one out, or you may have to apply a M.fromList somewhere, so do ask if you're having trouble with that part.
    thanks a lot. ill try and give it a shot.

  • Updated xmonad, funky stuff happening

    I updated xmonad tonight, and that didn't seem to be such a good idea. I'm using the darcs version. Since the update, things seem to be a little funky
    when new windows are created (launching thunar from urxvt, renaming a file inside of thunar, etc) they dont seem to be focused to the front anymore, and appear behind the older window. I'm wondering if there is a way to get an older version back? (pacman cache not available)

    In the current repo you can run:
    darcs put --tag 0.6 /path/to/the/new/0.6/repo
    And then build your happy version from there.
    But I think that you'd be better off looking into the issue in the current. It could be that you have accidentally floated a window, or maybe I'm just misunderstanding you.

  • Creative Mediasource ID3 Tags - Edit more than one year at a ti

    I use a 60gb Zen Xtra with Mediasource. I take pride in the ID3 tags of all my files especially those of my Jazz collection and my player is well organised. The only thing I have to ask is - is there any way of editing the year of, say, an entire album that was recorded in 959 for example all at the same time. It lets me do this for Artist, Album and Genre but not year. Is there any upgrade in software I can get or am I just missing something here?
    Thanks in advance for your input,Matt

    Shucks, I tried and you can't seem to do it. A curious oversight.
    You can either use another copying program like which will let you do it, or simply get a mass tagger (but you will need to edit the tracks on the PC first, then copy). For some mass tagger recommendations look here in the Zen FAQ at Nomadness.net.

  • How can I get all music "tags" to transfer when transferring an iTunes library?

    OK, here's my situation:  I have accumulated about 250GB of music on iTunes on a laptop running Windows 7.  The hard drive was running out of room, and I wanted to upgrade computers.  So I bought a Mac Book with 1TB of hard drive space.
    To transfer my library (which includes about equal parts iTunes purchases and imported CDs), I copied the entire iTunes folder onto an external hard drive, and then used the "add folder" function on iTunes to add the entire library to my new computer.  I knew I would lose all data such as last played, most played, etc.  And I knew from past experience that merely transferring the iTunes folder, including the iTunes library file, to the new computer hard drive (without using the "add folder to library" function) would not mean that the new computer would automatically behave as if the exact same library from the old computer was on the new computer.  I hope I am explaining this right.
    My problem/question is: many of the music files came over without some of the tags that were on the files in the old computer.  This happened with respect to some, but not all, of the imported CD files.  (I had used the MP3 format when I ripped these.)  The song titles are still there, but many of the tracks say "unknown album" for that artist or, worse, just say "unknown album" AND "unknown artist."  Because I have accumulated so much music over the years, it would take me quite a while to re-tag all he music files with all the missing info.   Again, I'm lucky to have the files, and my iPods containing the music have not yet been synced to the new computer, so I could just manually check what I had on the old iPods and re-add/re-tag the files that were problems.  I  know having such a large folder could itself be the problem.  But adding folders to the computer one at a time does not seem to help, as the "unknown" issue keeps happening even then.
    So my conclusions are that one of the following has happened:  either there is another way to import a large library that I should try (Apple migration assistant, maybe?), or I somehow made the transfer from the old computer onto the external hard drive in the wrong way and I'm stuck with things as they are (which would not be terrible, just inconvenient) or there is some limitation in the software of music services that results in many "unknowns" showing up.  These were not obscure records, and iTunes/Gracenote recognized 99% of them just fine when I imported them, but I remember from using Windows Media Player that it was pretty hit-or-miss at times in terms of the right tags being assigned to songs.
    Yes, I probably have spent way too much time over the years on my music.  But if there is something I can learn from this, I'd be happy to hear about it, either to fix things easily now or the next time I transfer music.  (Again, all the files had all the correct tags on my old computer, before I copied them.)  I thank anyone who replies very much, in advance!

    Just to update: the solution above works.  I had tried to "import" all my files into the new computer rather than just copying and pasting the old iTunes folder into the new computer.  This second, easier, solution is much, much better than re-importing all the songs.  Seems like those little files included in an existing iTunes folder are very, very important!  Without them, I would have had hundreds and hundreds of "unknown" files to re-tag.  As it was, when I copied and pasted the existing iTunes folder into the new computer and opened iTunes, all the files were there, complete with all the date added/date played/number of plays/etc. information from my old computer.  (For some reason, this didn't work when I transferred from PC to PC, but that was several years ago and not a transfer to a Mac.)  I did seem to lose album artwork for a number of albums I had imported rather than purchased, and there was other cleanup to do on a small percentage of files.  But that was a vry small amount of work compared to re-tagging from scratch.  Thanks again for your help.

  • How to set text resources avoiding automatic page update with c:set tag

    Hello everyone,
    I'm developing my web application with JDeveloper 11.1.2.3.0 in order to support two language locales (en and de). Following this guide I've performed the following steps:
    Creation of two property files (Resources.properties and Resources_de.properties) with the key-value entries;
    Modify of faces-config.xml file adding these lines:
    <locale-config>
            <default-locale>en</default-locale>
            <supported-locale>de</supported-locale>
      </locale-config>
      <resource-bundle>
          <base-name>view.Resources</base-name>
          <var>res</var>
       </resource-bundle>
    In the project properties > Resources Bundle I've checked:
    Automatically Synchronize Bundle;
    Warn about Hard-coed Translatable Strings;
    Always Prompt for Description.
    In the same place I've set the default project bundle name to view.Resources.
    In a test JSP page I've a outputText with the value #{res['HELLOWORLD']} where HELLOWORLD is the key in the property files. All works fine, and the correct string is shown based on locale browser settings.
    Anyway, when I use the "Select Text Resources..." menu in any text value choosing a value from the default property file, JDev automatically adds the following tag:
    <c:set var="customuiBundle" value="#{adfBundle['view.ViewControllerBundle']}"/>
    setting the value of the text in #{ViewControllerBundle.HELLOWORLD}.
    There is a way to avoid this behavior? Can I manage the resources in a different way? I would to choose a value from the list in order to get the res.KEY value instead of ViewControllerBundle.KEY value.
    Thanks in advance for your help.
    Manuel

    don't select from menu - go to source and write it . The problem with the tools is they have a certain way of doing things and don't think we should spend time customizing jdeveloper rather concentrate on the work in hand.

Maybe you are looking for

  • How to use the Oracle FTS search from my own program ?

    Hi, Due to certain reasons, we cann't use the UI that comes up with the Oracle help. Now I am wondering, If anybody has attempted to build something like the following: Have thier own JSP from where they had this search input box Accept the data (inp

  • My screen goes black then macbook restarts...what's happening?

    my screen goes black then macbook restarts...what's happening?  This has been happening often (3-4 times per day).  Not sure what kind of problem I am dealing with.  ideas?

  • Track zreports/transactions Usage

    Hi, Is there a standard program which can be executed to see the information on most used ZReports and transactions by users on a regular basis? I know most of the information is available using T-Code sm20,STAD,st03 but i need a program/report that

  • Matlab code much slower in Labview MatlabScript than in Matlab

    I was using an algorithm written in Matlab that executed in less than 2 seconds. Now I need to use it within a Labview program and I am using Matlab script with the same algorithm, but it lasts 10 times longer than in Matlab. Is this normal? Thank yo

  • Duration of clips keeps changing

    I'm making a graduation movie and the duration of the photos keeps changing.  I've set the duration through inspector and hit "Done".  I work on the project for a little while and then the durations I've set change.  How do I keep them from changing?