hyprland.conf 10.0 KB

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