dotfiles/mango/config.conf
2026-03-30 20:43:17 +02:00

291 lines
No EOL
12 KiB
Text

# ╔══════════════════════════════════════════════════════════════╗
# ║ MangoWM Config ║
# ║ ~/.config/mango/config.conf ║
# ╚══════════════════════════════════════════════════════════════╝
# ── Environment (NVIDIA-specific) ────────────────────────────
env=GBM_BACKEND,nvidia-drm
env=__GLX_VENDOR_LIBRARY_NAME,nvidia
env=WLR_NO_HARDWARE_CURSORS,1
env=LIBVA_DRIVER_NAME,nvidia-drm
env=XDG_SESSION_TYPE,wayland
env=XDG_CURRENT_DESKTOP,wlroots
env=QT_QPA_PLATFORM,wayland
env=QT_WAYLAND_DISABLE_WINDOWDECORATION,1
env=MOZ_ENABLE_WAYLAND,1
# ── Autostart ────────────────────────────────────────────────
exec-once=bash ~/.config/mango/autostart.sh
# ── General / Miscellaneous ──────────────────────────────────
sloppyfocus=1
smartgaps=0
default_mfact=0.55
default_nmaster=1
new_is_master=0
# ── Appearance ───────────────────────────────────────────────
borderpx=2
gappih=12
gappiv=12
gappoh=12
gappov=12
# ── Scroller Layout (default — like Niri) ────────────────────
# All tags default to scroller via tag rules below
scroller_structs=20
scroller_default_proportion=0.9
scroller_focus_center=0
scroller_prefer_center=1
scroller_prefer_overspread=0
edge_scroller_pointer_focus=1
scroller_proportion_preset=0.5,0.8,1.0
scroller_ignore_proportion_single=1
# ── Animations (full eye candy) ──────────────────────────────
animations=1
layer_animations=1
animation_type_open=zoom
animation_type_close=slide
layer_animation_type_open=slide
layer_animation_type_close=slide
animation_fade_in=1
animation_fade_out=1
fadein_begin_opacity=0.5
fadeout_begin_opacity=0.5
animation_duration_move=350
animation_duration_open=300
animation_duration_tag=250
animation_duration_close=200
animation_duration_focus=0
animation_curve_open=0.22,1.0,0.36,1.0
animation_curve_move=0.22,1.0,0.36,1.0
animation_curve_tag=0.22,1.0,0.36,1.0
animation_curve_close=0.22,1.0,0.36,1.0
tag_animation_direction=1
# ── Window Effects (blur + shadows) ─────────────────────────
blur=1
blur_layer=1
blur_optimized=1
blur_params_radius=6
blur_params_num_passes=2
blur_params_noise=0.02
blur_params_brightness=0.9
blur_params_contrast=0.9
blur_params_saturation=1.1
shadows=1
layer_shadows=0
shadow_only_floating=1
shadows_size=12
shadows_blur=18
shadows_position_x=0
shadows_position_y=2
# ── Tag Rules (all tags default to scroller) ─────────────────
tagrule=id:1,layout_name:scroller
tagrule=id:2,layout_name:scroller
tagrule=id:3,layout_name:scroller
tagrule=id:4,layout_name:scroller
tagrule=id:5,layout_name:scroller
tagrule=id:6,layout_name:scroller
tagrule=id:7,layout_name:scroller
tagrule=id:8,layout_name:scroller
tagrule=id:9,layout_name:scroller
# ── Window Rules ─────────────────────────────────────────────
# Float common game launchers / popups
# windowrule=appid:lutris,float:1
# ── Keyboard ─────────────────────────────────────────────────
xkb_rules_layout=us,sk
repeat_rate=50
repeat_delay=300
xkb_rules_options=grp:caps_toggle
# xkb_rules_options=ctrl:nocaps
# xkb_rules_options=grp:alt_altgr_toggle,caps:hyper
numlockon=0
# ── Trackpad ─────────────────────────────────────────────────
disable_trackpad=0
tap_to_click=1
tap_and_drag=1
drag_lock=1
mouse_natural_scrolling=0
trackpad_natural_scrolling=1
disable_while_typing=1
left_handed=0
middle_button_emulation=0
swipe_min_threshold=1
accel_profile=2
accel_speed=0.2
# scroll_button=274
# scroll_method=1
# ── Monitor (adjust to your setup) ──────────────────────────
# Uncomment and edit for your display:
# monitorrule=name:DP-1,res:2560x1440@165,pos:0x0,scale:1
# ═══════════════════════════════════════════════════════════════
# KEY BINDINGS
# ═══════════════════════════════════════════════════════════════
# ── Essentials ───────────────────────────────────────────────
bind=SUPER,t,spawn,alacritty
bind=SUPER,Return,spawn,alacritty
bind=SUPER,q,killclient
bind=SUPER,d,spawn,fuzzel
bind=SUPER+SHIFT,r,reload_config
bind=SUPER+SHIFT,e,quit
bind=SUPER+SHIFT,q,quit
bind=CTRL+ALT,Delete,quit
bind=SUPER+ALT,l,spawn,waylock
bind=SUPER,v,spawn,sh -c "cliphist list | fuzzel --dmenu --with-nth=2 --width 80 | cliphist decode | wl-copy"
# ── Focus (arrow keys — natural for scroller) ────────────────
bind=SUPER,Left,focusdir,left
bind=SUPER,Right,focusdir,right
bind=SUPER,Up,focusdir,up
bind=SUPER,Down,focusdir,down
# ── Focus (vim keys) ─────────────────────────────────────────
bind=SUPER,h,focusdir,left
bind=SUPER,l,focusdir,right
bind=SUPER,k,focusdir,up
bind=SUPER,j,focusdir,down
# ── Move windows ─────────────────────────────────────────────
bind=SUPER+SHIFT,Left,exchange_client,left
bind=SUPER+SHIFT,Right,exchange_client,right
bind=SUPER+SHIFT,Up,exchange_client,up
bind=SUPER+SHIFT,Down,exchange_client,down
bind=SUPER+SHIFT,h,exchange_client,left
bind=SUPER+SHIFT,l,exchange_client,right
bind=SUPER+SHIFT,k,exchange_client,up
bind=SUPER+SHIFT,j,exchange_client,down
# ── Scroller width cycling ───────────────────────────────────
bind=SUPER,equal,switch_proportion_preset
bind=SUPER,minus,set_proportion,0.5
bind=SUPER,f,togglefullscreen
bind=SUPER+SHIFT,f,togglefakefullscreen
bind=SUPER,m,togglemaximizescreen
# ── Layout switching ─────────────────────────────────────────
bind=SUPER,n,switch_layout
#bind=SUPER,s,setlayout,scroller
#bind=SUPER,t,setlayout,tile
#bind=SUPER,y,setlayout,monocle
# ── Floating ─────────────────────────────────────────────────
bind=SUPER,z,togglefloating
bind=SUPER,c,centerwin
# ── Tags (workspaces) ───────────────────────────────────────
bind=SUPER,1,view,1
bind=SUPER,2,view,2
bind=SUPER,3,view,3
bind=SUPER,4,view,4
bind=SUPER,5,view,5
bind=SUPER,6,view,6
bind=SUPER,7,view,7
bind=SUPER,8,view,8
bind=SUPER,9,view,9
bind=SUPER,0,view,0
# Move window to tag
bind=SUPER+SHIFT,1,tag,1
bind=SUPER+SHIFT,2,tag,2
bind=SUPER+SHIFT,3,tag,3
bind=SUPER+SHIFT,4,tag,4
bind=SUPER+SHIFT,5,tag,5
bind=SUPER+SHIFT,6,tag,6
bind=SUPER+SHIFT,7,tag,7
bind=SUPER+SHIFT,8,tag,8
bind=SUPER+SHIFT,9,tag,9
bind=SUPER+SHIFT,0,toggletag,0
# Quick tag navigation
bind=SUPER,bracketleft,viewtoleft
bind=SUPER,bracketright,viewtoright
bind=SUPER+SHIFT,bracketleft,tagtoleft
bind=SUPER+SHIFT,bracketright,tagtoright
# Workspace navigation (U/I and Page_Up/Down like niri)
bind=SUPER,Page_Down,viewtoright
bind=SUPER,Page_Up,viewtoleft
bind=SUPER,u,viewtoleft
bind=SUPER,i,viewtoright
bind=SUPER+CTRL,Page_Down,tagtoright
bind=SUPER+CTRL,Page_Up,tagtoleft
bind=SUPER+CTRL,u,tagtoleft
bind=SUPER+CTRL,i,tagtoright
# Move window to tag (Ctrl+number like niri)
bind=SUPER+CTRL,1,tag,1
bind=SUPER+CTRL,2,tag,2
bind=SUPER+CTRL,3,tag,3
bind=SUPER+CTRL,4,tag,4
bind=SUPER+CTRL,5,tag,5
bind=SUPER+CTRL,6,tag,6
bind=SUPER+CTRL,7,tag,7
bind=SUPER+CTRL,8,tag,8
bind=SUPER+CTRL,9,tag,9
# ── Monitor focus ────────────────────────────────────────────
bind=SUPER,comma,focusmon,left
bind=SUPER,period,focusmon,right
bind=SUPER+SHIFT,comma,tagmon,left
bind=SUPER+SHIFT,period,tagmon,right
# ── Gaps ─────────────────────────────────────────────────────
bind=SUPER+ALT,equal,incgaps,+2
bind=SUPER+ALT,minus,incgaps,-2
bind=SUPER+ALT,0,togglegaps
# ── Scratchpad ───────────────────────────────────────────────
bind=SUPER,i,minimized
bind=ALT,z,toggle_scratchpad
bind=SUPER+SHIFT,i,restore_minimized
# ── Overview ─────────────────────────────────────────────────
bind=SUPER,Tab,toggleoverview
bind=SUPER,o,toggleoverview
# ── Media keys ───────────────────────────────────────────────
bind=NONE,XF86AudioRaiseVolume,spawn,wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.1+
bind=NONE,XF86AudioLowerVolume,spawn,wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.1-
bind=NONE,XF86AudioMute,spawn,wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle
bind=NONE,XF86AudioMicMute,spawn,wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle
bind=NONE,XF86MonBrightnessUp,spawn,brightnessctl set 10+%
bind=NONE,XF86MonBrightnessDown,spawn,brightnessctl set 10-%
bind=NONE,XF86Display,spawn,wlopm --toggle \*
# ── Screenshots ──────────────────────────────────────────────
bind=NONE,Print,spawn,sh -c 'grim ~/Pictures/Screenshots/$(date +"Screenshot from %Y-%m-%d %H-%M-%S").png'
bind=CTRL,Print,spawn,sh -c 'grim -g "$(slurp)" ~/Pictures/Screenshots/$(date +"Screenshot from %Y-%m-%d %H-%M-%S").png'
bind=ALT,Print,spawn,sh -c 'grim -g "$(slurp)" ~/Pictures/Screenshots/$(date +"Screenshot from %Y-%m-%d %H-%M-%S").png'
bind=SUPER,Print,spawn,sh -c "wl-paste | swappy -f -"
# ── Mouse bindings ───────────────────────────────────────────
mousebind=SUPER,BTN_LEFT,moveresize,move
mousebind=SUPER,BTN_RIGHT,moveresize,resize
# 3-finger: Window focus
gesturebind=none,left,3,focusdir,left
gesturebind=none,right,3,focusdir,right
gesturebind=none,up,3,focusdir,up
gesturebind=none,down,3,focusdir,down
# 4-finger: Workspace navigation
gesturebind=none,left,4,viewtoleft_have_client
gesturebind=none,right,4,viewtoright_have_client
gesturebind=none,up,4,toggleoverview
gesturebind=none,down,4,toggleoverview
# ── Switch Bindings ─────────────────────────────────────────────
switchbind=fold,spawn,swaylock -f -c 000000
switchbind=unfold,spawn,wlr-dpms on