<div dir="ltr"><br><div>I am on Arch Linux, so there's that.  I had avoided upgrading for a couple of months.</div><div>Until yesterday morning.</div><div><br></div><div>I'm on ghc 9.02 and xmonad 17.1.</div><div><br></div><div>I had to wade through numerous problems and errors, Arch as well as xmonad deprecations. Nothing to do with scratchpads.</div><div><br></div><div>I am passing my scratchpads to all scratchpad Actions, I have a scratchToggle function to do that, which according to the doc, should continue to work even with the breaking changes to namedScratchpads.</div><div><br></div><div>I do have multiple ways to invoke them.  I have a submap keymap, grid select, and few direct keys in the main keymap.  None of them work. </div><div><br></div><div>None of the named scratchpads work, nor does the old unnamed scratchpad terminal.</div><div>I've ripped out my code and replaced it with the example with no success. </div><div>I've tested examples with xterm, uxrvt and termite.</div><div>I am now mostly back to my original scratchpad code.  Which silently does nothing, Named or otherwise.</div><div><br></div><div>I must be missing something very simple.</div><div><br></div><div>Any clues would be appreciated, my haskell is a bit rusty but coming back a little at a time.</div><div>Here's my relevant code chunks.  Also available on my github.  Itś a rather large config.</div><div><a href="https://github.com/EricGebhart/xmonad-setup/blob/master/.xmonad/xmonad.hs" target="_blank">https://github.com/EricGebhart/xmonad-setup/blob/master/.xmonad/xmonad.hs</a><br><br></div><div>I suspect my manage hooks, but it just doesn´t make sense to me. Everything is</div><div>a bit simpler with the new docks and ewmh stuff, I realize I could simplify it some</div><div>more. But I hate to mess with it too much, when it all looks good and it's been this</div><div>way for years now.</div><div><br></div><div>Any help is much appreciated.</div><div>Thank you,</div><div>Eric</div><div><br></div><div>```haskell</div><div><br></div><div>----------------------------------------------------------------------------<br>-- Scratch Pads ------------------------------------------------------------<br><br>-- location and dimension.<br><br>scratchpadSize = W.RationalRect (1/4) (1/4) (1/3) (3/7)<br><br>mySPFloat = customFloating scratchpadSize<br><br>            -- with a flexible location.<br>-- Big BSP, Small SSP, Super small,<br>--  so size is width and height. - change the fractions to get your sizes right.<br>flexScratchpadSize dx dy = W.RationalRect (dx) (dy) (1/2) (5/7)<br>flexSScratchpadSize dx dy = W.RationalRect (dx) (dy) (3/5) (5/8)<br>flexSSScratchpadSize dx dy = W.RationalRect (dx) (dy) (1/2) (1/2)<br>-- pass in a fraction to determine your x,y location. size is derived from that<br>-- all based on screen size.<br>flexFloatSSP dx dy = customFloating (flexSScratchpadSize dx dy)<br>flexFloatSSSP dx dy = customFloating (flexSSScratchpadSize dx dy)<br>flexFloatBSP dx dy = customFloating (flexScratchpadSize dx dy)<br><br><br>scratchpads =<br>  [ NS "conky"   spawnConky findConky manageConky<br>  , NS "htop" "xterm -e htop" (title =? "htop") defaultFloating -- from the example in the doc<br>  , NS "pavuControl"   spawnPavu findPavu managePavu<br>  , NS "term"  (myTerminal2 ++ " -t term") (title =? "term") (flexFloatBSP (1/20) (1/20))<br>  , NS "term1" (myTerminal2 ++ " -t term1") (title =? "term1") (flexFloatBSP (2/20) (2/20))<br>  , NS "term2" (myTerminal2 ++ " -t term2") (title =? "term2") (flexFloatBSP (3/20) (3/20))<br>  , NS "term3" (myTerminal2 ++ " -t term3") (title =? "term3") (flexFloatBSP (4/20) (4/20))<br>  , NS "term4" (myTerminal2 ++ " -t term4") (title =? "term4") (flexFloatBSP (6/20) (4/20))<br>  , NS "ghci"  (myTerminal2 ++ " -e ghci") (title =? "ghci") (flexFloatBSP (6/20) (1/10))<br>  --, NS "sync"  (myTerminal ++ " -e sy") (title =? "sy") (flexFloatSP (1/10) (2/3))<br>  , NS "top"   (myTerminal2 ++ " -e htop") (title =? "htop") (flexFloatSSP (1/4) (1/4))<br>  , NS "calc"  (myTerminal2 ++ " -e bcl -t bc") (title =? "bc") (flexFloatSSSP (1/4) (1/4))<br>  , NS "alsaMixer"  (myTerminal2 ++ " -e alsamixer -t alsamixer") (title =? "alsamixer") (flexFloatSSSP (1/4) (1/4))<br>  ]<br>  where<br>    spawnConky  = "conky -c ~/.config/conky/Erics.conkyrc" -- launch Conky<br>    findConky   = title =? "system_conky"   -- its window,  has a own_window_title of "system_conky"<br>    manageConky = (flexFloatSSP (1/4) (1/4))<br>    spawnPavu  = "pavucontrol"<br>    findPavu   = title =? "pavucontrol"<br>    managePavu = (flexFloatSSP (1/4) (1/4))<br><br>-- Scratchpad invocation / Dismissal<br>-- Warp<br>bringMouse = warpToWindow (9/10) (9/10)<br>scratchToggle a = namedScratchpadAction scratchpads a >> bringMouse<br></div><div><br></div><div>manageScratchPad :: ManageHook<br>manageScratchPad = scratchpadManageHook (W.RationalRect l t w h)<br>  where<br>    h = 0.6<br>    w = 0.5<br>    t = 1 - h<br>    l = 1 - w<br><br>myScratchpadManageHook =<br>    manageScratchPad <+><br>    namedScratchpadManageHook scratchpads</div><div><br></div><div>myManageHelpers = composeAll . concat $<br>    [ [ className   =? c --> doFloat           | c <- classFloats]<br>    , [ title       =? t --> doFloat           | t <- titleFloats]<br>    , [ resource    =? r --> doFloat           | r <- resourceFloats]<br>    , [ title       =? c --> doIgnore          | c <- titleIgnores]<br>    , [(className =? "Firefox" <&&> resource =? "Dialog") --> doFloat]<br>    ]<br>  where classFloats    = ["Galculator", "Steam", "Media_Center_30", "YACReaderLibrary",<br>                          "MPlayer", "Gimp", "Gajim.py", "Xmessage"]<br>        titleFloats    = ["Volume Control", "alsamixer", "Onboard"]<br>        resourceFloats = ["desktop_window", "Dialog", "gpicview"]<br>        titleIgnores   = ["stalonetray", "xfce4-notifyd"]<br><br>myManageHook = myManageHelpers <+> myScratchpadManageHook<br></div><div><br></div><div>--- keymaps</div><div>...</div><div><br></div><div> -- Scratchpads<br>    , ("M4-e",          toSubmap c "namedScratchpadsKeymap" namedScratchpadsKeymap) -- Scratchpad<br>    , ("M4-n",          scratchpadSpawnActionTerminal  "urxvt") -- Urxvt Scratchpad<br>    , ("M4-S-n",        namedScratchpadAction scratchpads  "term1") -- Term1 Scratchpad<br>    , ("M4-S-e",        namedScratchpadAction scratchpads  "htop") -- htop example Scratchpad<br></div><div><br></div><div>-- manage hooks / def</div><div>myConfig = do<br>  dbus <- D.connectSession<br>  getWellKnownName dbus<br>  return $ defaults {<br>      logHook = do<br>         -- dynamicLogWithPP $ (prettyPrinter dbus)<br>         dynamicLogWithPP $ (myPPPolybar dbus)<br>         fadeinactive<br><br>      , manageHook = myManageHook<br>      , layoutHook = layoutHook defaults<br>      , startupHook = do<br>          myStartupHook        -- >> setWMName "LG3D"<br>      }<br><br>-- docks :: XConfig myConfig -> XConfig myConfig<br><br>------------------------------------------------------------------------<br>-- Combine it all together<br>-- A structure containing your confiuration settings, overriding<br>-- fields in the default config. Any you don't override, will<br><br>-- use the defaults defined in xmonad/XMonad/Config.hs<br>--<br>-- No need to modify this.<br>--<br><br>-- defaultConfig<br>defaults = def {<br>  -- simple stuff<br>   terminal           = myTerminal,<br>   focusFollowsMouse  = myFocusFollowsMouse,<br>   borderWidth        = myBorderWidth,<br>   modMask            = myModMask,<br>   workspaces         = myTopicNames,  -- MyWorkspaces<br>   normalBorderColor  = myNormalBorderColor,<br>   focusedBorderColor = myFocusedBorderColor,<br><br>     -- key bindings<br>   keys               = mainKeymap,<br>   mouseBindings      = myMouseBindings,<br><br>     -- hooks, layouts<br>   layoutHook         = myLayout, -- smartBorders $ myLayout,<br>   manageHook         = myManageHook,<br>   startupHook        = myStartupHook<br>} -- `additionalKeysP` myadditionalKeys<br><br>main :: IO ()<br>main = xmonad . ewmh . docks =<< myConfig<br></div><div>```</div></div>