From a0430329f1d334fbb5fcdd8e31834db5bbbf6839 Mon Sep 17 00:00:00 2001 From: termite Date: Wed, 7 May 2025 19:32:35 -0700 Subject: [PATCH] Added Picom, along with changing colors for transparency --- alacritty | 3 + dunstrc | 4 +- i3config | 11 +- install | 2 + installpackages.txt | 1 + picom.conf | 245 ++++++++++++++++++++++++++++++++++++++++++++ 6 files changed, 259 insertions(+), 7 deletions(-) create mode 100644 picom.conf diff --git a/alacritty b/alacritty index 4133644..8d7bc02 100644 --- a/alacritty +++ b/alacritty @@ -6,6 +6,9 @@ family = "monospace" [env] WINIT_X11_SCALE_FACTOR="1.0" +[window] +opacity = 0.75 + # Colours (Monokai Charcoal) # Default Colours diff --git a/dunstrc b/dunstrc index 26bd2a7..f6f5e37 100644 --- a/dunstrc +++ b/dunstrc @@ -108,7 +108,7 @@ # Defines width in pixels of frame around the notification window. # Set to 0 to disable. - frame_width = 3 + frame_width = 1 # Defines color of the frame around the notification window. frame_color = "#aaaaaa" @@ -326,7 +326,7 @@ mouse_left_click = close_current mouse_middle_click = do_action, close_current mouse_right_click = close_all - background = "#000000" + background = "#00000088" foreground = "#ffffff" highlight = "#ffffff" diff --git a/i3config b/i3config index 562416f..ad569f1 100644 --- a/i3config +++ b/i3config @@ -49,8 +49,8 @@ bindsym XF86AudioPlay exec --no-startup-id ~/.dotfiles/bin/volbright play_pause bindsym XF86AudioNext exec --no-startup-id ~/.dotfiles/bin/volbright next_track bindsym XF86AudioPrev exec --no-startup-id ~/.dotfiles/bin/volbright prev_track -bindsym --release XF86RotateWindows exec ~/.dotfiles/bin/rotatescreen -bindsym --release XF86TaskPane exec ~/.dotfiles/bin/flipscreen +bindsym --release XF86RotateWindows exec --no-startup-id ~/.dotfiles/bin/rotatescreen +bindsym --release XF86TaskPane exec --no-startup-id ~/.dotfiles/bin/flipscreen bindsym --release Print exec flameshot gui bindsym --release $mod+Print exec flameshot screen @@ -224,9 +224,9 @@ bar { default_border pixel 1 # class border backgr. text indicator child_border -client.focused #ffffff #000000 #ffffff #ffffff #ffffff -client.focused_inactive #555555 #555555 #ffffff #555555 #555555 -client.unfocused #000000 #222222 #bbbbbb #000000 #000000 +client.focused #ffffff #000000AA #ffffff #ffffff #ffffff +client.focused_inactive #555555 #000000AA #ffffff #555555 #555555 +client.unfocused #000000 #000000AA #bbbbbb #000000 #00000088 client.urgent #900000 #900000 #ffffff #900000 #900000 client.placeholder #0c0c0c #0c0c0c #ffffff #000000 #0c0c0c @@ -237,6 +237,7 @@ bindsym $mod+minus scratchpad show exec --no-startup-id nm-applet exec --no-startup-id dunst +exec_always --no-startup-id picom -b include ~/.dotfiles/setup_specific/i3extraconf diff --git a/install b/install index 38f4e13..e8997d9 100755 --- a/install +++ b/install @@ -15,12 +15,14 @@ ln -sf ~/.dotfiles/ncmpcppconfig ~/.config/ncmpcpp/config mkdir -p ~/.config/dunst ln -sf ~/.dotfiles/dunstrc ~/.config/dunst/dunstrc + mkdir -p ~/.config/alacritty ln -sf ~/.dotfiles/alacritty ~/.config/alacritty/alacritty.toml mkdir -p ~/.config/i3blocks ln -sf ~/.dotfiles/i3blocks ~/.config/i3blocks/config +ln -sf ~/.dotfiles/picom.conf ~/.config/picom.conf ln -sf ~/.dotfiles/bashrc ~/.bashrc ln -sf ~/.dotfiles/bash_profile ~/.bash_profile ln -sf ~/.dotfiles/xinitrc ~/.xinitrc diff --git a/installpackages.txt b/installpackages.txt index f7e0bb5..e3462b1 100644 --- a/installpackages.txt +++ b/installpackages.txt @@ -18,3 +18,4 @@ python3 sysstat wireless_tools papirus-icon-theme +picom diff --git a/picom.conf b/picom.conf new file mode 100644 index 0000000..86a84a5 --- /dev/null +++ b/picom.conf @@ -0,0 +1,245 @@ +################################# +# Transparency / Opacity # +################################# + +# Opacity of window titlebars and borders. +# +# Range: 0.1 - 1.0 +# Default: 1.0 (disabled) +#frame-opacity = 1.0; + +# Use fixed inactive dim value, instead of adjusting according to window opacity. +# +# Default: false +# inactive-dim-fixed = true + +################################# +# Corners # +################################# + +# Sets the radius of rounded window corners. When > 0, the compositor will +# round the corners of windows. Does not interact well with +# `transparent-clipping`. +# +# Default: 0 (disabled) +corner-radius = 0 + +################################# +# Blur # +################################# + +# Parameters for background blurring, see BLUR section in the man page for more information. +#blur-method = gaussian +blur: { + method = "dual_kawase"; + strength = 2; +}; + + +# Blur background of semi-transparent / ARGB windows. +# Can be set per-window using rules. +# +# Default: false +# blur-background = false + +# Blur background of windows when the window frame is not opaque. +# Implies: +# blur-background +# +# Default: false +# blur-background-frame = false + +# Use fixed blur strength rather than adjusting according to window opacity. +# +# Default: false +# blur-background-fixed = false + + +# Specify the blur convolution kernel, with the following format: +# example: +# blur-kern = "5,5,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1"; +# Can also be a pre-defined kernel, see the man page. +# +# Default: "" +#blur-kern = "3x3box"; + +################################# +# General Settings # +################################# + +# Enable remote control via D-Bus. See the man page for more details. +# +# Default: false +# dbus = true + +# Daemonize process. Fork to background after initialization. Causes issues with certain (badly-written) drivers. +# daemon = false + +# Specify the backend to use: `xrender`, `glx`, or `egl`. +# +# Default: "xrender" +backend = "glx" + +# Use higher precision during rendering, and apply dither when presenting the +# rendered screen. Reduces banding artifacts, but may cause performance +# degradation. Only works with OpenGL. +dithered-present = false; + +# Enable/disable VSync. +# +# Default: false +#vsync = false; + +# Try to detect windows with rounded corners and don't consider them +# shaped windows. The accuracy is not very high, unfortunately. +# +# Has nothing to do with `corner-radius`. +# +# Default: false +detect-rounded-corners = true; + +# Detect '_NET_WM_WINDOW_OPACITY' on client windows, useful for window managers +# not passing '_NET_WM_WINDOW_OPACITY' of client windows to frame windows. +# +# Default: false +detect-client-opacity = true; + +# Use EWMH '_NET_ACTIVE_WINDOW' to determine currently focused window, +# rather than listening to 'FocusIn'/'FocusOut' event. May be more accurate, +# provided that the WM supports it. +# +# Default: false +# use-ewmh-active-win = false + +# Unredirect all windows if a full-screen opaque window is detected, +# to maximize performance for full-screen windows. Known to cause flickering +# when redirecting/unredirecting windows. +# +# Default: false +# unredir-if-possible = false + +# Delay before unredirecting the window, in milliseconds. +# +# Default: 0. +# unredir-if-possible-delay = 0 + +# Use 'WM_TRANSIENT_FOR' to group windows, and consider windows +# in the same group focused at the same time. +# +# Default: false +detect-transient = true; + +# Use 'WM_CLIENT_LEADER' to group windows, and consider windows in the same +# group focused at the same time. This usually means windows from the same application +# will be considered focused or unfocused at the same time. +# 'WM_TRANSIENT_FOR' has higher priority if detect-transient is enabled, too. +# +# Default: false +# detect-client-leader = false + +# Use of damage information for rendering. This cause the only the part of the +# screen that has actually changed to be redrawn, instead of the whole screen +# every time. Should improve performance. +# +# Default: false +use-damage = true; + +# Use X Sync fence to wait for the completion of rendering of other windows, +# before using their content to render the current screen. +# +# Required for explicit sync drivers, such as nvidia. +# +# Default: false +# xrender-sync-fence = false + +# GLX backend: Use specified GLSL fragment shader for rendering window +# contents. Read the man page for a detailed explanation of the interface. +# +# Can be set per-window using rules. +# +# window-shader-fg = "default" + +# Force all windows to be painted with blending. Useful if you +# have a `window-shader-fg` that could turn opaque pixels transparent. +# +# Default: false +# force-win-blend = false + +# Do not use EWMH to detect fullscreen windows. +# Reverts to checking if a window is fullscreen based only on its size and coordinates. +# +# Default: false +# no-ewmh-fullscreen = false + +# Dimming bright windows so their brightness doesn't exceed this set value. +# Brightness of a window is estimated by averaging all pixels in the window, +# so this could comes with a performance hit. +# Setting this to 1.0 disables this behaviour. Requires --use-damage to be disabled. +# +# Default: 1.0 (disabled) +# max-brightness = 1.0 + +# Make transparent windows clip other windows like non-transparent windows do, +# instead of blending on top of them. e.g. placing a transparent window on top +# of another window will cut a "hole" in that window, and show the desktop background +# underneath. +# +# Default: false +transparent-clipping = true + +# Set the log level. Possible values are: +# "trace", "debug", "info", "warn", "error" +# in increasing level of importance. Case insensitive. +# If using the "TRACE" log level, it's better to log into a file +# using *--log-file*, since it can generate a huge stream of logs. +# +# Default: "warn" +# log-level = "warn"; + +# Set the log file. +# If *--log-file* is never specified, logs will be written to stderr. +# Otherwise, logs will to written to the given file, though some of the early +# logs might still be written to the stderr. +# When setting this option from the config file, it is recommended to use an absolute path. +# +# log-file = "/path/to/your/log/file" + +# Write process ID to a file. +# write-pid-path = "/path/to/your/log/file" + +# Rule-based per-window options. +# +# See WINDOW RULES section in the man page for how these work. +rules: ({ + match = "window_type = 'tooltip'"; + fade = false; + shadow = true; + opacity = 0.75; + full-shadow = false; +}, { + match = "window_type = 'dock' || " + "window_type = 'desktop' || " + "_GTK_FRAME_EXTENTS@"; + blur-background = false; +}, { + match = "window_type != 'dock'"; + # shader = "my_shader.frag"; +}, { + match = "window_type = 'dock' || " + "window_type = 'desktop'"; + corner-radius = 0; +}, { + match = "name = 'Notification' || " + "class_g = 'Conky' || " + "class_g ?= 'Notify-osd' || " + "class_g = 'Cairo-clock' || " + "_GTK_FRAME_EXTENTS@"; + shadow = false; +}) + +# `@include` directive can be used to include additional configuration files. +# Relative paths are search either in the parent of this configuration file +# (when the configuration is loaded through a symlink, the symlink will be +# resolved first). Or in `$XDG_CONFIG_HOME/picom/include`. +# +# @include "extra.conf"