# Mouse binds
bindm=SUPER,mouse:272,movewindow
bindm=SUPER,mouse:273,resizewindow

# Basic keybinds
bind=SUPER,Q,killactive,
bind=SUPERCTRL,R,exec, pkill waybar || waybar
bind=SUPERCTRL,M,exit,
bind=SUPER,A,togglefloating,
bind=SUPER,P,pseudo,
bind=SUPER,F,fullscreen,0
bind=SUPER,Z,exec,pypr zoom

## Applications
bind=SUPER,W,exec,librewolf # Numpad dot
bind=SUPER,22,exec,neovide # Return key
bind=SUPER,O,exec,obsidian

# Nemo
bind=SUPER,M,exec,nemo # Numpad 0
bind=SUPER,87,exec,nemo ~/Descargas # Numpad 1
bind=SUPER,88,exec,nemo /docs/Documentos # Numpad 2
bind=SUPER,89,exec,nemo ~/Imagenes # Numpad 3
bind=SUPER,83,exec,nemo ~/Musica # Numpad 4
bind=SUPER,84,exec,nemo ~/Repos # Numpad 5
bind=SUPER,85,exec,nemo ~/Videos # Numpad 6
bind=SUPER,79,exec,nemo /vm # Numpad 7
bind=SUPER,80,exec,nemo ~/Juegos # Numpad 8
bind=SUPER,81,exec,nemo ~/.config # Numpad 9

# Kitty
bind=SUPER,RETURN,exec,kitty
bind=SUPERSHIFT,87,exec,kitty ~/Descargas # Numpad 1
bind=SUPERSHIFT,88,exec,kitty /docs/Documentos # Numpad 2
bind=SUPERSHIFT,89,exec,kitty ~/Imagenes # Numpad 3
bind=SUPERSHIFT,83,exec,kitty ~/Musica # Numpad 4
bind=SUPERSHIFT,84,exec,kitty ~/Repos # Numpad 5
bind=SUPERSHIFT,85,exec,kitty ~/Videos # Numpad 6
bind=SUPERSHIFT,79,exec,kitty /vm # Numpad 7
bind=SUPERSHIFT,80,exec,kitty ~/Juegos # Numpad 8
bind=SUPERSHIFT,81,exec,kitty ~/.config # Numpad 9

# Launchers
bind=SUPER, 23, exec, rofi -show drun -theme ~/.config/rofi/style.rasi # Space key

# Scratchpads
bind=SUPER,V,exec,pypr toggle volume

# Screenshotting
bind=SHIFT,Insert,exec, hyprshot -m output -o ~/Imagenes/Capturas/PC -f captura-$(date +'%Y-%m-%d-%s').png
bind=SUPERSHIFT,Insert,exec, hyprshot -m window -o ~/Imagenes/Capturas/PC -f captura-$(date +'%Y-%m-%d-%s').png
bind=CTRL,Insert,exec, hyprshot -m region -o ~/Imagenes/Capturas/PC -f captura-$(date +'%Y-%m-%d-%s').png
bind=ALT,Insert,exec, ~/.config/hypr/scripts/rofi/screenshots_selection

# Clipboard
bind=SUPER,c,exec, cliphist list | rofi -dmenu -theme ~/.config/rofi/style.rasi | cliphist decode | wl-copy

# Logout menu
bind=SUPER, escape, exec, wleave

# Color picker
bind=SUPER,Insert,exec, ~/.config/hypr/scripts/color_picker

# Wallpaper
bind=SUPERSHIFT,w,exec, ~/.config/hypr/scripts/wallpaper select

# Keybindings Cheatsheet
bind=SUPER,i,exec, ~/.config/hypr/scripts/rofi/keybindings

# Recording
bind=SUPERSHIFT,r,exec, ~/.config/hypr/scripts/rofi/recording

## Windows
## Focusing on windows
bind=SUPER,left,movefocus,l
bind=SUPER,right,movefocus,r
bind=SUPER,up,movefocus,u
bind=SUPER,down,movefocus,d
# Vim-keybinds
bind=SUPER,h,movefocus,l
bind=SUPER,l,movefocus,r
bind=SUPER,k,movefocus,u
bind=SUPER,j,movefocus,d

## Moving windows
bind=SUPERSHIFT,left,movewindow,l
bind=SUPERSHIFT,right,movewindow,r
bind=SUPERSHIFT,up,movewindow,u
bind=SUPERSHIFT,down,movewindow,d
# Vim-keybinds
bind=SUPERSHIFT,h,movewindow,l
bind=SUPERSHIFT,l,movewindow,r
bind=SUPERSHIFT,k,movewindow,u
bind=SUPERSHIFT,j,movewindow,d

