hyprland.conf 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335
  1. monitor=,preferred,auto,auto
  2. ###################
  3. ### MY PROGRAMS ###
  4. ###################
  5. # See https://wiki.hypr.land/Configuring/Keywords/
  6. # source=~/.config/hypr/keybinds.conf
  7. # Set programs that you use
  8. $terminal = wezterm
  9. $fileManager = nautilus
  10. $menu = hyprlauncher
  11. #################
  12. ### AUTOSTART ###
  13. #################
  14. # Autostart necessary processes (like notifications daemons, status bars, etc.)
  15. # Or execute your favorite apps at launch like this:
  16. exec-once = swww-daemon &
  17. exec-once = waybar
  18. # exec-once = $terminal
  19. # exec-once = nm-applet &
  20. # exec-once = waybar & hyprpaper & firefox
  21. #############################
  22. ### ENVIRONMENT VARIABLES ###
  23. #############################
  24. env = XCURSOR_SIZE,24
  25. env = HYPRCURSOR_SIZE,24
  26. ###################
  27. ### PERMISSIONS ###
  28. ###################
  29. ecosystem {
  30. enforce_permissions = 1
  31. }
  32. permission = /usr/bin/grim, screencopy, allow
  33. #####################
  34. ### LOOK AND FEEL ###
  35. #####################
  36. # Refer to https://wiki.hypr.land/Configuring/Variables/
  37. # https://wiki.hypr.land/Configuring/Variables/#general
  38. general {
  39. gaps_in = 5
  40. gaps_out = 20
  41. border_size = 2
  42. # https://wiki.hypr.land/Configuring/Variables/#variable-types for info about colors
  43. col.active_border = rgba(33ccffee) rgba(00ff99ee) 45deg
  44. col.inactive_border = rgba(595959aa)
  45. # Set to true enable resizing windows by clicking and dragging on borders and gaps
  46. resize_on_border = false
  47. allow_tearing = false
  48. layout = master
  49. }
  50. # https://wiki.hypr.land/Configuring/Variables/#decoration
  51. decoration {
  52. rounding = 10
  53. rounding_power = 2
  54. # Change transparency of focused and unfocused windows
  55. active_opacity = 1.0
  56. inactive_opacity = 1.0
  57. shadow {
  58. enabled = true
  59. range = 4
  60. render_power = 3
  61. color = rgba(1a1a1aee)
  62. }
  63. # https://wiki.hypr.land/Configuring/Variables/#blur
  64. blur {
  65. enabled = true
  66. size = 3
  67. passes = 1
  68. vibrancy = 0.1696
  69. }
  70. }
  71. # https://wiki.hypr.land/Configuring/Variables/#animations
  72. animations {
  73. enabled = yes, please :)
  74. # Default curves, see https://wiki.hypr.land/Configuring/Animations/#curves
  75. # NAME, X0, Y0, X1, Y1
  76. bezier = easeOutQuint, 0.23, 1, 0.32, 1
  77. bezier = easeInOutCubic, 0.65, 0.05, 0.36, 1
  78. bezier = linear, 0, 0, 1, 1
  79. bezier = almostLinear, 0.5, 0.5, 0.75, 1
  80. bezier = quick, 0.15, 0, 0.1, 1
  81. # Default animations, see https://wiki.hypr.land/Configuring/Animations/
  82. # NAME, ONOFF, SPEED, CURVE, [STYLE]
  83. animation = global, 1, 10, default
  84. animation = border, 1, 5.39, easeOutQuint
  85. animation = windows, 1, 4.79, easeOutQuint
  86. animation = windowsIn, 1, 4.1, easeOutQuint, popin 87%
  87. animation = windowsOut, 1, 1.49, linear, popin 87%
  88. animation = fadeIn, 1, 1.73, almostLinear
  89. animation = fadeOut, 1, 1.46, almostLinear
  90. animation = fade, 1, 3.03, quick
  91. animation = layers, 1, 3.81, easeOutQuint
  92. animation = layersIn, 1, 4, easeOutQuint, fade
  93. animation = layersOut, 1, 1.5, linear, fade
  94. animation = fadeLayersIn, 1, 1.79, almostLinear
  95. animation = fadeLayersOut, 1, 1.39, almostLinear
  96. animation = workspaces, 1, 1.94, almostLinear, fade
  97. animation = workspacesIn, 1, 1.21, almostLinear, fade
  98. animation = workspacesOut, 1, 1.94, almostLinear, fade
  99. animation = zoomFactor, 1, 7, quick
  100. }
  101. # Ref https://wiki.hypr.land/Configuring/Workspace-Rules/
  102. # "Smart gaps" / "No gaps when only"
  103. # uncomment all if you wish to use that.
  104. # workspace = w[tv1], gapsout:0, gapsin:0
  105. # workspace = f[1], gapsout:0, gapsin:0
  106. # windowrule {
  107. # name = no-gaps-wtv1
  108. # match:float = false
  109. # match:workspace = w[tv1]
  110. #
  111. # border_size = 0
  112. # rounding = 0
  113. # }
  114. #
  115. # windowrule {
  116. # name = no-gaps-f1
  117. # match:float = false
  118. # match:workspace = f[1]
  119. #
  120. # border_size = 0
  121. # rounding = 0
  122. # }
  123. # See https://wiki.hypr.land/Configuring/Dwindle-Layout/ for more
  124. dwindle {
  125. pseudotile = true # Master switch for pseudotiling. Enabling is bound to mainMod + P in the keybinds section below
  126. preserve_split = true # You probably want this
  127. }
  128. # See https://wiki.hypr.land/Configuring/Master-Layout/ for more
  129. master {
  130. new_status = master
  131. }
  132. # https://wiki.hypr.land/Configuring/Variables/#misc
  133. misc {
  134. force_default_wallpaper = -1 # Set to 0 or 1 to disable the anime mascot wallpapers
  135. disable_hyprland_logo = false # If true disables the random hyprland logo / anime girl background. :(
  136. }
  137. #############
  138. ### INPUT ###
  139. #############
  140. # https://wiki.hypr.land/Configuring/Variables/#input
  141. input {
  142. kb_layout = ch
  143. kb_options = caps:swapescape,altwin:swap_lalt_lwin
  144. follow_mouse = 1
  145. sensitivity = 0 # -1.0 - 1.0, 0 means no modification.
  146. touchpad {
  147. natural_scroll = true
  148. }
  149. }
  150. # See https://wiki.hypr.land/Configuring/Gestures
  151. gesture = 3, horizontal, workspace
  152. # Example per-device config
  153. # See https://wiki.hypr.land/Configuring/Keywords/#per-device-input-configs for more
  154. device {
  155. name = epic-mouse-v1
  156. sensitivity = -0.5
  157. }
  158. ###################
  159. ### KEYBINDINGS ###
  160. ###################
  161. # See https://wiki.hypr.land/Configuring/Keywords/
  162. $mainMod = SUPER
  163. bindir = $mainMod, SUPER_L, exec, fuzzel
  164. # Example binds, see https://wiki.hypr.land/Configuring/Binds/ for more
  165. bind = $mainMod, Return, exec, $terminal
  166. bind = $mainMod, Q, killactive,
  167. bind = $mainMod SHIFT, Q, exec, killall Hyprland
  168. bind = $mainMod, M, exec, command -v hyprshutdown >/dev/null 2>&1 && hyprshutdown || hyprctl dispatch exit
  169. bind = $mainMod, E, exec, $fileManager --new-window
  170. bind = $mainMod, V, togglefloating,
  171. bind = $mainMod, R, exec, $menu
  172. bind = $mainMod, P, pseudo, # dwindle
  173. # bind = $mainMod, J, layoutmsg, togglesplit # dwindle
  174. bind = $mainMod ALT, Space, togglefloating,
  175. # Move focus with mainMod + arrow keys
  176. bind = $mainMod, left, movefocus, l
  177. bind = $mainMod, right, movefocus, r
  178. bind = $mainMod, up, movefocus, u
  179. bind = $mainMod, down, movefocus, d
  180. # Swap windows
  181. bind = $mainMod SHIFT, left, movewindow, l
  182. bind = $mainMod SHIFT, right, movewindow, r
  183. bind = $mainMod SHIFT, up, movewindow, u
  184. bind = $mainMod SHIFT, down, movewindow, d
  185. binde = $mainMod, H, splitratio, -0.05
  186. binde = $mainMod, L, splitratio, 0.05
  187. bind = $mainMod, F, fullscreen, 0
  188. # Master Layout Control
  189. bind = $mainMod SHIFT, Return, layoutmsg, swapwithmaster
  190. bind = $mainMod, J, layoutmsg, cyclenext
  191. bind = $mainMod, K, layoutmsg, cycleprev
  192. bind = $mainMod, I, layoutmsg, addmaster
  193. bind = $mainMod, D, layoutmsg, removemaster
  194. # Switch workspaces with mainMod + [0-9]
  195. bind = $mainMod, 1, workspace, 1
  196. bind = $mainMod, 2, workspace, 2
  197. bind = $mainMod, 3, workspace, 3
  198. bind = $mainMod, 4, workspace, 4
  199. bind = $mainMod, 5, workspace, 5
  200. bind = $mainMod, 6, workspace, 6
  201. bind = $mainMod, 7, workspace, 7
  202. bind = $mainMod, 8, workspace, 8
  203. bind = $mainMod, 9, workspace, 9
  204. bind = $mainMod, 0, workspace, 10
  205. # Move active window to a workspace with mainMod + SHIFT + [0-9]
  206. bind = $mainMod SHIFT, 1, movetoworkspace, 1
  207. bind = $mainMod SHIFT, 2, movetoworkspace, 2
  208. bind = $mainMod SHIFT, 3, movetoworkspace, 3
  209. bind = $mainMod SHIFT, 4, movetoworkspace, 4
  210. bind = $mainMod SHIFT, 5, movetoworkspace, 5
  211. bind = $mainMod SHIFT, 6, movetoworkspace, 6
  212. bind = $mainMod SHIFT, 7, movetoworkspace, 7
  213. bind = $mainMod SHIFT, 8, movetoworkspace, 8
  214. bind = $mainMod SHIFT, 9, movetoworkspace, 9
  215. bind = $mainMod SHIFT, 0, movetoworkspace, 10
  216. # Example special workspace (scratchpad)
  217. bind = $mainMod, S, togglespecialworkspace, magic
  218. bind = $mainMod SHIFT, S, movetoworkspace, special:magic
  219. # Scroll through existing workspaces with mainMod + scroll
  220. bind = $mainMod, mouse_down, workspace, e+1
  221. bind = $mainMod, mouse_up, workspace, e-1
  222. # Move/resize windows with mainMod + LMB/RMB and dragging
  223. bindm = $mainMod, mouse:272, movewindow
  224. bindm = $mainMod, mouse:273, resizewindow
  225. # Laptop multimedia keys for volume and LCD brightness
  226. bindel = ,XF86AudioRaiseVolume, exec, wpctl set-volume -l 1 @DEFAULT_AUDIO_SINK@ 5%+
  227. bindel = ,XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-
  228. bindel = ,XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle
  229. bindel = ,XF86AudioMicMute, exec, wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle
  230. bindel = ,XF86MonBrightnessUp, exec, brightnessctl -e4 -n2 set 5%+
  231. bindel = ,XF86MonBrightnessDown, exec, brightnessctl -e4 -n2 set 5%-
  232. # Requires playerctl
  233. bindl = , XF86AudioNext, exec, playerctl next
  234. bindl = , XF86AudioPause, exec, playerctl play-pause
  235. bindl = , XF86AudioPlay, exec, playerctl play-pause
  236. bindl = , XF86AudioPrev, exec, playerctl previous
  237. ##############################
  238. ### WINDOWS AND WORKSPACES ###
  239. ##############################
  240. # See https://wiki.hypr.land/Configuring/Window-Rules/ for more
  241. # See https://wiki.hypr.land/Configuring/Workspace-Rules/ for workspace rules
  242. # Example windowrules that are useful
  243. windowrule {
  244. # Ignore maximize requests from all apps. You'll probably like this.
  245. name = suppress-maximize-events
  246. match:class = .*
  247. suppress_event = maximize
  248. }
  249. windowrule {
  250. # Fix some dragging issues with XWayland
  251. name = fix-xwayland-drags
  252. match:class = ^$
  253. match:title = ^$
  254. match:xwayland = true
  255. match:float = true
  256. match:fullscreen = false
  257. match:pin = false
  258. no_focus = true
  259. }
  260. # Hyprland-run windowrule
  261. windowrule {
  262. name = move-hyprland-run
  263. match:class = hyprland-run
  264. move = 20 monitor_h-120
  265. float = yes
  266. }