mirror of
https://github.com/davegallant/nix-config
synced 2025-08-06 03:13:38 +00:00
remove configs that are no longer used
This commit is contained in:
@@ -1,56 +0,0 @@
|
||||
[global]
|
||||
monitor = 0
|
||||
follow = mouse
|
||||
geometry = "500x50-24+24"
|
||||
indicate_hidden = yes
|
||||
shrink = no
|
||||
separator_height = 4
|
||||
separator_color = "#cccccc"
|
||||
padding = 16
|
||||
horizontal_padding = 24
|
||||
transparency = 20
|
||||
frame_width = 4
|
||||
sort = no
|
||||
idle_threshold = 0
|
||||
font = Fira Code 12
|
||||
line_height = 4
|
||||
markup = full
|
||||
format = "<b>%s</b>\n%b"
|
||||
alignment = left
|
||||
show_age_threshold = 60
|
||||
word_wrap = yes
|
||||
ignore_newline = no
|
||||
stack_duplicates = false
|
||||
hide_duplicate_count = yes
|
||||
show_indicators = yes
|
||||
icon_position = off
|
||||
sticky_history = yes
|
||||
history_length = 20
|
||||
browser = firefox -new-tab
|
||||
always_run_script = true
|
||||
title = Dunst
|
||||
class = Dunst
|
||||
|
||||
[shortcuts]
|
||||
close = ctrl+space
|
||||
close_all = ctrl+shift+space
|
||||
history = ctrl+shift+grave
|
||||
context = ctrl+shift+period
|
||||
|
||||
[urgency_low]
|
||||
background = "#000000"
|
||||
foreground = "#ffffff"
|
||||
frame_color = "#add8e6"
|
||||
timeout = 3
|
||||
|
||||
[urgency_normal]
|
||||
background = "#000000"
|
||||
foreground = "#ffffff"
|
||||
frame_color = "#98FB98"
|
||||
timeout = 0
|
||||
|
||||
[urgency_critical]
|
||||
background = "#000000"
|
||||
foreground = "#ffffff"
|
||||
frame_color = "#c61616"
|
||||
timeout = 0
|
@@ -1,236 +0,0 @@
|
||||
# Thank you code_nomad: http://9m.no/ꪯ鵞
|
||||
# and Arch Wiki contributors: https://wiki.archlinux.org/index.php/Compton
|
||||
|
||||
#################################
|
||||
#
|
||||
# Backend
|
||||
#
|
||||
#################################
|
||||
|
||||
# Backend to use: "xrender" or "glx".
|
||||
# GLX backend is typically much faster but depends on a sane driver.
|
||||
backend = "xrender";
|
||||
|
||||
#################################
|
||||
#
|
||||
# GLX backend
|
||||
#
|
||||
#################################
|
||||
|
||||
glx-no-stencil = true;
|
||||
|
||||
# GLX backend: Copy unmodified regions from front buffer instead of redrawing them all.
|
||||
# My tests with nvidia-drivers show a 10% decrease in performance when the whole screen is modified,
|
||||
# but a 20% increase when only 1/4 is.
|
||||
# My tests on nouveau show terrible slowdown.
|
||||
# Useful with --glx-swap-method, as well.
|
||||
glx-copy-from-front = false;
|
||||
|
||||
# GLX backend: Use MESA_copy_sub_buffer to do partial screen update.
|
||||
# My tests on nouveau shows a 200% performance boost when only 1/4 of the screen is updated.
|
||||
# May break VSync and is not available on some drivers.
|
||||
# Overrides --glx-copy-from-front.
|
||||
# glx-use-copysubbuffermesa = true;
|
||||
|
||||
# GLX backend: Avoid rebinding pixmap on window damage.
|
||||
# Probably could improve performance on rapid window content changes, but is known to break things on some drivers (LLVMpipe).
|
||||
# Recommended if it works.
|
||||
# glx-no-rebind-pixmap = true;
|
||||
|
||||
# GLX backend: GLX buffer swap method we assume.
|
||||
# Could be undefined (0), copy (1), exchange (2), 3-6, or buffer-age (-1).
|
||||
# undefined is the slowest and the safest, and the default value.
|
||||
# copy is fastest, but may fail on some drivers,
|
||||
# 2-6 are gradually slower but safer (6 is still faster than 0).
|
||||
# Usually, double buffer means 2, triple buffer means 3.
|
||||
# buffer-age means auto-detect using GLX_EXT_buffer_age, supported by some drivers.
|
||||
# Useless with --glx-use-copysubbuffermesa.
|
||||
# Partially breaks --resize-damage.
|
||||
# Defaults to undefined.
|
||||
glx-swap-method = "undefined";
|
||||
|
||||
#################################
|
||||
#
|
||||
# Shadows
|
||||
#
|
||||
#################################
|
||||
|
||||
# Enabled client-side shadows on windows.
|
||||
shadow = true;
|
||||
# The blur radius for shadows. (default 12)
|
||||
shadow-radius = 5;
|
||||
# The left offset for shadows. (default -15)
|
||||
shadow-offset-x = -5;
|
||||
# The top offset for shadows. (default -15)
|
||||
shadow-offset-y = -5;
|
||||
# The translucency for shadows. (default .75)
|
||||
shadow-opacity = 0.5;
|
||||
|
||||
# Set if you want different colour shadows
|
||||
# shadow-red = 0.0;
|
||||
# shadow-green = 0.0;
|
||||
# shadow-blue = 0.0;
|
||||
|
||||
# The shadow exclude options are helpful if you have shadows enabled. Due to the way compton draws its shadows, certain applications will have visual glitches
|
||||
# (most applications are fine, only apps that do weird things with xshapes or argb are affected).
|
||||
# This list includes all the affected apps I found in my testing. The "! name~=''" part excludes shadows on any "Unknown" windows, this prevents a visual glitch with the XFWM alt tab switcher.
|
||||
shadow-exclude = [
|
||||
"! name~=''",
|
||||
"name *= 'Chrome'",
|
||||
"name *= 'Chromium'",
|
||||
"name *= 'VLC'",
|
||||
"name *= 'compton'",
|
||||
"name = 'Docky'",
|
||||
"name = 'Kupfer'",
|
||||
"name = 'Notification'",
|
||||
"name = 'Plank'",
|
||||
"name = 'cpt_frame_window'",
|
||||
"class_g = 'Firefox' && argb",
|
||||
"class_g = 'Tor Browser' && argb",
|
||||
"class_g = 'Conky'",
|
||||
"class_g = 'Kupfer'",
|
||||
"class_g = 'Synapse'",
|
||||
"class_g ?= 'Notify-osd'",
|
||||
"class_g ?= 'Cairo-dock'",
|
||||
"class_g ?= 'Xfce4-notifyd'",
|
||||
"class_g ?= 'Xfce4-power-manager'",
|
||||
"_GTK_FRAME_EXTENTS@:c",
|
||||
"_NET_WM_STATE@:32a *= '_NET_WM_STATE_HIDDEN'"
|
||||
];
|
||||
# Avoid drawing shadow on all shaped windows (see also: --detect-rounded-corners)
|
||||
shadow-ignore-shaped = false;
|
||||
|
||||
#################################
|
||||
#
|
||||
# Opacity
|
||||
#
|
||||
#################################
|
||||
|
||||
#inactive-opacity = 1;
|
||||
#active-opacity = 1;
|
||||
#frame-opacity = 1;
|
||||
#inactive-opacity-override = false;
|
||||
|
||||
opacity-rule = ["85:class_g = 'kitty'"];
|
||||
|
||||
# Dim inactive windows. (0.0 - 1.0)
|
||||
# inactive-dim = 0.2;
|
||||
# Do not let dimness adjust based on window opacity.
|
||||
# inactive-dim-fixed = true;
|
||||
# Blur background of transparent windows. Bad performance with X Render backend. GLX backend is preferred.
|
||||
# blur-background = true;
|
||||
# Blur background of opaque windows with transparent frames as well.
|
||||
# blur-background-frame = true;
|
||||
# Do not let blur radius adjust based on window opacity.
|
||||
blur-background-fixed = false;
|
||||
blur-background-exclude = [
|
||||
"window_type = 'dock'",
|
||||
"window_type = 'desktop'"
|
||||
];
|
||||
|
||||
#################################
|
||||
#
|
||||
# Fading
|
||||
#
|
||||
#################################
|
||||
|
||||
# Fade windows during opacity changes.
|
||||
fading = true;
|
||||
# The time between steps in a fade in milliseconds. (default 10).
|
||||
fade-delta = 4;
|
||||
# Opacity change between steps while fading in. (default 0.028).
|
||||
fade-in-step = 0.03;
|
||||
# Opacity change between steps while fading out. (default 0.03).
|
||||
fade-out-step = 0.03;
|
||||
# Fade windows in/out when opening/closing
|
||||
# no-fading-openclose = true;
|
||||
|
||||
# Specify a list of conditions of windows that should not be faded.
|
||||
fade-exclude = [ ];
|
||||
|
||||
#################################
|
||||
#
|
||||
# Other
|
||||
#
|
||||
#################################
|
||||
|
||||
# Try to detect WM windows and mark them as active.
|
||||
mark-wmwin-focused = true;
|
||||
# Mark all non-WM but override-redirect windows active (e.g. menus).
|
||||
mark-ovredir-focused = true;
|
||||
# Use EWMH _NET_WM_ACTIVE_WINDOW to determine which window is focused instead of using FocusIn/Out events.
|
||||
# Usually more reliable but depends on a EWMH-compliant WM.
|
||||
use-ewmh-active-win = true;
|
||||
# Detect rounded corners and treat them as rectangular when --shadow-ignore-shaped is on.
|
||||
detect-rounded-corners = true;
|
||||
|
||||
# Detect _NET_WM_OPACITY on client windows, useful for window managers not passing _NET_WM_OPACITY of client windows to frame windows.
|
||||
# This prevents opacity being ignored for some apps.
|
||||
# For example without this enabled my xfce4-notifyd is 100% opacity no matter what.
|
||||
detect-client-opacity = true;
|
||||
|
||||
# Specify refresh rate of the screen.
|
||||
# If not specified or 0, compton will try detecting this with X RandR extension.
|
||||
refresh-rate = 0;
|
||||
|
||||
# Set VSync method. VSync methods currently available:
|
||||
# none: No VSync
|
||||
# drm: VSync with DRM_IOCTL_WAIT_VBLANK. May only work on some drivers.
|
||||
# opengl: Try to VSync with SGI_video_sync OpenGL extension. Only work on some drivers.
|
||||
# opengl-oml: Try to VSync with OML_sync_control OpenGL extension. Only work on some drivers.
|
||||
# opengl-swc: Try to VSync with SGI_swap_control OpenGL extension. Only work on some drivers. Works only with GLX backend. Known to be most effective on many drivers. Does not actually control paint timing, only buffer swap is affected, so it doesn’t have the effect of --sw-opti unlike other methods. Experimental.
|
||||
# (Note some VSync methods may not be enabled at compile time.)
|
||||
vsync = "opengl";
|
||||
|
||||
# Enable DBE painting mode, intended to use with VSync to (hopefully) eliminate tearing.
|
||||
# Reported to have no effect, though.
|
||||
dbe = false;
|
||||
|
||||
# Limit compton to repaint at most once every 1 / refresh_rate second to boost performance.
|
||||
# This should not be used with --vsync drm/opengl/opengl-oml as they essentially does --sw-opti's job already,
|
||||
# unless you wish to specify a lower refresh rate than the actual value.
|
||||
#sw-opti = true;
|
||||
|
||||
# Unredirect all windows if a full-screen opaque window is detected, to maximize performance for full-screen windows, like games.
|
||||
# Known to cause flickering when redirecting/unredirecting windows.
|
||||
unredir-if-possible = false;
|
||||
|
||||
# Specify a list of conditions of windows that should always be considered focused.
|
||||
focus-exclude = [ ];
|
||||
|
||||
# Use WM_TRANSIENT_FOR to group windows, and consider windows in the same group focused at the same time.
|
||||
detect-transient = true;
|
||||
# Use WM_CLIENT_LEADER to group windows, and consider windows in the same group focused at the same time.
|
||||
# WM_TRANSIENT_FOR has higher priority if --detect-transient is enabled, too.
|
||||
detect-client-leader = true;
|
||||
|
||||
#################################
|
||||
#
|
||||
# Window type settings
|
||||
#
|
||||
#################################
|
||||
|
||||
wintypes:
|
||||
{
|
||||
tooltip =
|
||||
{
|
||||
# fade: Fade the particular type of windows.
|
||||
fade = true;
|
||||
# shadow: Give those windows shadow
|
||||
shadow = false;
|
||||
# opacity: Default opacity for the type of windows.
|
||||
opacity = 0.85;
|
||||
# focus: Whether to always consider windows of this type focused.
|
||||
focus = true;
|
||||
};
|
||||
};
|
||||
|
||||
######################
|
||||
#
|
||||
# XSync
|
||||
# See: https://github.com/yshui/compton/commit/b18d46bcbdc35a3b5620d817dd46fbc76485c20d
|
||||
#
|
||||
######################
|
||||
|
||||
# Use X Sync fence to sync clients' draw calls. Needed on nvidia-drivers with GLX backend for some users.
|
||||
xrender-sync-fence = true;
|
@@ -1,18 +0,0 @@
|
||||
[Unit]
|
||||
Description=Clipmenu daemon
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/clipmenud
|
||||
Restart=always
|
||||
RestartSec=500ms
|
||||
Environment=DISPLAY=:0
|
||||
|
||||
MemoryDenyWriteExecute=yes
|
||||
NoNewPrivileges=yes
|
||||
ProtectControlGroups=yes
|
||||
ProtectKernelTunables=yes
|
||||
RestrictAddressFamilies=
|
||||
RestrictRealtime=yes
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
@@ -1,95 +0,0 @@
|
||||
Config {
|
||||
|
||||
-- appearance
|
||||
font = "xft:Fira Code:size=10:bold:antialias=true"
|
||||
, bgColor = "black"
|
||||
, fgColor = "#CCC"
|
||||
, position = TopP 0 80
|
||||
, border = BottomB
|
||||
, borderColor = "#646464"
|
||||
|
||||
-- layout
|
||||
, sepChar = "%" -- delineator between plugin names and straight text
|
||||
, alignSep = "}{" -- separator between left-right alignment
|
||||
, template = "%UnsafeStdinReader% }{ %multicpu% | %memory% | %dynnetwork% | %battery% | %date%"
|
||||
|
||||
-- general behavior
|
||||
, lowerOnStart = True -- send to bottom of window stack on start
|
||||
, hideOnStart = False -- start with window unmapped (hidden)
|
||||
, allDesktops = True -- show on all desktops
|
||||
, overrideRedirect = True -- set the Override Redirect flag (Xlib)
|
||||
, pickBroadest = False -- choose widest display (multi-monitor)
|
||||
, persistent = True -- enable/disable hiding (True = disabled)
|
||||
|
||||
-- plugins
|
||||
-- Numbers can be automatically colored according to their value. xmobar
|
||||
-- decides color based on a three-tier/two-cutoff system, controlled by
|
||||
-- command options:
|
||||
-- --Low sets the low cutoff
|
||||
-- --High sets the high cutoff
|
||||
--
|
||||
-- --low sets the color below --Low cutoff
|
||||
-- --normal sets the color between --Low and --High cutoffs
|
||||
-- --High sets the color above --High cutoff
|
||||
--
|
||||
-- The --template option controls how the plugin is displayed. Text
|
||||
-- color can be set by enclosing in <fc></fc> tags. For more details
|
||||
-- see http://projects.haskell.org/xmobar/#system-monitor-plugins.
|
||||
, commands =
|
||||
|
||||
-- network activity monitor (dynamic interface resolution)
|
||||
[ Run DynNetwork [ "--template" , "<dev>: <tx>kB/s|<rx>kB/s"
|
||||
, "--Low" , "1000" -- units: B/s
|
||||
, "--High" , "5000" -- units: B/s
|
||||
, "--low" , "darkgreen"
|
||||
, "--normal" , "darkorange"
|
||||
, "--high" , "darkred"
|
||||
] 10
|
||||
|
||||
-- cpu activity monitor
|
||||
, Run MultiCpu [ "--template" , "Cpu: <total>%"
|
||||
, "--Low" , "50" -- units: %
|
||||
, "--High" , "85" -- units: %
|
||||
, "--low" , "darkgreen"
|
||||
, "--normal" , "darkorange"
|
||||
, "--high" , "darkred"
|
||||
] 10
|
||||
|
||||
-- memory usage monitor
|
||||
, Run Memory [ "--template" ,"Mem: <usedratio>%"
|
||||
, "--Low" , "20" -- units: %
|
||||
, "--High" , "90" -- units: %
|
||||
, "--low" , "darkgreen"
|
||||
, "--normal" , "darkorange"
|
||||
, "--high" , "darkred"
|
||||
] 10
|
||||
|
||||
-- battery monitor
|
||||
, Run Battery [ "--template" , "Batt: <acstatus>"
|
||||
, "--Low" , "10" -- units: %
|
||||
, "--High" , "80" -- units: %
|
||||
, "--low" , "darkred"
|
||||
, "--normal" , "darkorange"
|
||||
, "--high" , "darkgreen"
|
||||
|
||||
, "--" -- battery specific options
|
||||
-- discharging status
|
||||
, "-o" , "<left>% (<timeleft>)"
|
||||
-- AC "on" status
|
||||
, "-O" , "<fc=#dAA520>Charging</fc>"
|
||||
-- charged status
|
||||
, "-i" , "<fc=#006000>Charged</fc>"
|
||||
] 50
|
||||
|
||||
-- time and date indicator
|
||||
-- (%F = y-m-d date, %a = day of week, %T = h:m:s time)
|
||||
, Run Date "<fc=#ABABAB>%F (%a) %T</fc>" "date" 10
|
||||
|
||||
, Run UnsafeStdinReader
|
||||
|
||||
-- keyboard layout indicator
|
||||
, Run Kbd [ ("us(dvorak)" , "<fc=#00008B>DV</fc>")
|
||||
, ("us" , "<fc=#8B0000>US</fc>")
|
||||
]
|
||||
]
|
||||
}
|
@@ -1,337 +0,0 @@
|
||||
--
|
||||
import Data.Monoid
|
||||
import Graphics.X11.ExtraTypes.XF86
|
||||
import System.Exit
|
||||
import System.IO (hPutStrLn)
|
||||
import XMonad
|
||||
import XMonad.Hooks.DynamicLog
|
||||
import XMonad.Hooks.ManageDocks
|
||||
import XMonad.Util.Run(spawnPipe)
|
||||
import XMonad.Util.SpawnOnce
|
||||
import XMonad.Hooks.EwmhDesktops
|
||||
|
||||
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 = "alacritty"
|
||||
|
||||
-- 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
|
||||
|
||||
-- NOTE: from 0.9.1 on numlock mask is set automatically. The numlockMask
|
||||
-- setting should be removed from configs.
|
||||
--
|
||||
-- You can safely remove this even on earlier xmonad versions unless you
|
||||
-- need to set it to something other than the default mod2Mask, (e.g. OSX).
|
||||
--
|
||||
-- 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 -- deprecated in xmonad-0.9.1
|
||||
------------------------------------------------------------
|
||||
|
||||
|
||||
-- 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 = "#cccccc"
|
||||
myFocusedBorderColor = "#b541c4"
|
||||
|
||||
lockScreen = "i3lock-fancy-rapid 10 2 pixels"
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- 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 "rofi -show run")
|
||||
|
||||
-- launch gmrun
|
||||
, ((modm .|. shiftMask, xK_p ), spawn "gmrun")
|
||||
|
||||
-- close focused window
|
||||
, ((modm .|. shiftMask, xK_c ), kill)
|
||||
|
||||
-- lock the screen
|
||||
, ((modm .|. shiftMask, xK_l ), spawn lockScreen)
|
||||
|
||||
-- suspend
|
||||
, ((modm .|. shiftMask, xK_s ), spawn $ lockScreen ++ " && systemctl suspend")
|
||||
|
||||
-- screenshot
|
||||
, ((modm , xK_Print ), spawn "import png:- | xclip -selection clipboard -t image/png")
|
||||
|
||||
-- multimedia
|
||||
, ((0, xF86XK_AudioPlay), spawn "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlayPause")
|
||||
, ((0, xF86XK_AudioStop), spawn "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Stop")
|
||||
, ((0, xF86XK_AudioPrev), spawn "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Previous")
|
||||
, ((0, xF86XK_AudioNext), spawn "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Next")
|
||||
|
||||
-- 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 exitSuccess)
|
||||
|
||||
-- Restart xmonad
|
||||
, ((modm , xK_q ), spawn "xmonad --recompile; xmonad --restart")
|
||||
]
|
||||
++
|
||||
|
||||
--
|
||||
-- mod-[1..9], Switch to workspace N
|
||||
--
|
||||
-- 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 = avoidStruts (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 =? "Gimp" --> doFloat
|
||||
, resource =? "desktop_window" --> doIgnore
|
||||
, resource =? "kdesktop" --> doIgnore ]
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- Event handling
|
||||
|
||||
-- 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.
|
||||
--
|
||||
-- * NOTE: EwmhDesktops users should use the 'ewmh' function from
|
||||
-- XMonad.Hooks.EwmhDesktops to modify their defaultConfig as a whole.
|
||||
-- It will add EWMH event handling to your custom event hooks by
|
||||
-- combining them with ewmhDesktopsEventHook.
|
||||
--
|
||||
myEventHook = docksEventHook <+> handleEventHook def <+> 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.
|
||||
--
|
||||
--
|
||||
-- * NOTE: EwmhDesktops users should use the 'ewmh' function from
|
||||
-- XMonad.Hooks.EwmhDesktops to modify their defaultConfig as a whole.
|
||||
-- It will add EWMH logHook actions to your custom log hook by
|
||||
-- combining it with ewmhDesktopsLogHook.
|
||||
--
|
||||
myLogHook h = dynamicLogWithPP $ xmobarPP
|
||||
{ ppOutput = hPutStrLn h
|
||||
, ppCurrent = xmobarColor "yellow" "" . wrap "[" "]"
|
||||
, ppTitle = xmobarColor "grey" "" . shorten 80
|
||||
, ppVisible = wrap "(" ")"
|
||||
, ppUrgent = xmobarColor "red" "yellow"
|
||||
, ppWsSep = " "
|
||||
, ppOrder = \(ws:l:t:_) -> [ws,t]
|
||||
}
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- 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.
|
||||
--
|
||||
-- * NOTE: EwmhDesktops users should use the 'ewmh' function from
|
||||
-- XMonad.Hooks.EwmhDesktops to modify their defaultConfig as a whole.
|
||||
-- It will add initialization of EWMH support to your custom startup
|
||||
-- hook by combining it with ewmhDesktopsStartup.
|
||||
--
|
||||
myStartupHook = do
|
||||
spawnOnce "dunst &"
|
||||
spawnOnce "feh --bg-fill ~/Pictures/Wallpapers/laughingman.jpg"
|
||||
spawnOnce "if xinput list | grep -qi 'mouse'; then xmodmap -e 'pointer = 3 2 1 ';fi" -- flip mouse buttons
|
||||
spawnOnce "picom --config ~/.config/picom.conf -b"
|
||||
spawnOnce "stalonetray &"
|
||||
spawn "xautolock -time 5 -locker 'i3lock-fancy-rapid 10 2 pixels' -notify 30 -notifier \"notify-send -t 30000 'Locking in 30 seconds'\""
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- Now run xmonad with all the defaults we set up.
|
||||
|
||||
-- Run xmonad with the settings you specify. No need to modify this.
|
||||
--
|
||||
main = do
|
||||
xmproc <- spawnPipe "LC_ALL=C.UTF-8 xmobar -x 2 ~/.config/xmobar/xmobar.hs"
|
||||
xmonad $ ewmh $ docks 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 xmproc,
|
||||
startupHook = myStartupHook
|
||||
}
|
Reference in New Issue
Block a user