mirror of
https://github.com/vincentbernat/i3wm-configuration.git
synced 2025-08-23 10:58:18 +02:00
picom: compute an offset for shadows
This commit is contained in:
parent
d5dbb906b4
commit
100a23fb03
2 changed files with 5 additions and 3 deletions
|
@ -4,11 +4,13 @@ dpi=$(xrdb -query | sed -nE 's/^Xft\.dpi:\s*//p')
|
|||
|
||||
POLYBAR_HEIGHT=$((20 * dpi / 96))
|
||||
SHADOW_RADIUS=$((12 * dpi / 96))
|
||||
SHADOW_OFFSET=$((SHADOW_RADIUS*2/3))
|
||||
|
||||
# Configure picom
|
||||
cat ~/.config/i3/dotfiles/picom.conf \
|
||||
| sed -e "s/@POLYBAR_HEIGHT@/$POLYBAR_HEIGHT/" \
|
||||
| sed -e "s/@SHADOW_RADIUS@/$SHADOW_RADIUS/" \
|
||||
| sed -e "s/@SHADOW_OFFSET@/$SHADOW_OFFSET/" \
|
||||
> $XDG_RUNTIME_DIR/i3/picom.conf.new
|
||||
|
||||
# Put new configuration file in place
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue