From fa9fbff5b90d6b05ce646a0d2853d9f5d351ba75 Mon Sep 17 00:00:00 2001 From: Dmitriy Pleshevskiy Date: Thu, 6 Apr 2023 15:01:24 +0300 Subject: [PATCH] user/xmonad: tile below only alacritty windows --- home/modules/window_manager/xmonad_config.hs | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/home/modules/window_manager/xmonad_config.hs b/home/modules/window_manager/xmonad_config.hs index d16c056..c2cbba2 100644 --- a/home/modules/window_manager/xmonad_config.hs +++ b/home/modules/window_manager/xmonad_config.hs @@ -16,13 +16,13 @@ import qualified Data.Map.Strict as Map import Data.Monoid import System.Exit import XMonad -import XMonad.Actions.Minimize (withLastMinimized, minimizeWindow, maximizeWindow) import XMonad.Actions.CycleSelectedLayouts (cycleThroughLayouts) import XMonad.Actions.EasyMotion ( ChordKeys (..), EasyMotionConfig (..), selectWindow, ) +import XMonad.Actions.Minimize (maximizeWindow, minimizeWindow, withLastMinimized) import XMonad.Hooks.DynamicLog import XMonad.Hooks.EwmhDesktops import XMonad.Hooks.InsertPosition (Focus (Newer), Position (Below), insertPosition) @@ -35,14 +35,14 @@ import XMonad.Hooks.ManageHelpers ) import XMonad.Hooks.StatusBar import XMonad.Hooks.StatusBar.PP -import XMonad.Layout.BoringWindows (boringWindows, focusUp, focusDown, focusMaster, swapUp, swapDown) +import XMonad.Layout.BoringWindows (boringWindows, focusDown, focusMaster, focusUp, swapDown, swapUp) import XMonad.Layout.Gaps (gaps) import XMonad.Layout.Grid import XMonad.Layout.LimitWindows (limitWindows) -import XMonad.Layout.NoBorders (smartBorders) -import XMonad.Layout.Spacing (spacing) import XMonad.Layout.Minimize (minimize) -import XMonad.Layout.Renamed (renamed, Rename (..)) +import XMonad.Layout.NoBorders (smartBorders) +import XMonad.Layout.Renamed (Rename (..), renamed) +import XMonad.Layout.Spacing (spacing) import XMonad.Prompt (XPConfig (..), XPPosition (Top), XPType (..), XPrompt (..), mkComplFunFromList', mkXPromptWithModes) import qualified XMonad.StackSet as W import XMonad.Util.EZConfig @@ -178,7 +178,9 @@ myLayoutHook = mirrorTiled ||| tiled ||| full myGaps gap = gaps [(U, gap), (D, gap), (L, gap), (R, gap)] fullLayoutId = "Full" + tallLayoutId = "Tall" + mirrorTallLayoutId = "Mirror Tall" ------------------------------------------------------------------------ @@ -231,6 +233,7 @@ myManageHook = manageApps role = stringProperty "WM_WINDOW_ROLE" isPopup = role =? "pop-up" isPinentry = anyOf [className =? "Gcr-promter", className =? "Pinentry"] + isAlacritty = className =? "Alacritty" anyOf :: [Query Bool] -> Query Bool anyOf = foldl (<||>) (pure False) tileBelow = insertPosition Below Newer @@ -250,7 +253,7 @@ myManageHook = manageApps isPinentry ] -?> doCenterFloat, - pure True -?> tileBelow + isAlacritty -?> tileBelow ] ------------------------------------------------------------------------