From 006f840b2cfd0185131f7261365e87674299ec4e Mon Sep 17 00:00:00 2001 From: a Date: Wed, 13 May 2026 13:30:41 -0700 Subject: [PATCH] asdf --- .gitignore | 1 + configuration.nix | 68 +++ flake.lock | 514 +++++++++++++++++++ flake.nix | 22 + foot/foot.ini | 32 ++ hypr/.luarc.json | 10 + hypr/hl.meta.lua | 1252 +++++++++++++++++++++++++++++++++++++++++++++ hypr/hyprland.lua | 269 ++++++++++ 8 files changed, 2168 insertions(+) create mode 100644 .gitignore create mode 100644 configuration.nix create mode 100644 flake.lock create mode 100644 flake.nix create mode 100644 foot/foot.ini create mode 100644 hypr/.luarc.json create mode 100644 hypr/hl.meta.lua create mode 100644 hypr/hyprland.lua diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..f0c70fb --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +hardware* diff --git a/configuration.nix b/configuration.nix new file mode 100644 index 0000000..fa5902a --- /dev/null +++ b/configuration.nix @@ -0,0 +1,68 @@ +{ + config, + lib, + pkgs, + inputs, + ... +}: { + imports = [ + ./hardware-configuration.nix + ]; + + boot.loader.systemd-boot.enable = true; + boot.loader.efi.canTouchEfiVariables = true; + networking.hostName = "nixos-btw"; + networking.networkmanager.enable = true; + services = { + displayManager = { + ly.enable = true; + }; + }; + + time.timeZone = "America/Los_Angeles"; + users.users.tony = { + isNormalUser = true; + extraGroups = ["wheel"]; + }; + programs.firefox.enable = true; + environment.systemPackages = with pkgs; [ + tree + vis + git + foot + neovim + gcc + lua-language-server + nil + alejandra + vim + wget + adwaita-icon-theme + gnome-themes-extra + nitch + thunar + rofi + swaybg + ]; + + programs.hyprland = { + enable = true; + xwayland.enable = true; + package = inputs.hyprland.packages.${pkgs.system}.hyprland; + portalPackage = inputs.hyprland.packages.${pkgs.system}.xdg-desktop-portal-hyprland; + }; + + nix.settings = { + experimental-features = ["nix-command" "flakes"]; + download-buffer-size = 268435456; + trusted-users = ["root" "tony"]; + extra-substituters = ["https://hyprland.cachix.org"]; + extra-trusted-public-keys = ["hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="]; + }; + + fonts.packages = with pkgs; [ + nerd-fonts.iosevka + ]; + + system.stateVersion = "25.11"; +} diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..96b75ff --- /dev/null +++ b/flake.lock @@ -0,0 +1,514 @@ +{ + "nodes": { + "aquamarine": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1777499565, + "narHash": "sha256-nU55VWk99Pn1QzQDDjFISocC4SgDZ3Xp+zb6ji3JclM=", + "owner": "hyprwm", + "repo": "aquamarine", + "rev": "813c1e8981893c11e118b19c125d6bc282f51765", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "aquamarine", + "type": "github" + } + }, + "flake-compat": { + "flake": false, + "locked": { + "lastModified": 1767039857, + "narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=", + "owner": "NixOS", + "repo": "flake-compat", + "rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab", + "type": "github" + }, + "original": { + "owner": "NixOS", + "repo": "flake-compat", + "type": "github" + } + }, + "gitignore": { + "inputs": { + "nixpkgs": [ + "hyprland", + "pre-commit-hooks", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1709087332, + "narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=", + "owner": "hercules-ci", + "repo": "gitignore.nix", + "rev": "637db329424fd7e46cf4185293b9cc8c88c95394", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "gitignore.nix", + "type": "github" + } + }, + "hyprcursor": { + "inputs": { + "hyprlang": [ + "hyprland", + "hyprlang" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1776511930, + "narHash": "sha256-fCpwFiTW0rT7oKJqr3cqHMnkwypSwQKpbtUEtxdkgrM=", + "owner": "hyprwm", + "repo": "hyprcursor", + "rev": "39435900785d0c560c6ae8777d29f28617d031ef", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprcursor", + "type": "github" + } + }, + "hyprgraphics": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1776426399, + "narHash": "sha256-RUESLKNikIeEq9ymGJ6nmcDXiSFQpUW1IhJ245nL3xM=", + "owner": "hyprwm", + "repo": "hyprgraphics", + "rev": "68d064434787cf1ed4a2fe257c03c5f52f33cf84", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprgraphics", + "type": "github" + } + }, + "hyprland": { + "inputs": { + "aquamarine": "aquamarine", + "hyprcursor": "hyprcursor", + "hyprgraphics": "hyprgraphics", + "hyprland-guiutils": "hyprland-guiutils", + "hyprland-protocols": "hyprland-protocols", + "hyprlang": "hyprlang", + "hyprutils": "hyprutils", + "hyprwayland-scanner": "hyprwayland-scanner", + "hyprwire": "hyprwire", + "nixpkgs": "nixpkgs", + "pre-commit-hooks": "pre-commit-hooks", + "systems": "systems", + "xdph": "xdph" + }, + "locked": { + "lastModified": 1778333727, + "narHash": "sha256-RGYGbW6aH3jUwGVB9BrSYcKsQj7Dl2K32ao5aWbTK40=", + "owner": "hyprwm", + "repo": "Hyprland", + "rev": "af923e30d1d24f1f4a4f5cb8308065173c1d9539", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "ref": "v0.55.0", + "repo": "Hyprland", + "type": "github" + } + }, + "hyprland-guiutils": { + "inputs": { + "aquamarine": [ + "hyprland", + "aquamarine" + ], + "hyprgraphics": [ + "hyprland", + "hyprgraphics" + ], + "hyprlang": [ + "hyprland", + "hyprlang" + ], + "hyprtoolkit": "hyprtoolkit", + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1776426575, + "narHash": "sha256-KI6nIfVihn/DPaeB5Et46Xg3dkNHrrEtUd5LBBVomB0=", + "owner": "hyprwm", + "repo": "hyprland-guiutils", + "rev": "a968d211048e3ed538e47b84cb3649299578f19d", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprland-guiutils", + "type": "github" + } + }, + "hyprland-protocols": { + "inputs": { + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1772460177, + "narHash": "sha256-/6G/MsPvtn7bc4Y32pserBT/Z4SUUdBd4XYJpOEKVR4=", + "owner": "hyprwm", + "repo": "hyprland-protocols", + "rev": "1cb6db5fd6bb8aee419f4457402fa18293ace917", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprland-protocols", + "type": "github" + } + }, + "hyprlang": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1777320127, + "narHash": "sha256-Qu+Wf2Bp5qUjyn2YpZNq8a7JyzTGowhT1knrwE38a9U=", + "owner": "hyprwm", + "repo": "hyprlang", + "rev": "090117506ddc3d7f26e650ff344d378c2ec329cc", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprlang", + "type": "github" + } + }, + "hyprtoolkit": { + "inputs": { + "aquamarine": [ + "hyprland", + "hyprland-guiutils", + "aquamarine" + ], + "hyprgraphics": [ + "hyprland", + "hyprland-guiutils", + "hyprgraphics" + ], + "hyprlang": [ + "hyprland", + "hyprland-guiutils", + "hyprlang" + ], + "hyprutils": [ + "hyprland", + "hyprland-guiutils", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprland-guiutils", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "hyprland-guiutils", + "nixpkgs" + ], + "systems": [ + "hyprland", + "hyprland-guiutils", + "systems" + ] + }, + "locked": { + "lastModified": 1772462885, + "narHash": "sha256-5pHXrQK9zasMnIo6yME6EOXmWGFMSnCITcfKshhKJ9I=", + "owner": "hyprwm", + "repo": "hyprtoolkit", + "rev": "9af245a69fa6b286b88ddfc340afd288e00a6998", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprtoolkit", + "type": "github" + } + }, + "hyprutils": { + "inputs": { + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1778234770, + "narHash": "sha256-jAcsogZwWMfXT9MfXxZzkwliAqIuZUV0p71h6Ba9ReE=", + "owner": "hyprwm", + "repo": "hyprutils", + "rev": "a2dbd8a4cc51f7cbe4224732668392bb1aa79df2", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprutils", + "type": "github" + } + }, + "hyprwayland-scanner": { + "inputs": { + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1777159683, + "narHash": "sha256-Jxixw6wZphUp+nHYxOKUYSckL17QMBx2d5Zp0rJHr1g=", + "owner": "hyprwm", + "repo": "hyprwayland-scanner", + "rev": "b8632713a6beaf28b56f2a7b0ab2fb7088dbb404", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprwayland-scanner", + "type": "github" + } + }, + "hyprwire": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1777388329, + "narHash": "sha256-40YxVGF2rA9iH3D7am5fy4EOSBbMgpJtJ9yhl0Cx+qI=", + "owner": "hyprwm", + "repo": "hyprwire", + "rev": "04be2897e05f9b271d532b5ae56ca088d2eeac02", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprwire", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1777954456, + "narHash": "sha256-hGdgeU2Nk87RAuZyYjyDjFL6LK7dAZN5RE9+hrDTkDU=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "549bd84d6279f9852cae6225e372cc67fb91a4c1", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_2": { + "locked": { + "lastModified": 1778443072, + "narHash": "sha256-zi7/fsqM/kFdNuED//4WOCUtezGtKKqRNORjMvfwjnA=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "da5ad661ba4e5ef59ba743f0d112cbc30e474f32", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "pre-commit-hooks": { + "inputs": { + "flake-compat": "flake-compat", + "gitignore": "gitignore", + "nixpkgs": [ + "hyprland", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1776796298, + "narHash": "sha256-PcRvlWayisPSjd0UcRQbhG8Oqw78AcPE6x872cPRHN8=", + "owner": "cachix", + "repo": "git-hooks.nix", + "rev": "3cfd774b0a530725a077e17354fbdb87ea1c4aad", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "git-hooks.nix", + "type": "github" + } + }, + "root": { + "inputs": { + "hyprland": "hyprland", + "nixpkgs": "nixpkgs_2" + } + }, + "systems": { + "locked": { + "lastModified": 1689347949, + "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", + "owner": "nix-systems", + "repo": "default-linux", + "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default-linux", + "type": "github" + } + }, + "xdph": { + "inputs": { + "hyprland-protocols": [ + "hyprland", + "hyprland-protocols" + ], + "hyprlang": [ + "hyprland", + "hyprlang" + ], + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1777585783, + "narHash": "sha256-JTeWRy42VElroJ0rVdZuVXSoTLsx+NzQfGPKMbtn3SU=", + "owner": "hyprwm", + "repo": "xdg-desktop-portal-hyprland", + "rev": "fa50d6fbaff8f42c61071b87b034a90d82a33558", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "xdg-desktop-portal-hyprland", + "type": "github" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..adcc925 --- /dev/null +++ b/flake.nix @@ -0,0 +1,22 @@ +{ + description = "Nix Hyprland Lua, btw."; + inputs = { + nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; + hyprland.url = "github:hyprwm/Hyprland/v0.55.0"; + }; + outputs = inputs @ { + self, + nixpkgs, + hyprland, + ... + }: { + nixosConfigurations.nixos-btw = nixpkgs.lib.nixosSystem { + system = "x86_64-linux"; + specialArgs = {inherit inputs;}; + modules = [ + ./configuration.nix + ./hardware-configuration.nix + ]; + }; + }; +} diff --git a/foot/foot.ini b/foot/foot.ini new file mode 100644 index 0000000..dfeb25d --- /dev/null +++ b/foot/foot.ini @@ -0,0 +1,32 @@ +font=Iosevka NF:size=24 +pad=4x4 + +[colors-dark] +foreground=c0caf5 +background=1a1b26 + +## Normal/regular colors (color palette 0-7) +regular0=15161E # black +regular1=f7768e # red +regular2=9ece6a # green +regular3=e0af68 # yellow +regular4=7aa2f7 # blue +regular5=bb9af7 # magenta +regular6=7dcfff # cyan +regular7=a9b1d6 # white + +## Bright colors (color palette 8-15) +bright0=414868 # bright black +bright1=f7768e # bright red +bright2=9ece6a # bright green +bright3=e0af68 # bright yellow +bright4=7aa2f7 # bright blue +bright5=bb9af7 # bright magenta +bright6=7dcfff # bright cyan +bright7=c0caf5 # bright white + +## dimmed colors (see foot.ini(5) man page) +dim0=ff9e64 +dim1=db4b4b + +alpha=0.9 diff --git a/hypr/.luarc.json b/hypr/.luarc.json new file mode 100644 index 0000000..7a8f4af --- /dev/null +++ b/hypr/.luarc.json @@ -0,0 +1,10 @@ +{ + "workspace": { + "library": [ + "/home/tony/.config/hypr" + ] + }, + "diagnostics": { + "globals": ["hl"] + } +} diff --git a/hypr/hl.meta.lua b/hypr/hl.meta.lua new file mode 100644 index 0000000..76fc923 --- /dev/null +++ b/hypr/hl.meta.lua @@ -0,0 +1,1252 @@ +-- This file is autogenerated. Do not edit by hand. +-- Generator: scripts/generateLuaStubs.py +---@meta + +---@alias HL.EventName +---| "config.reloaded" +---| "hyprland.shutdown" +---| "hyprland.start" +---| "keybinds.submap" +---| "layer.closed" +---| "layer.opened" +---| "monitor.added" +---| "monitor.focused" +---| "monitor.layout_changed" +---| "monitor.removed" +---| "screenshare.state" +---| "window.active" +---| "window.class" +---| "window.close" +---| "window.destroy" +---| "window.fullscreen" +---| "window.kill" +---| "window.move_to_workspace" +---| "window.open" +---| "window.open_early" +---| "window.pin" +---| "window.title" +---| "window.update_rules" +---| "window.urgent" +---| "workspace.active" +---| "workspace.created" +---| "workspace.move_to_monitor" +---| "workspace.removed" + +---@alias HL.ConfigKey +---| "animations.enabled" +---| "animations.workspace_wraparound" +---| "binds.allow_pin_fullscreen" +---| "binds.allow_workspace_cycles" +---| "binds.disable_keybind_grabbing" +---| "binds.drag_threshold" +---| "binds.focus_preferred_method" +---| "binds.hide_special_on_workspace_change" +---| "binds.ignore_group_lock" +---| "binds.movefocus_cycles_fullscreen" +---| "binds.movefocus_cycles_groupfirst" +---| "binds.pass_mouse_when_bound" +---| "binds.scroll_event_delay" +---| "binds.window_direction_monitor_fallback" +---| "binds.workspace_back_and_forth" +---| "binds.workspace_center_on" +---| "cursor.default_monitor" +---| "cursor.enable_hyprcursor" +---| "cursor.hide_on_key_press" +---| "cursor.hide_on_tablet" +---| "cursor.hide_on_touch" +---| "cursor.hotspot_padding" +---| "cursor.inactive_timeout" +---| "cursor.invisible" +---| "cursor.min_refresh_rate" +---| "cursor.no_break_fs_vrr" +---| "cursor.no_hardware_cursors" +---| "cursor.no_warps" +---| "cursor.persistent_warps" +---| "cursor.sync_gsettings_theme" +---| "cursor.use_cpu_buffer" +---| "cursor.warp_back_after_non_mouse_input" +---| "cursor.warp_on_change_workspace" +---| "cursor.warp_on_toggle_special" +---| "cursor.zoom_detached_camera" +---| "cursor.zoom_disable_aa" +---| "cursor.zoom_factor" +---| "cursor.zoom_rigid" +---| "debug.colored_stdout_logs" +---| "debug.damage_blink" +---| "debug.damage_tracking" +---| "debug.disable_logs" +---| "debug.disable_scale_checks" +---| "debug.disable_time" +---| "debug.ds_handle_same_buffer" +---| "debug.ds_handle_same_buffer_fifo" +---| "debug.enable_stdout_logs" +---| "debug.error_limit" +---| "debug.error_position" +---| "debug.fifo_pending_workaround" +---| "debug.full_cm_proto" +---| "debug.gl_debugging" +---| "debug.invalidate_fp16" +---| "debug.log_damage" +---| "debug.manual_crash" +---| "debug.overlay" +---| "debug.pass" +---| "debug.render_solitary_wo_damage" +---| "debug.suppress_errors" +---| "debug.vfr" +---| "decoration.active_opacity" +---| "decoration.blur.brightness" +---| "decoration.blur.contrast" +---| "decoration.blur.enabled" +---| "decoration.blur.ignore_opacity" +---| "decoration.blur.input_methods" +---| "decoration.blur.input_methods_ignorealpha" +---| "decoration.blur.new_optimizations" +---| "decoration.blur.noise" +---| "decoration.blur.passes" +---| "decoration.blur.popups" +---| "decoration.blur.popups_ignorealpha" +---| "decoration.blur.size" +---| "decoration.blur.special" +---| "decoration.blur.vibrancy" +---| "decoration.blur.vibrancy_darkness" +---| "decoration.blur.xray" +---| "decoration.border_part_of_window" +---| "decoration.dim_around" +---| "decoration.dim_inactive" +---| "decoration.dim_modal" +---| "decoration.dim_special" +---| "decoration.dim_strength" +---| "decoration.fullscreen_opacity" +---| "decoration.glow.color" +---| "decoration.glow.color_inactive" +---| "decoration.glow.enabled" +---| "decoration.glow.range" +---| "decoration.glow.render_power" +---| "decoration.inactive_opacity" +---| "decoration.rounding" +---| "decoration.rounding_power" +---| "decoration.screen_shader" +---| "decoration.shadow.color" +---| "decoration.shadow.color_inactive" +---| "decoration.shadow.enabled" +---| "decoration.shadow.offset" +---| "decoration.shadow.range" +---| "decoration.shadow.render_power" +---| "decoration.shadow.scale" +---| "decoration.shadow.sharp" +---| "dwindle.default_split_ratio" +---| "dwindle.force_split" +---| "dwindle.permanent_direction_override" +---| "dwindle.precise_mouse_move" +---| "dwindle.preserve_split" +---| "dwindle.smart_resizing" +---| "dwindle.smart_split" +---| "dwindle.special_scale_factor" +---| "dwindle.split_bias" +---| "dwindle.split_width_multiplier" +---| "dwindle.use_active_for_splits" +---| "ecosystem.enforce_permissions" +---| "ecosystem.no_donation_nag" +---| "ecosystem.no_update_news" +---| "experimental.wp_cm_1_2" +---| "general.allow_tearing" +---| "general.border_size" +---| "general.col.active_border" +---| "general.col.inactive_border" +---| "general.col.nogroup_border" +---| "general.col.nogroup_border_active" +---| "general.extend_border_grab_area" +---| "general.float_gaps" +---| "general.gaps_in" +---| "general.gaps_out" +---| "general.gaps_workspaces" +---| "general.hover_icon_on_border" +---| "general.layout" +---| "general.locale" +---| "general.modal_parent_blocking" +---| "general.no_focus_fallback" +---| "general.resize_corner" +---| "general.resize_on_border" +---| "general.snap.border_overlap" +---| "general.snap.enabled" +---| "general.snap.monitor_gap" +---| "general.snap.respect_gaps" +---| "general.snap.window_gap" +---| "gestures.close_max_timeout" +---| "gestures.scrolling.move_snap_cursor" +---| "gestures.scrolling.move_snap_to_grid" +---| "gestures.workspace_swipe_cancel_ratio" +---| "gestures.workspace_swipe_create_new" +---| "gestures.workspace_swipe_direction_lock" +---| "gestures.workspace_swipe_direction_lock_threshold" +---| "gestures.workspace_swipe_distance" +---| "gestures.workspace_swipe_forever" +---| "gestures.workspace_swipe_invert" +---| "gestures.workspace_swipe_min_speed_to_force" +---| "gestures.workspace_swipe_touch" +---| "gestures.workspace_swipe_touch_invert" +---| "gestures.workspace_swipe_use_r" +---| "group.auto_group" +---| "group.col.border_active" +---| "group.col.border_inactive" +---| "group.col.border_locked_active" +---| "group.col.border_locked_inactive" +---| "group.drag_into_group" +---| "group.focus_removed_window" +---| "group.group_on_movetoworkspace" +---| "group.groupbar.blur" +---| "group.groupbar.col.active" +---| "group.groupbar.col.inactive" +---| "group.groupbar.col.locked_active" +---| "group.groupbar.col.locked_inactive" +---| "group.groupbar.enabled" +---| "group.groupbar.font_family" +---| "group.groupbar.font_size" +---| "group.groupbar.font_weight_active" +---| "group.groupbar.font_weight_inactive" +---| "group.groupbar.gaps_in" +---| "group.groupbar.gaps_out" +---| "group.groupbar.gradient_round_only_edges" +---| "group.groupbar.gradient_rounding" +---| "group.groupbar.gradient_rounding_power" +---| "group.groupbar.gradients" +---| "group.groupbar.height" +---| "group.groupbar.indicator_gap" +---| "group.groupbar.indicator_height" +---| "group.groupbar.keep_upper_gap" +---| "group.groupbar.middle_click_close" +---| "group.groupbar.priority" +---| "group.groupbar.render_titles" +---| "group.groupbar.round_only_edges" +---| "group.groupbar.rounding" +---| "group.groupbar.rounding_power" +---| "group.groupbar.scrolling" +---| "group.groupbar.stacked" +---| "group.groupbar.text_color" +---| "group.groupbar.text_color_inactive" +---| "group.groupbar.text_color_locked_active" +---| "group.groupbar.text_color_locked_inactive" +---| "group.groupbar.text_offset" +---| "group.groupbar.text_padding" +---| "group.insert_after_current" +---| "group.merge_floated_into_tiled_on_groupbar" +---| "group.merge_groups_on_drag" +---| "group.merge_groups_on_groupbar" +---| "input.accel_profile" +---| "input.emulate_discrete_scroll" +---| "input.float_switch_override_focus" +---| "input.focus_on_close" +---| "input.follow_mouse" +---| "input.follow_mouse_shrink" +---| "input.follow_mouse_threshold" +---| "input.force_no_accel" +---| "input.kb_file" +---| "input.kb_layout" +---| "input.kb_model" +---| "input.kb_options" +---| "input.kb_rules" +---| "input.kb_variant" +---| "input.left_handed" +---| "input.mouse_refocus" +---| "input.natural_scroll" +---| "input.numlock_by_default" +---| "input.off_window_axis_events" +---| "input.repeat_delay" +---| "input.repeat_rate" +---| "input.resolve_binds_by_sym" +---| "input.rotation" +---| "input.scroll_button" +---| "input.scroll_button_lock" +---| "input.scroll_factor" +---| "input.scroll_method" +---| "input.scroll_points" +---| "input.sensitivity" +---| "input.special_fallthrough" +---| "input.tablet.absolute_region_position" +---| "input.tablet.active_area_position" +---| "input.tablet.active_area_size" +---| "input.tablet.left_handed" +---| "input.tablet.output" +---| "input.tablet.region_position" +---| "input.tablet.region_size" +---| "input.tablet.relative_input" +---| "input.tablet.transform" +---| "input.touchdevice.enabled" +---| "input.touchdevice.output" +---| "input.touchdevice.transform" +---| "input.touchpad.clickfinger_behavior" +---| "input.touchpad.disable_while_typing" +---| "input.touchpad.drag_3fg" +---| "input.touchpad.drag_lock" +---| "input.touchpad.flip_x" +---| "input.touchpad.flip_y" +---| "input.touchpad.middle_button_emulation" +---| "input.touchpad.natural_scroll" +---| "input.touchpad.scroll_factor" +---| "input.touchpad.tap_and_drag" +---| "input.touchpad.tap_button_map" +---| "input.touchpad.tap_to_click" +---| "input.virtualkeyboard.release_pressed_on_close" +---| "input.virtualkeyboard.share_states" +---| "layout.single_window_aspect_ratio" +---| "layout.single_window_aspect_ratio_tolerance" +---| "master.allow_small_split" +---| "master.always_keep_position" +---| "master.center_ignores_reserved" +---| "master.center_master_fallback" +---| "master.drop_at_cursor" +---| "master.focus_master_on_close" +---| "master.mfact" +---| "master.new_on_active" +---| "master.new_on_top" +---| "master.new_status" +---| "master.orientation" +---| "master.slave_count_for_center_master" +---| "master.smart_resizing" +---| "master.special_scale_factor" +---| "misc.allow_session_lock_restore" +---| "misc.always_follow_on_dnd" +---| "misc.animate_manual_resizes" +---| "misc.animate_mouse_windowdragging" +---| "misc.anr_missed_pings" +---| "misc.background_color" +---| "misc.close_special_on_empty" +---| "misc.col.splash" +---| "misc.disable_autoreload" +---| "misc.disable_hyprland_guiutils_check" +---| "misc.disable_hyprland_logo" +---| "misc.disable_scale_notification" +---| "misc.disable_splash_rendering" +---| "misc.disable_watchdog_warning" +---| "misc.disable_xdg_env_checks" +---| "misc.enable_anr_dialog" +---| "misc.enable_swallow" +---| "misc.exit_window_retains_fullscreen" +---| "misc.focus_on_activate" +---| "misc.font_family" +---| "misc.force_default_wallpaper" +---| "misc.initial_workspace_tracking" +---| "misc.key_press_enables_dpms" +---| "misc.layers_hog_keyboard_focus" +---| "misc.lockdead_screen_delay" +---| "misc.middle_click_paste" +---| "misc.mouse_move_enables_dpms" +---| "misc.mouse_move_focuses_monitor" +---| "misc.name_vk_after_proc" +---| "misc.on_focus_under_fullscreen" +---| "misc.render_unfocused_fps" +---| "misc.screencopy_force_8b" +---| "misc.session_lock_xray" +---| "misc.size_limits_tiled" +---| "misc.splash_font_family" +---| "misc.swallow_exception_regex" +---| "misc.swallow_regex" +---| "misc.vrr" +---| "opengl.nvidia_anti_flicker" +---| "quirks.prefer_hdr" +---| "quirks.skip_non_kms_dmabuf_formats" +---| "render.cm_auto_hdr" +---| "render.cm_enabled" +---| "render.cm_sdr_eotf" +---| "render.commit_timing_enabled" +---| "render.ctm_animation" +---| "render.direct_scanout" +---| "render.expand_undersized_textures" +---| "render.fp16_sdr_tf" +---| "render.icc_vcgt_enabled" +---| "render.keep_unmodified_copy" +---| "render.new_render_scheduling" +---| "render.non_shader_cm" +---| "render.non_shader_cm_interop" +---| "render.send_content_type" +---| "render.use_fp16" +---| "render.use_shader_blur_blend" +---| "render.xp_mode" +---| "scrolling.column_width" +---| "scrolling.direction" +---| "scrolling.explicit_column_widths" +---| "scrolling.focus_fit_method" +---| "scrolling.follow_focus" +---| "scrolling.follow_min_visible" +---| "scrolling.fullscreen_on_one_column" +---| "scrolling.wrap_focus" +---| "scrolling.wrap_swapcol" +---| "xwayland.create_abstract_socket" +---| "xwayland.enabled" +---| "xwayland.force_zero_scaling" +---| "xwayland.use_nearest_neighbor" + +---@alias HL.MonitorSelector string|integer|HL.Monitor +---@alias HL.WorkspaceSelector string|integer|HL.Workspace +---@alias HL.WindowSelector string|integer|HL.Window +---@alias HL.Vec2Like HL.Vec2|{x:number, y:number}|{number, number}|string +---@alias HL.CssGap integer|{top?:integer, right?:integer, bottom?:integer, left?:integer} +---@alias HL.Gradient string|{colors:string[], angle?:number} + +---@class HL.Dispatcher +local __HL_Dispatcher = {} + +---@class HL.Vec2 +---@field x number +---@field y number +local __HL_Vec2 = {} + +---@class HL.Box +---@field x number +---@field y number +---@field w number +---@field h number +local __HL_Box = {} + +---@class HL.LayoutTarget +---@field index integer +---@field window HL.Window|nil +---@field box HL.Box +---@field place fun(self: HL.LayoutTarget, box: HL.Box): nil +---@field set_box fun(self: HL.LayoutTarget, box: HL.Box): nil +local __HL_LayoutTarget = {} + +---@class HL.LayoutContext +---@field area HL.Box +---@field targets HL.LayoutTarget[] +---@field grid_cell fun(self: HL.LayoutContext, i: integer, cols: integer, rows?: integer): HL.Box +---@field column fun(self: HL.LayoutContext, i: integer, n: integer): HL.Box +---@field row fun(self: HL.LayoutContext, i: integer, n: integer): HL.Box +---@field split fun(self: HL.LayoutContext, box: HL.Box, side: 'left'|'right'|'top'|'bottom'|'up'|'down', ratio: number): HL.Box +local __HL_LayoutContext = {} + +---@class HL.LayoutProvider +---@field recalculate fun(ctx: HL.LayoutContext): nil +---@field layout_msg? fun(ctx: HL.LayoutContext, msg: string): boolean|string|nil +local __HL_LayoutProvider = {} + +---@class HL.BindOptions +---@field repeating? boolean +---@field locked? boolean +---@field release? boolean +---@field non_consuming? boolean +---@field transparent? boolean +---@field ignore_mods? boolean +---@field dont_inhibit? boolean +---@field long_press? boolean +---@field submap_universal? boolean +---@field click? boolean +---@field drag? boolean +---@field description? string +---@field desc? string +---@field device? {inclusive?: boolean, list?: string[]} +local __HL_BindOptions = {} + +---@class HL.TimerOptions +---@field timeout integer +---@field type "repeat"|"oneshot" +local __HL_TimerOptions = {} + +---@class HL.GestureSpec +---@field fingers integer +---@field direction string +---@field action string +---@field mods? string +---@field scale? number +---@field mode? string +---@field zoom_level? number +---@field workspace_name? string +---@field disable_inhibit? boolean +local __HL_GestureSpec = {} + +---@class HL.PermissionSpec +---@field binary string +---@field type string +---@field mode string +local __HL_PermissionSpec = {} + +---@class HL.NotificationOptions +---@field color? string +---@field timeout? number +---@field icon? integer|string +---@field font_size? number +local __HL_NotificationOptions = {} + +---@class HL.LayerQueryFilter +---@field monitor? HL.MonitorSelector +---@field namespace? string +local __HL_LayerQueryFilter = {} + +---@class HL.WindowQueryFilter +---@field class? string +---@field floating? boolean +---@field mapped? boolean +---@field monitor? HL.MonitorSelector +---@field tag? string +---@field title? string +---@field workspace? HL.WorkspaceSelector +local __HL_WindowQueryFilter = {} + +---@class HL.DeviceSpec +---@field absolute_region_position? boolean +---@field accel_profile? string +---@field active_area_position? HL.Vec2Like +---@field active_area_size? HL.Vec2Like +---@field clickfinger_behavior? boolean +---@field disable_while_typing? boolean +---@field drag_3fg? integer|boolean +---@field drag_lock? integer|boolean +---@field enabled? boolean +---@field flip_x? boolean +---@field flip_y? boolean +---@field kb_file? string +---@field kb_layout? string +---@field kb_model? string +---@field kb_options? string +---@field kb_rules? string +---@field kb_variant? string +---@field keybinds? boolean +---@field left_handed? boolean +---@field middle_button_emulation? boolean +---@field name string +---@field natural_scroll? boolean +---@field numlock_by_default? boolean +---@field output? string +---@field region_position? HL.Vec2Like +---@field region_size? HL.Vec2Like +---@field relative_input? boolean +---@field release_pressed_on_close? boolean +---@field repeat_delay? integer|boolean +---@field repeat_rate? integer|boolean +---@field resolve_binds_by_sym? boolean +---@field rotation? integer|boolean +---@field scroll_button? integer|boolean +---@field scroll_button_lock? boolean +---@field scroll_factor? number|boolean +---@field scroll_method? string +---@field scroll_points? string +---@field sensitivity? number|boolean +---@field share_states? integer|boolean +---@field tags? string +---@field tap_and_drag? boolean +---@field tap_button_map? string +---@field tap_to_click? boolean +---@field transform? integer|boolean +local __HL_DeviceSpec = {} + +---@class HL.LayerRuleSpec +---@field above_lock? integer|boolean +---@field animation? string +---@field blur? boolean +---@field blur_popups? boolean +---@field dim_around? boolean +---@field enabled? boolean +---@field ignore_alpha? number|boolean +---@field match? table +---@field name? string +---@field no_anim? boolean +---@field no_screen_share? boolean +---@field order? integer|boolean +---@field xray? boolean +local __HL_LayerRuleSpec = {} + +---@class HL.MonitorSpec +---@field bitdepth? integer|boolean +---@field cm? string +---@field disabled? boolean +---@field icc? string +---@field max_avg_luminance? integer|boolean +---@field max_luminance? integer|boolean +---@field min_luminance? number|boolean +---@field mirror? string +---@field mode? string +---@field output string +---@field position? string +---@field reserved? integer|HL.CssGap +---@field reserved_area? integer|HL.CssGap +---@field scale? string|number +---@field sdr_eotf? string +---@field sdr_max_luminance? integer|boolean +---@field sdr_min_luminance? number|boolean +---@field sdrbrightness? number|boolean +---@field sdrsaturation? number|boolean +---@field supports_hdr? integer|boolean +---@field supports_wide_color? integer|boolean +---@field transform? integer|boolean +---@field vrr? integer|boolean +local __HL_MonitorSpec = {} + +---@class HL.WindowRuleSpec +---@field enabled? boolean +---@field match? table +---@field name? string +local __HL_WindowRuleSpec = {} + +---@class HL.WorkspaceRuleSpec +---@field animation? string +---@field border_size? integer|boolean +---@field decorate? boolean +---@field default? boolean +---@field default_name? string +---@field enabled? boolean +---@field float_gaps? integer|HL.CssGap +---@field gaps_in? integer|HL.CssGap +---@field gaps_out? integer|HL.CssGap +---@field layout? string +---@field layout_opts? table +---@field monitor? string +---@field no_border? boolean +---@field no_rounding? boolean +---@field no_shadow? boolean +---@field on_created_empty? string +---@field persistent? boolean +---@field workspace string +local __HL_WorkspaceRuleSpec = {} + +---@class HL.EventSubscription +---@field is_active fun(self: HL.EventSubscription, ...): any +---@field remove fun(self: HL.EventSubscription, ...): any +local __HL_EventSubscription = {} + +---@class HL.Group +---@field current HL.Window|nil +---@field current_index integer +---@field denied boolean +---@field locked boolean +---@field members HL.Window|table|nil +---@field size integer +local __HL_Group = {} + +---@class HL.Keybind +---@field is_enabled fun(self: HL.Keybind, ...): any +---@field remove fun(self: HL.Keybind, ...): any +---@field set_enabled fun(self: HL.Keybind, ...): any +---@field unbind fun(self: HL.Keybind, ...): any +---@field arg string +---@field auto_consuming boolean +---@field catchall boolean +---@field click boolean +---@field description any +---@field device_inclusive boolean +---@field devices nil +---@field display_key string +---@field dont_inhibit boolean +---@field drag boolean +---@field enabled boolean +---@field handler string +---@field has_description boolean +---@field ignore_mods boolean +---@field key string +---@field keycode integer +---@field locked boolean +---@field long_press boolean +---@field modmask integer +---@field mouse boolean +---@field non_consuming boolean +---@field release boolean +---@field repeating boolean +---@field submap string +---@field submap_universal boolean +---@field transparent boolean +local __HL_Keybind = {} + +---@class HL.LayerRule +---@field is_enabled fun(self: HL.LayerRule, ...): any +---@field set_enabled fun(self: HL.LayerRule, ...): any +local __HL_LayerRule = {} + +---@class HL.LayerSurface +---@field above_fullscreen boolean|nil +---@field address string +---@field h integer +---@field interactivity integer +---@field layer integer +---@field mapped boolean +---@field monitor HL.Monitor|nil +---@field namespace string +---@field pid integer +---@field w integer +---@field x integer +---@field y integer +local __HL_LayerSurface = {} + +---@class HL.Monitor +---@field active_special_workspace HL.Workspace|nil +---@field active_workspace HL.Workspace|nil +---@field description string +---@field dpms_status boolean +---@field focused boolean|nil +---@field height integer +---@field id integer +---@field is_mirror boolean +---@field mirrors HL.Monitor|table +---@field name string +---@field position integer|table +---@field refresh_rate number +---@field scale number +---@field size integer|table +---@field transform integer +---@field vrr_active boolean +---@field width integer +---@field x integer +---@field y integer +local __HL_Monitor = {} + +---@class HL.Notification +---@field dismiss fun(self: HL.Notification, ...): any +---@field get_color fun(self: HL.Notification, ...): any +---@field get_elapsed fun(self: HL.Notification, ...): any +---@field get_elapsed_since_creation fun(self: HL.Notification, ...): any +---@field get_font_size fun(self: HL.Notification, ...): any +---@field get_icon fun(self: HL.Notification, ...): any +---@field get_text fun(self: HL.Notification, ...): any +---@field get_timeout fun(self: HL.Notification, ...): any +---@field is_alive fun(self: HL.Notification, ...): any +---@field is_paused fun(self: HL.Notification, ...): any +---@field pause fun(self: HL.Notification, ...): any +---@field resume fun(self: HL.Notification, ...): any +---@field set_color fun(self: HL.Notification, ...): any +---@field set_font_size fun(self: HL.Notification, ...): any +---@field set_icon fun(self: HL.Notification, ...): any +---@field set_paused fun(self: HL.Notification, ...): any +---@field set_text fun(self: HL.Notification, ...): any +---@field set_timeout fun(self: HL.Notification, ...): any +local __HL_Notification = {} + +---@class HL.Timer +---@field is_enabled fun(self: HL.Timer, ...): any +---@field set_enabled fun(self: HL.Timer, ...): any +---@field set_timeout fun(self: HL.Timer, ...): any +local __HL_Timer = {} + +---@class HL.Window +---@field accepts_input boolean +---@field active boolean|nil +---@field address string +---@field at integer|table +---@field class string +---@field content_type string +---@field floating boolean +---@field focus_history_id integer +---@field fullscreen integer +---@field fullscreen_client integer +---@field group HL.Group|nil +---@field hidden boolean +---@field inhibiting_idle boolean +---@field initial_class string +---@field initial_title string +---@field layout HL.Window|boolean|integer|number|string|table|nil +---@field mapped boolean +---@field monitor HL.Monitor|nil +---@field over_fullscreen boolean +---@field pid integer +---@field pinned boolean +---@field size integer|table +---@field stable_id integer +---@field swallowing HL.Window|nil +---@field tags string|table +---@field title string +---@field visible boolean +---@field workspace HL.Workspace|nil +---@field xdg_description string|nil +---@field xdg_tag string|nil +---@field xwayland boolean +local __HL_Window = {} + +---@class HL.WindowRule +---@field is_enabled fun(self: HL.WindowRule, ...): any +---@field set_enabled fun(self: HL.WindowRule, ...): any +local __HL_WindowRule = {} + +---@class HL.Workspace +---@field get_groups fun(self: HL.Workspace, ...): any +---@field get_windows fun(self: HL.Workspace, ...): any +---@field active boolean +---@field config_name string +---@field fullscreen_mode integer +---@field fullscreen_window HL.Window|nil +---@field groups integer|nil +---@field has_fullscreen boolean +---@field has_urgent boolean +---@field id integer +---@field is_empty boolean +---@field is_persistent boolean +---@field last_window HL.Window|nil +---@field monitor HL.Monitor|nil +---@field name string +---@field special boolean +---@field tiled_layout string +---@field visible boolean +---@field windows integer +local __HL_Workspace = {} + +---@class HL.API +---@field animation fun(...): any +---@field bind fun(keys: string, dispatcher: HL.Dispatcher|function, opts?: HL.BindOptions): HL.Keybind +---@field config fun(config: table): nil +---@field curve fun(...): any +---@field define_submap fun(name: string, reset_or_fn: string|function, fn?: function): nil +---@field device fun(spec: HL.DeviceSpec): nil +---@field dispatch fun(dispatcher: HL.Dispatcher|function): any +---@field env fun(...): any +---@field exec_cmd fun(cmd: string, rules?: table): nil +---@field gesture fun(spec: HL.GestureSpec): nil +---@field get_active_monitor fun(): HL.Monitor|nil +---@field get_active_special_workspace fun(monitor?: HL.MonitorSelector): HL.Workspace|nil +---@field get_active_window fun(): HL.Window|nil +---@field get_active_workspace fun(monitor?: HL.MonitorSelector): HL.Workspace|nil +---@field get_config fun(key: HL.ConfigKey|string): any, string? +---@field get_current_submap fun(): string +---@field get_cursor_pos fun(): HL.Vec2|nil +---@field get_last_window fun(): HL.Window|nil +---@field get_last_workspace fun(monitor?: HL.MonitorSelector): HL.Workspace|nil +---@field get_layers fun(filters?: HL.LayerQueryFilter): HL.LayerSurface[] +---@field get_monitor fun(selector: HL.MonitorSelector): HL.Monitor|nil +---@field get_monitor_at fun(x: number|HL.Vec2, y?: number): HL.Monitor|nil +---@field get_monitor_at_cursor fun(): HL.Monitor|nil +---@field get_monitors fun(): HL.Monitor[] +---@field get_urgent_window fun(): HL.Window|nil +---@field get_window fun(selector: HL.WindowSelector): HL.Window|nil +---@field get_windows fun(filters?: HL.WindowQueryFilter): HL.Window[] +---@field get_workspace fun(selector: HL.WorkspaceSelector): HL.Workspace|nil +---@field get_workspace_windows fun(workspace: HL.WorkspaceSelector): HL.Window[] +---@field get_workspaces fun(): HL.Workspace[] +---@field layer_rule fun(spec: HL.LayerRuleSpec): HL.LayerRule +---@field monitor fun(spec: HL.MonitorSpec): nil +---@field on fun(event: HL.EventName, cb: fun(...)): HL.EventSubscription +---@field permission fun(spec: HL.PermissionSpec): nil +---@field timer fun(callback: function, opts: HL.TimerOptions): HL.Timer +---@field unbind fun(...): any +---@field version fun(...): any +---@field window_rule fun(spec: HL.WindowRuleSpec): HL.WindowRule +---@field workspace_rule fun(spec: HL.WorkspaceRuleSpec): nil +---@field dsp HL.DspNamespace +---@field layout HL.LayoutNamespace +---@field notification HL.NotificationNamespace +---@field plugin HL.PluginNamespace +local __HL_API = {} + +---@class HL.DspNamespace +---@field dpms fun(...): HL.Dispatcher +---@field event fun(...): HL.Dispatcher +---@field exec_cmd fun(...): HL.Dispatcher +---@field exec_raw fun(...): HL.Dispatcher +---@field exit fun(...): HL.Dispatcher +---@field focus fun(...): HL.Dispatcher +---@field force_idle fun(...): HL.Dispatcher +---@field force_renderer_reload fun(...): HL.Dispatcher +---@field global fun(...): HL.Dispatcher +---@field layout fun(...): HL.Dispatcher +---@field no_op fun(...): HL.Dispatcher +---@field pass fun(...): HL.Dispatcher +---@field send_key_state fun(...): HL.Dispatcher +---@field send_shortcut fun(...): HL.Dispatcher +---@field submap fun(...): HL.Dispatcher +---@field cursor HL.DspCursorNamespace +---@field group HL.DspGroupNamespace +---@field window HL.DspWindowNamespace +---@field workspace HL.DspWorkspaceNamespace +local __HL_DspNamespace = {} + +---@class HL.DspCursorNamespace +---@field move fun(...): HL.Dispatcher +---@field move_to_corner fun(...): HL.Dispatcher +local __HL_DspCursorNamespace = {} + +---@class HL.DspGroupNamespace +---@field active fun(...): HL.Dispatcher +---@field lock fun(...): HL.Dispatcher +---@field lock_active fun(...): HL.Dispatcher +---@field move_window fun(...): HL.Dispatcher +---@field next fun(...): HL.Dispatcher +---@field prev fun(...): HL.Dispatcher +---@field toggle fun(...): HL.Dispatcher +local __HL_DspGroupNamespace = {} + +---@class HL.DspWindowNamespace +---@field alter_zorder fun(...): HL.Dispatcher +---@field bring_to_top fun(...): HL.Dispatcher +---@field center fun(...): HL.Dispatcher +---@field clear_tags fun(...): HL.Dispatcher +---@field close fun(...): HL.Dispatcher +---@field cycle_next fun(...): HL.Dispatcher +---@field deny_from_group fun(...): HL.Dispatcher +---@field drag fun(...): HL.Dispatcher +---@field float fun(...): HL.Dispatcher +---@field fullscreen fun(...): HL.Dispatcher +---@field fullscreen_state fun(...): HL.Dispatcher +---@field kill fun(...): HL.Dispatcher +---@field move fun(...): HL.Dispatcher +---@field pin fun(...): HL.Dispatcher +---@field pseudo fun(...): HL.Dispatcher +---@field resize fun(...): HL.Dispatcher +---@field set_prop fun(...): HL.Dispatcher +---@field signal fun(...): HL.Dispatcher +---@field swap fun(...): HL.Dispatcher +---@field tag fun(...): HL.Dispatcher +---@field toggle_swallow fun(...): HL.Dispatcher +local __HL_DspWindowNamespace = {} + +---@class HL.DspWorkspaceNamespace +---@field move fun(...): HL.Dispatcher +---@field rename fun(...): HL.Dispatcher +---@field swap_monitors fun(...): HL.Dispatcher +---@field toggle_special fun(...): HL.Dispatcher +local __HL_DspWorkspaceNamespace = {} + +---@class HL.LayoutNamespace +---@field register fun(name: string, provider: HL.LayoutProvider): nil +local __HL_LayoutNamespace = {} + +---@class HL.NotificationNamespace +---@field create fun(opts?: HL.NotificationOptions): HL.Notification +---@field get fun(): HL.Notification[] +local __HL_NotificationNamespace = {} + +---@class HL.PluginNamespace +---@field load fun(...): any +---@field [string] any +local __HL_PluginNamespace = {} + +---@type HL.API +hl = {} + +---@class HL.ConfigValueTypes +---@field ['animations.enabled'] boolean +---@field ['animations.workspace_wraparound'] boolean +---@field ['binds.allow_pin_fullscreen'] boolean +---@field ['binds.allow_workspace_cycles'] boolean +---@field ['binds.disable_keybind_grabbing'] boolean +---@field ['binds.drag_threshold'] integer|boolean +---@field ['binds.focus_preferred_method'] integer|boolean +---@field ['binds.hide_special_on_workspace_change'] boolean +---@field ['binds.ignore_group_lock'] boolean +---@field ['binds.movefocus_cycles_fullscreen'] boolean +---@field ['binds.movefocus_cycles_groupfirst'] boolean +---@field ['binds.pass_mouse_when_bound'] boolean +---@field ['binds.scroll_event_delay'] integer|boolean +---@field ['binds.window_direction_monitor_fallback'] boolean +---@field ['binds.workspace_back_and_forth'] boolean +---@field ['binds.workspace_center_on'] integer|boolean +---@field ['cursor.default_monitor'] string +---@field ['cursor.enable_hyprcursor'] boolean +---@field ['cursor.hide_on_key_press'] boolean +---@field ['cursor.hide_on_tablet'] boolean +---@field ['cursor.hide_on_touch'] boolean +---@field ['cursor.hotspot_padding'] integer|boolean +---@field ['cursor.inactive_timeout'] number|boolean +---@field ['cursor.invisible'] boolean +---@field ['cursor.min_refresh_rate'] integer|boolean +---@field ['cursor.no_break_fs_vrr'] integer|boolean +---@field ['cursor.no_hardware_cursors'] integer|boolean +---@field ['cursor.no_warps'] boolean +---@field ['cursor.persistent_warps'] boolean +---@field ['cursor.sync_gsettings_theme'] boolean +---@field ['cursor.use_cpu_buffer'] integer|boolean +---@field ['cursor.warp_back_after_non_mouse_input'] boolean +---@field ['cursor.warp_on_change_workspace'] integer|boolean +---@field ['cursor.warp_on_toggle_special'] integer|boolean +---@field ['cursor.zoom_detached_camera'] boolean +---@field ['cursor.zoom_disable_aa'] boolean +---@field ['cursor.zoom_factor'] number|boolean +---@field ['cursor.zoom_rigid'] boolean +---@field ['debug.colored_stdout_logs'] boolean +---@field ['debug.damage_blink'] boolean +---@field ['debug.damage_tracking'] integer|boolean +---@field ['debug.disable_logs'] boolean +---@field ['debug.disable_scale_checks'] boolean +---@field ['debug.disable_time'] boolean +---@field ['debug.ds_handle_same_buffer'] boolean +---@field ['debug.ds_handle_same_buffer_fifo'] boolean +---@field ['debug.enable_stdout_logs'] boolean +---@field ['debug.error_limit'] integer|boolean +---@field ['debug.error_position'] integer|boolean +---@field ['debug.fifo_pending_workaround'] boolean +---@field ['debug.full_cm_proto'] boolean +---@field ['debug.gl_debugging'] boolean +---@field ['debug.invalidate_fp16'] integer|boolean +---@field ['debug.log_damage'] boolean +---@field ['debug.manual_crash'] integer|boolean +---@field ['debug.overlay'] boolean +---@field ['debug.pass'] boolean +---@field ['debug.render_solitary_wo_damage'] boolean +---@field ['debug.suppress_errors'] boolean +---@field ['debug.vfr'] boolean +---@field ['decoration.active_opacity'] number|boolean +---@field ['decoration.blur.brightness'] number|boolean +---@field ['decoration.blur.contrast'] number|boolean +---@field ['decoration.blur.enabled'] boolean +---@field ['decoration.blur.ignore_opacity'] boolean +---@field ['decoration.blur.input_methods'] boolean +---@field ['decoration.blur.input_methods_ignorealpha'] number|boolean +---@field ['decoration.blur.new_optimizations'] boolean +---@field ['decoration.blur.noise'] number|boolean +---@field ['decoration.blur.passes'] integer|boolean +---@field ['decoration.blur.popups'] boolean +---@field ['decoration.blur.popups_ignorealpha'] number|boolean +---@field ['decoration.blur.size'] integer|boolean +---@field ['decoration.blur.special'] boolean +---@field ['decoration.blur.vibrancy'] number|boolean +---@field ['decoration.blur.vibrancy_darkness'] number|boolean +---@field ['decoration.blur.xray'] boolean +---@field ['decoration.border_part_of_window'] boolean +---@field ['decoration.dim_around'] number|boolean +---@field ['decoration.dim_inactive'] boolean +---@field ['decoration.dim_modal'] boolean +---@field ['decoration.dim_special'] number|boolean +---@field ['decoration.dim_strength'] number|boolean +---@field ['decoration.fullscreen_opacity'] number|boolean +---@field ['decoration.glow.color'] string +---@field ['decoration.glow.color_inactive'] string +---@field ['decoration.glow.enabled'] boolean +---@field ['decoration.glow.range'] integer|boolean +---@field ['decoration.glow.render_power'] integer|boolean +---@field ['decoration.inactive_opacity'] number|boolean +---@field ['decoration.rounding'] integer|boolean +---@field ['decoration.rounding_power'] number|boolean +---@field ['decoration.screen_shader'] string +---@field ['decoration.shadow.color'] string +---@field ['decoration.shadow.color_inactive'] string +---@field ['decoration.shadow.enabled'] boolean +---@field ['decoration.shadow.offset'] HL.Vec2Like +---@field ['decoration.shadow.range'] integer|boolean +---@field ['decoration.shadow.render_power'] integer|boolean +---@field ['decoration.shadow.scale'] number|boolean +---@field ['decoration.shadow.sharp'] boolean +---@field ['dwindle.default_split_ratio'] number|boolean +---@field ['dwindle.force_split'] integer|boolean +---@field ['dwindle.permanent_direction_override'] boolean +---@field ['dwindle.precise_mouse_move'] boolean +---@field ['dwindle.preserve_split'] boolean +---@field ['dwindle.smart_resizing'] boolean +---@field ['dwindle.smart_split'] boolean +---@field ['dwindle.special_scale_factor'] number|boolean +---@field ['dwindle.split_bias'] integer|boolean +---@field ['dwindle.split_width_multiplier'] number|boolean +---@field ['dwindle.use_active_for_splits'] boolean +---@field ['ecosystem.enforce_permissions'] boolean +---@field ['ecosystem.no_donation_nag'] boolean +---@field ['ecosystem.no_update_news'] boolean +---@field ['experimental.wp_cm_1_2'] boolean +---@field ['general.allow_tearing'] boolean +---@field ['general.border_size'] integer|boolean +---@field ['general.col.active_border'] string|HL.Gradient +---@field ['general.col.inactive_border'] string|HL.Gradient +---@field ['general.col.nogroup_border'] string|HL.Gradient +---@field ['general.col.nogroup_border_active'] string|HL.Gradient +---@field ['general.extend_border_grab_area'] integer|boolean +---@field ['general.float_gaps'] integer|HL.CssGap +---@field ['general.gaps_in'] integer|HL.CssGap +---@field ['general.gaps_out'] integer|HL.CssGap +---@field ['general.gaps_workspaces'] integer|boolean +---@field ['general.hover_icon_on_border'] boolean +---@field ['general.layout'] string +---@field ['general.locale'] string +---@field ['general.modal_parent_blocking'] boolean +---@field ['general.no_focus_fallback'] boolean +---@field ['general.resize_corner'] integer|boolean +---@field ['general.resize_on_border'] boolean +---@field ['general.snap.border_overlap'] boolean +---@field ['general.snap.enabled'] boolean +---@field ['general.snap.monitor_gap'] integer|boolean +---@field ['general.snap.respect_gaps'] boolean +---@field ['general.snap.window_gap'] integer|boolean +---@field ['gestures.close_max_timeout'] integer|boolean +---@field ['gestures.scrolling.move_snap_cursor'] boolean +---@field ['gestures.scrolling.move_snap_to_grid'] boolean +---@field ['gestures.workspace_swipe_cancel_ratio'] number|boolean +---@field ['gestures.workspace_swipe_create_new'] boolean +---@field ['gestures.workspace_swipe_direction_lock'] boolean +---@field ['gestures.workspace_swipe_direction_lock_threshold'] integer|boolean +---@field ['gestures.workspace_swipe_distance'] integer|boolean +---@field ['gestures.workspace_swipe_forever'] boolean +---@field ['gestures.workspace_swipe_invert'] boolean +---@field ['gestures.workspace_swipe_min_speed_to_force'] integer|boolean +---@field ['gestures.workspace_swipe_touch'] boolean +---@field ['gestures.workspace_swipe_touch_invert'] boolean +---@field ['gestures.workspace_swipe_use_r'] boolean +---@field ['group.auto_group'] boolean +---@field ['group.col.border_active'] string|HL.Gradient +---@field ['group.col.border_inactive'] string|HL.Gradient +---@field ['group.col.border_locked_active'] string|HL.Gradient +---@field ['group.col.border_locked_inactive'] string|HL.Gradient +---@field ['group.drag_into_group'] integer|boolean +---@field ['group.focus_removed_window'] boolean +---@field ['group.group_on_movetoworkspace'] boolean +---@field ['group.groupbar.blur'] boolean +---@field ['group.groupbar.col.active'] string|HL.Gradient +---@field ['group.groupbar.col.inactive'] string|HL.Gradient +---@field ['group.groupbar.col.locked_active'] string|HL.Gradient +---@field ['group.groupbar.col.locked_inactive'] string|HL.Gradient +---@field ['group.groupbar.enabled'] boolean +---@field ['group.groupbar.font_family'] string +---@field ['group.groupbar.font_size'] integer|boolean +---@field ['group.groupbar.font_weight_active'] integer|string +---@field ['group.groupbar.font_weight_inactive'] integer|string +---@field ['group.groupbar.gaps_in'] integer|boolean +---@field ['group.groupbar.gaps_out'] integer|boolean +---@field ['group.groupbar.gradient_round_only_edges'] boolean +---@field ['group.groupbar.gradient_rounding'] integer|boolean +---@field ['group.groupbar.gradient_rounding_power'] number|boolean +---@field ['group.groupbar.gradients'] boolean +---@field ['group.groupbar.height'] integer|boolean +---@field ['group.groupbar.indicator_gap'] integer|boolean +---@field ['group.groupbar.indicator_height'] integer|boolean +---@field ['group.groupbar.keep_upper_gap'] boolean +---@field ['group.groupbar.middle_click_close'] boolean +---@field ['group.groupbar.priority'] integer|boolean +---@field ['group.groupbar.render_titles'] boolean +---@field ['group.groupbar.round_only_edges'] boolean +---@field ['group.groupbar.rounding'] integer|boolean +---@field ['group.groupbar.rounding_power'] number|boolean +---@field ['group.groupbar.scrolling'] boolean +---@field ['group.groupbar.stacked'] boolean +---@field ['group.groupbar.text_color'] string +---@field ['group.groupbar.text_color_inactive'] string +---@field ['group.groupbar.text_color_locked_active'] string +---@field ['group.groupbar.text_color_locked_inactive'] string +---@field ['group.groupbar.text_offset'] integer|boolean +---@field ['group.groupbar.text_padding'] integer|boolean +---@field ['group.insert_after_current'] boolean +---@field ['group.merge_floated_into_tiled_on_groupbar'] boolean +---@field ['group.merge_groups_on_drag'] boolean +---@field ['group.merge_groups_on_groupbar'] boolean +---@field ['input.accel_profile'] string +---@field ['input.emulate_discrete_scroll'] integer|boolean +---@field ['input.float_switch_override_focus'] integer|boolean +---@field ['input.focus_on_close'] integer|boolean +---@field ['input.follow_mouse'] integer|boolean +---@field ['input.follow_mouse_shrink'] integer|boolean +---@field ['input.follow_mouse_threshold'] number|boolean +---@field ['input.force_no_accel'] boolean +---@field ['input.kb_file'] string +---@field ['input.kb_layout'] string +---@field ['input.kb_model'] string +---@field ['input.kb_options'] string +---@field ['input.kb_rules'] string +---@field ['input.kb_variant'] string +---@field ['input.left_handed'] boolean +---@field ['input.mouse_refocus'] boolean +---@field ['input.natural_scroll'] boolean +---@field ['input.numlock_by_default'] boolean +---@field ['input.off_window_axis_events'] integer|boolean +---@field ['input.repeat_delay'] integer|boolean +---@field ['input.repeat_rate'] integer|boolean +---@field ['input.resolve_binds_by_sym'] boolean +---@field ['input.rotation'] integer|boolean +---@field ['input.scroll_button'] integer|boolean +---@field ['input.scroll_button_lock'] boolean +---@field ['input.scroll_factor'] number|boolean +---@field ['input.scroll_method'] string +---@field ['input.scroll_points'] string +---@field ['input.sensitivity'] number|boolean +---@field ['input.special_fallthrough'] boolean +---@field ['input.tablet.absolute_region_position'] boolean +---@field ['input.tablet.active_area_position'] HL.Vec2Like +---@field ['input.tablet.active_area_size'] HL.Vec2Like +---@field ['input.tablet.left_handed'] boolean +---@field ['input.tablet.output'] string +---@field ['input.tablet.region_position'] HL.Vec2Like +---@field ['input.tablet.region_size'] HL.Vec2Like +---@field ['input.tablet.relative_input'] boolean +---@field ['input.tablet.transform'] integer|boolean +---@field ['input.touchdevice.enabled'] boolean +---@field ['input.touchdevice.output'] string +---@field ['input.touchdevice.transform'] integer|boolean +---@field ['input.touchpad.clickfinger_behavior'] boolean +---@field ['input.touchpad.disable_while_typing'] boolean +---@field ['input.touchpad.drag_3fg'] integer|boolean +---@field ['input.touchpad.drag_lock'] integer|boolean +---@field ['input.touchpad.flip_x'] boolean +---@field ['input.touchpad.flip_y'] boolean +---@field ['input.touchpad.middle_button_emulation'] boolean +---@field ['input.touchpad.natural_scroll'] boolean +---@field ['input.touchpad.scroll_factor'] number|boolean +---@field ['input.touchpad.tap_and_drag'] boolean +---@field ['input.touchpad.tap_button_map'] string +---@field ['input.touchpad.tap_to_click'] boolean +---@field ['input.virtualkeyboard.release_pressed_on_close'] boolean +---@field ['input.virtualkeyboard.share_states'] integer|boolean +---@field ['layout.single_window_aspect_ratio'] HL.Vec2Like +---@field ['layout.single_window_aspect_ratio_tolerance'] number|boolean +---@field ['master.allow_small_split'] boolean +---@field ['master.always_keep_position'] boolean +---@field ['master.center_ignores_reserved'] boolean +---@field ['master.center_master_fallback'] string +---@field ['master.drop_at_cursor'] boolean +---@field ['master.focus_master_on_close'] boolean +---@field ['master.mfact'] number|boolean +---@field ['master.new_on_active'] string +---@field ['master.new_on_top'] boolean +---@field ['master.new_status'] string +---@field ['master.orientation'] string +---@field ['master.slave_count_for_center_master'] integer|boolean +---@field ['master.smart_resizing'] boolean +---@field ['master.special_scale_factor'] number|boolean +---@field ['misc.allow_session_lock_restore'] boolean +---@field ['misc.always_follow_on_dnd'] boolean +---@field ['misc.animate_manual_resizes'] boolean +---@field ['misc.animate_mouse_windowdragging'] boolean +---@field ['misc.anr_missed_pings'] integer|boolean +---@field ['misc.background_color'] string +---@field ['misc.close_special_on_empty'] boolean +---@field ['misc.col.splash'] string +---@field ['misc.disable_autoreload'] boolean +---@field ['misc.disable_hyprland_guiutils_check'] boolean +---@field ['misc.disable_hyprland_logo'] boolean +---@field ['misc.disable_scale_notification'] boolean +---@field ['misc.disable_splash_rendering'] boolean +---@field ['misc.disable_watchdog_warning'] boolean +---@field ['misc.disable_xdg_env_checks'] boolean +---@field ['misc.enable_anr_dialog'] boolean +---@field ['misc.enable_swallow'] boolean +---@field ['misc.exit_window_retains_fullscreen'] boolean +---@field ['misc.focus_on_activate'] boolean +---@field ['misc.font_family'] string +---@field ['misc.force_default_wallpaper'] integer|boolean +---@field ['misc.initial_workspace_tracking'] integer|boolean +---@field ['misc.key_press_enables_dpms'] boolean +---@field ['misc.layers_hog_keyboard_focus'] boolean +---@field ['misc.lockdead_screen_delay'] integer|boolean +---@field ['misc.middle_click_paste'] boolean +---@field ['misc.mouse_move_enables_dpms'] boolean +---@field ['misc.mouse_move_focuses_monitor'] boolean +---@field ['misc.name_vk_after_proc'] boolean +---@field ['misc.on_focus_under_fullscreen'] integer|boolean +---@field ['misc.render_unfocused_fps'] integer|boolean +---@field ['misc.screencopy_force_8b'] boolean +---@field ['misc.session_lock_xray'] boolean +---@field ['misc.size_limits_tiled'] boolean +---@field ['misc.splash_font_family'] string +---@field ['misc.swallow_exception_regex'] string +---@field ['misc.swallow_regex'] string +---@field ['misc.vrr'] integer|boolean +---@field ['opengl.nvidia_anti_flicker'] boolean +---@field ['quirks.prefer_hdr'] integer|boolean +---@field ['quirks.skip_non_kms_dmabuf_formats'] boolean +---@field ['render.cm_auto_hdr'] integer|boolean +---@field ['render.cm_enabled'] boolean +---@field ['render.cm_sdr_eotf'] string +---@field ['render.commit_timing_enabled'] boolean +---@field ['render.ctm_animation'] integer|boolean +---@field ['render.direct_scanout'] integer|boolean +---@field ['render.expand_undersized_textures'] boolean +---@field ['render.fp16_sdr_tf'] integer|boolean +---@field ['render.icc_vcgt_enabled'] boolean +---@field ['render.keep_unmodified_copy'] integer|boolean +---@field ['render.new_render_scheduling'] boolean +---@field ['render.non_shader_cm'] integer|boolean +---@field ['render.non_shader_cm_interop'] integer|boolean +---@field ['render.send_content_type'] boolean +---@field ['render.use_fp16'] integer|boolean +---@field ['render.use_shader_blur_blend'] boolean +---@field ['render.xp_mode'] boolean +---@field ['scrolling.column_width'] number|boolean +---@field ['scrolling.direction'] string +---@field ['scrolling.explicit_column_widths'] string +---@field ['scrolling.focus_fit_method'] integer|boolean +---@field ['scrolling.follow_focus'] boolean +---@field ['scrolling.follow_min_visible'] number|boolean +---@field ['scrolling.fullscreen_on_one_column'] boolean +---@field ['scrolling.wrap_focus'] boolean +---@field ['scrolling.wrap_swapcol'] boolean +---@field ['xwayland.create_abstract_socket'] boolean +---@field ['xwayland.enabled'] boolean +---@field ['xwayland.force_zero_scaling'] boolean +---@field ['xwayland.use_nearest_neighbor'] boolean +local __HL_ConfigValueTypes = {} diff --git a/hypr/hyprland.lua b/hypr/hyprland.lua new file mode 100644 index 0000000..5db9c07 --- /dev/null +++ b/hypr/hyprland.lua @@ -0,0 +1,269 @@ +------------------ +---- MONITORS ---- +------------------ + +-- See https://wiki.hypr.land/Configuring/Basics/Monitors/ +hl.monitor({ + output = "", + mode = "1920x1080@60", + position = "auto", + scale = "1", +}) + + +--------------------- +---- MY PROGRAMS ---- +--------------------- + +-- Set programs that you use +local terminal = "foot" +local fileManager = "thunar" +local menu = "rofi -show drun" + + +------------------- +---- AUTOSTART ---- +------------------- + +-- See https://wiki.hypr.land/Configuring/Basics/Autostart/ + +-- Autostart necessary processes (like notifications daemons, status bars, etc.) +-- Or execute your favorite apps at launch like this: +hl.on("hyprland.start", function() + hl.exec_cmd("swaybg -i /home/tony/walls/dune-wars.png") +end) + + +------------------------------- +---- ENVIRONMENT VARIABLES ---- +------------------------------- +hl.env("XCURSOR_SIZE", "24") +hl.env("XCURSOR_THEME", "Adwaita") + + +----------------------- +---- LOOK AND FEEL ---- +----------------------- + +-- Refer to https://wiki.hypr.land/Configuring/Basics/Variables/ +hl.config({ + general = { + gaps_in = 0, + gaps_out = 0, + border_size = 0, + + col = { + active_border = { colors = { "rgba(33ccffee)", "rgba(00ff99ee)" }, angle = 45 }, + inactive_border = "rgba(595959aa)", + }, + + resize_on_border = false, + allow_tearing = false, + layout = "master", + }, + + cursor = { enable_hyprcursor = false, no_hardware_cursors = true, }, + + decoration = { + rounding = 10, + rounding_power = 0, + + -- Change transparency of focused and unfocused windows + active_opacity = 1.0, + inactive_opacity = 1.0, + + blur = { + enabled = true, + size = 3, + passes = 1, + vibrancy = 0.1696, + }, + }, + + animations = { + enabled = true, + }, +}) + +hl.curve("easeOutQuint", { type = "bezier", points = { { 0.23, 1 }, { 0.32, 1 } } }) +hl.curve("easeInOutCubic", { type = "bezier", points = { { 0.65, 0.05 }, { 0.36, 1 } } }) +hl.curve("linear", { type = "bezier", points = { { 0, 0 }, { 1, 1 } } }) +hl.curve("almostLinear", { type = "bezier", points = { { 0.5, 0.5 }, { 0.75, 1 } } }) +hl.curve("quick", { type = "bezier", points = { { 0.15, 0 }, { 0.1, 1 } } }) +hl.curve("easy", { type = "spring", mass = 1, stiffness = 71.2633, dampening = 15.8273644 }) +hl.animation({ leaf = "global", enabled = true, speed = 10, bezier = "default" }) +hl.animation({ leaf = "border", enabled = true, speed = 5.39, bezier = "easeOutQuint" }) +hl.animation({ leaf = "windows", enabled = true, speed = 4.79, spring = "easy" }) +hl.animation({ leaf = "windowsIn", enabled = true, speed = 4.1, spring = "easy", style = "popin 87%" }) +hl.animation({ leaf = "windowsOut", enabled = true, speed = 1.49, bezier = "linear", style = "popin 87%" }) +hl.animation({ leaf = "fadeIn", enabled = true, speed = 1.73, bezier = "almostLinear" }) +hl.animation({ leaf = "fadeOut", enabled = true, speed = 1.46, bezier = "almostLinear" }) +hl.animation({ leaf = "fade", enabled = true, speed = 3.03, bezier = "quick" }) +hl.animation({ leaf = "layers", enabled = true, speed = 3.81, bezier = "easeOutQuint" }) +hl.animation({ leaf = "layersIn", enabled = true, speed = 4, bezier = "easeOutQuint", style = "fade" }) +hl.animation({ leaf = "layersOut", enabled = true, speed = 1.5, bezier = "linear", style = "fade" }) +hl.animation({ leaf = "fadeLayersIn", enabled = true, speed = 1.79, bezier = "almostLinear" }) +hl.animation({ leaf = "fadeLayersOut", enabled = true, speed = 1.39, bezier = "almostLinear" }) +hl.animation({ leaf = "workspaces", enabled = true, speed = 1.94, bezier = "almostLinear", style = "fade" }) +hl.animation({ leaf = "workspacesIn", enabled = true, speed = 1.21, bezier = "almostLinear", style = "fade" }) +hl.animation({ leaf = "workspacesOut", enabled = true, speed = 1.94, bezier = "almostLinear", style = "fade" }) +hl.animation({ leaf = "zoomFactor", enabled = true, speed = 7, bezier = "quick" }) + +hl.window_rule({ + name = "firefox-on-ws3", + match = { class = "^(firefox)$" }, + workspace = "3 silent" +}) + +hl.config({ + dwindle = { + preserve_split = true, -- You probably want this + }, +}) + +-- See https://wiki.hypr.land/Configuring/Layouts/Master-Layout/ for more +hl.config({ + master = { + new_status = "master", + }, +}) + +-- See https://wiki.hypr.land/Configuring/Layouts/Scrolling-Layout/ for more +hl.config({ + scrolling = { + fullscreen_on_one_column = true, + }, +}) + +hl.config({ + misc = { + force_default_wallpaper = -1, -- Set to 0 or 1 to disable the anime mascot wallpapers + disable_hyprland_logo = false, -- If true disables the random hyprland logo / anime girl background. :( + }, +}) + + + +hl.config({ + input = { + kb_layout = "us", + kb_variant = "", + kb_model = "", + kb_options = "", + kb_rules = "", + + -- infamous xset r rate 200 35; + repeat_rate = 35, + repeat_delay = 200, + follow_mouse = 1, + sensitivity = 0, -- -1.0 - 1.0, 0 means no modification. + touchpad = { + natural_scroll = false, + }, + }, +}) + +hl.gesture({ + fingers = 3, + direction = "horizontal", + action = "workspace" +}) + + +--------------------- +---- KEYBINDINGS ---- +--------------------- + +local main_mod = "SUPER" -- Sets "Windows" key as main modifier + +hl.bind(main_mod .. " + Return", hl.dsp.exec_cmd(terminal)) +hl.bind(main_mod .. " + Q", hl.dsp.window.close()) +hl.bind(main_mod .. " + SHIFT + Q", + hl.dsp.exec_cmd("command -v hyprshutdown >/dev/null 2>&1 && hyprshutdown || hyprctl dispatch 'hl.dsp.exit()'")) +hl.bind(main_mod .. " + E", hl.dsp.exec_cmd(fileManager)) +hl.bind(main_mod .. " + F", hl.dsp.window.float({ action = "toggle" })) +hl.bind(main_mod .. " + D", hl.dsp.exec_cmd(menu)) +hl.bind(main_mod .. " + P", hl.dsp.window.pseudo()) + +-- Move focus with main_mod + arrow keys +hl.bind(main_mod .. " + h", hl.dsp.focus({ direction = "left" })) +hl.bind(main_mod .. " + l", hl.dsp.focus({ direction = "right" })) +hl.bind(main_mod .. " + k", hl.dsp.focus({ direction = "up" })) +hl.bind(main_mod .. " + j", hl.dsp.focus({ direction = "down" })) + +-- Switch workspaces with main_mod + [0-9] +-- Move active window to a workspace with main_mod + SHIFT + [0-9] +for i = 1, 10 do + local key = i % 10 -- 10 maps to key 0 + hl.bind(main_mod .. " + " .. key, hl.dsp.focus({ workspace = i })) + hl.bind(main_mod .. " + SHIFT + " .. key, hl.dsp.window.move({ workspace = i })) +end + +-- Scroll through existing workspaces with main_mod + scroll +hl.bind(main_mod .. " + TAB", hl.dsp.focus({ workspace = "e+1" })) +hl.bind(main_mod .. " + SHIFT + TAB", hl.dsp.focus({ workspace = "e-1" })) + +-- Move/resize windows with main_mod + LMB/RMB and dragging +hl.bind(main_mod .. " + mouse:272", hl.dsp.window.drag(), { mouse = true }) +hl.bind(main_mod .. " + mouse:273", hl.dsp.window.resize(), { mouse = true }) + +-- Laptop multimedia keys for volume and LCD brightness +hl.bind("XF86AudioRaiseVolume", hl.dsp.exec_cmd("wpctl set-volume -l 1 @DEFAULT_AUDIO_SINK@ 5%+"), + { locked = true, repeating = true }) +hl.bind("XF86AudioLowerVolume", hl.dsp.exec_cmd("wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-"), + { locked = true, repeating = true }) +hl.bind("XF86AudioMute", hl.dsp.exec_cmd("wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"), + { locked = true, repeating = true }) +hl.bind("XF86AudioMicMute", hl.dsp.exec_cmd("wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle"), + { locked = true, repeating = true }) +hl.bind("XF86MonBrightnessUp", hl.dsp.exec_cmd("brightnessctl -e4 -n2 set 5%+"), { locked = true, repeating = true }) +hl.bind("XF86MonBrightnessDown", hl.dsp.exec_cmd("brightnessctl -e4 -n2 set 5%-"), { locked = true, repeating = true }) + +-- Requires playerctl +hl.bind("XF86AudioNext", hl.dsp.exec_cmd("playerctl next"), { locked = true }) +hl.bind("XF86AudioPause", hl.dsp.exec_cmd("playerctl play-pause"), { locked = true }) +hl.bind("XF86AudioPlay", hl.dsp.exec_cmd("playerctl play-pause"), { locked = true }) +hl.bind("XF86AudioPrev", hl.dsp.exec_cmd("playerctl previous"), { locked = true }) + + +-------------------------------- +---- WINDOWS AND WORKSPACES ---- +-------------------------------- + +-- See https://wiki.hypr.land/Configuring/Basics/Window-Rules/ +-- and https://wiki.hypr.land/Configuring/Basics/Workspace-Rules/ + +-- Example window rules that are useful + +hl.window_rule({ + -- Ignore maximize requests from all apps. You'll probably like this. + name = "suppress-maximize-events", + match = { class = ".*" }, + + suppress_event = "maximize", +}) + +hl.window_rule({ + -- Fix some dragging issues with XWayland + name = "fix-xwayland-drags", + match = { + class = "^$", + title = "^$", + xwayland = true, + float = true, + fullscreen = false, + pin = false, + }, + + no_focus = true, +}) + + +-- Hyprland-run windowrule +hl.window_rule({ + name = "move-hyprland-run", + match = { class = "hyprland-run" }, + + move = "20 monitor_h-120", + float = true, +})