use Fira Code as font, add setwall script

This commit is contained in:
krolxon 2025-08-13 15:01:43 +05:30
parent ecb14b548e
commit 32247d59a2
6 changed files with 63 additions and 46 deletions

View File

@ -89,10 +89,10 @@ persistent_logging = false
render_timer = false
[font]
size = 11
size = 12
[font.bold]
family = "JetBrainsMono Nerd Font"
family = "Fira Code"
style = "Bold"
[font.glyph_offset]
@ -100,11 +100,11 @@ x = 0
y = 0
[font.italic]
family = "JetBrainsMono Nerd Font"
family = "Fira Code"
style = "Italic"
[font.normal]
family = "JetBrainsMono Nerd Font"
family = "Fira Code"
style = "Regular"
[font.offset]
@ -650,7 +650,7 @@ semantic_escape_chars = ",│`|:\"' ()[]{}<>"
[window]
decorations = "none"
dynamic_padding = false
opacity = 0.8
opacity = 0.9
startup_mode = "Maximized"
[window.dimensions]
@ -658,8 +658,8 @@ columns = 0
lines = 0
[window.padding]
x = 0
y = 0
x = 5
y = 5
[general]

View File

@ -4,7 +4,7 @@
include "/home/krolyxon/.gtkrc-2.0.mine"
gtk-theme-name="Arc-Dark"
gtk-icon-theme-name="Papirus-Dark"
gtk-font-name="JetBrainsMonoNL Nerd Font Thin 11"
gtk-font-name="Fira Code 11"
gtk-cursor-theme-name="Adwaita"
gtk-cursor-theme-size=0
gtk-toolbar-style=GTK_TOOLBAR_BOTH

View File

@ -1,18 +0,0 @@
#!/bin/sh
# Dependencies:
# convert wal xdotool xwallpaper
wall_dir=~/pix/wall
if [ -z "$1" ]; then
wall="$(find "$wall_dir" -type f -name "*.jpg" -o -name "*.png" | shuf -n1)"
else
wall="$1"
fi
convert "$wall" ~/.local/share/bg.jpg
xwallpaper --zoom ~/.local/share/bg.jpg
wal -c
wal -i ~/.local/share/bg.jpg
xdotool key super+F5

View File

@ -1,17 +0,0 @@
#!/bin/bash
WALL_DIR="$HOME/pix/wallpapers/onedarkwallpapers/"
NEW_WALL=$(find "$WALL_DIR" -type f | shuf -n 1)
if ! pgrep -x hyprpaper >/dev/null; then
# hyprpaper not running → write config and start it
cat > ~/.config/hypr/hyprpaper.conf <<EOF
preload = $NEW_WALL
wallpaper = ,$NEW_WALL
EOF
hyprpaper &
else
# hyprpaper is running → just update it live
hyprctl hyprpaper preload "$NEW_WALL"
hyprctl hyprpaper wallpaper ",$NEW_WALL"
fi

View File

@ -3,9 +3,9 @@
ocr_cmd="wl-copy"
case "$(printf "a selected area (copy)\ncurrent window (copy)\nfull screen (copy)\na selected area\ncurrent window\nfull screen\na selected area (OCR)" | rofi -dmenu -l 7 -i -p "Screenshot which area?")" in
"a selected area (copy)") hyprshot -m region -c ;;
"current window (copy)") hyprshot -m window -c ;;
"full screen (copy)") hyprshot -m output -c ;;
"a selected area (copy)") hyprshot -m region --clipboard-only ;;
"current window (copy)") hyprshot -m window --clipboard-only ;;
"full screen (copy)") hyprshot -m output --clipboard-only ;;
"a selected area") hyprshot -m region -o ~/pix/ss -f "pic-selected-$(uuidgen | awk -F- '{printf $2}')-$(date '+%y-%m-%d').png" ;;
"current window") hyprshot -m window -o ~/pix/ss -f "pic-window-$(uuidgen | awk -F- '{printf $2}')-$(date '+%y-%m-%d').png" ;;

52
.local/bin/setwall Executable file
View File

@ -0,0 +1,52 @@
#!/bin/bash
WALL_DIR="$HOME/pix/wallpapers/onedarkwallpapers/"
MODE="random"
CUSTOM_PATH=""
# Parse options
while getopts ":mp:" opt; do
case $opt in
m) MODE="menu" ;;
p) MODE="path"; CUSTOM_PATH="$OPTARG" ;;
\?) echo "Usage: $0 [-m] [-p /path/to/image]" >&2; exit 1 ;;
:) echo "Option -$OPTARG requires an argument." >&2; exit 1 ;;
esac
done
# Choose wallpaper
case $MODE in
random)
NEW_WALL=$(find "$WALL_DIR" -type f | shuf -n 1)
;;
path)
if [[ -f "$CUSTOM_PATH" ]]; then
NEW_WALL="$CUSTOM_PATH"
else
echo "Error: File not found -> $CUSTOM_PATH" >&2
exit 1
fi
;;
menu)
WALLPAPER_LIST=$(find "$WALL_DIR" -type f | sort | sed "s|$WALL_DIR||")
CHOSEN=$(echo "$WALLPAPER_LIST" | rofi -dmenu -i -p "Choose wallpaper:")
if [[ -z "$CHOSEN" ]]; then
NEW_WALL=$(find "$WALL_DIR" -type f | shuf -n 1)
else
NEW_WALL="$WALL_DIR$CHOSEN"
fi
;;
esac
# Apply wallpaper
if ! pgrep -x hyprpaper >/dev/null; then
# Hyprpaper not running → start with chosen wallpaper
cat > ~/.config/hypr/hyprpaper.conf <<EOF
preload = $NEW_WALL
wallpaper = ,$NEW_WALL
EOF
hyprpaper &
else
# Hyprpaper is running → change it live
hyprctl hyprpaper preload "$NEW_WALL"
hyprctl hyprpaper wallpaper ",$NEW_WALL"
fi