## Workspaces
# Focusing other workspaces
bind=SUPER,1,exec,hyprsome workspace 1
bind=SUPER,2,exec,hyprsome workspace 2
bind=SUPER,3,exec,hyprsome workspace 3
bind=SUPER,4,exec,hyprsome workspace 4
bind=SUPER,5,exec,hyprsome workspace 5
bind=SUPER,6,exec,hyprsome workspace 6
bind=SUPER,7,exec,hyprsome workspace 7
bind=SUPER,8,exec,hyprsome workspace 8
bind=SUPER,9,exec,hyprsome workspace 9
bind=SUPER,0,exec,hyprsome workspace 10

# Moving windows to other workspaces
bind=SUPERSHIFT,1,exec,hyprsome move 1
bind=SUPERSHIFT,2,exec,hyprsome move 2
bind=SUPERSHIFT,3,exec,hyprsome move 3
bind=SUPERSHIFT,4,exec,hyprsome move 4
bind=SUPERSHIFT,5,exec,hyprsome move 5
bind=SUPERSHIFT,6,exec,hyprsome move 6
bind=SUPERSHIFT,7,exec,hyprsome move 7
bind=SUPERSHIFT,8,exec,hyprsome move 8
bind=SUPERSHIFT,9,exec,hyprsome move 9
bind=SUPERSHIFT,0,exec,hyprsome move 10

# Moving windows to other workspaces (silent)
bind=SUPERALT,1,exec,hyprsome movetoworkspacesilent 1
bind=SUPERALT,2,exec,hyprsome movetoworkspacesilent 2
bind=SUPERALT,3,exec,hyprsome movetoworkspacesilent 3
bind=SUPERALT,4,exec,hyprsome movetoworkspacesilent 4
bind=SUPERALT,5,exec,hyprsome movetoworkspacesilent 5
bind=SUPERALT,6,exec,hyprsome movetoworkspacesilent 6
bind=SUPERALT,7,exec,hyprsome movetoworkspacesilent 7
bind=SUPERALT,8,exec,hyprsome movetoworkspacesilent 8
bind=SUPERALT,9,exec,hyprsome movetoworkspacesilent 9
bind=SUPERALT,0,exec,hyprsome movetoworkspacesilent 10

# Moving to other wokspace with mouse control
bind=SUPER,mouse_down,workspace,m-1
bind=SUPER,mouse_up,workspace,m+1

# Moving to other wokspace with keyboard
bind=SUPERCTRL,LEFT,workspace,m-1
bind=SUPERCTRL,RIGHT,workspace,m+1

bind=SUPERCTRL,h,workspace,m-1
bind=SUPERCTRL,l,workspace,m+1

# Group control
bind =SUPER, S, togglesplit
bind=SUPER,G,togglegroup
bind=ALT,tab,changegroupactive

# Submap for resizing windows
bind=SUPER,R,submap,resize
submap=resize

binde=,right,resizeactive,20 0
binde=,left,resizeactive,-20 0
binde=,up,resizeactive,0 -20
binde=,down,resizeactive,0 20

binde=,l,resizeactive,20 0
binde=,h,resizeactive,-20 0
binde=,k,resizeactive,0 -20
binde=,j,resizeactive,0 20

bind=,escape,submap,reset 

submap=reset

## Audio
bind=SUPERCTRL,V,exec,restartAudio
#bind=,XF86AudioPlay,exec,playerctl play-pause
bindl=SUPERCTRL,mouse:274,exec,playerctl play-pause
#bind=,XF86AudioPrev,exec,playerctl previous
bindl=SUPERCTRL,mouse_up,exec,playerctl previous
#bind=,XF86AudioNext,exec,playerctl next
bindl=SUPERCTRL,mouse_down,exec,playerctl next

bindl=,XF86AudioMedia,exec,playerctl play-pause
bindl=,XF86AudioStop,exec,playerctl stop

bindle=,XF86AudioRaiseVolume,exec,swayosd --output-volume raise
bindle=,XF86AudioLowerVolume,exec,swayosd --output-volume lower

bindle=,XF86AudioMute,exec,swayosd --output-volume mute-toggle
bindle=,XF86AudioMicMute,exec,exec swayosd --input-volume mute-toggle
