--############################
--## ENVIRONMENT VARIABLES ###
--############################

-- See https://wiki.hypr.land/Configuring/Environment-variables/

-- XDG Desktop Portal
-- Generated by hyprlang2lua. Review TODOs before reloading Hyprland.

hl.env("XDG_CURRENT_DESKTOP", "Hyprland")
hl.env("XDG_SESSION_TYPE", "wayland")
hl.env("XDG_SESSION_DESKTOP", "Hyprland")

-- QT
hl.env("QT_QPA_PLATFORM", "wayland;xcb")
hl.env("QT_QPA_PLATFORMTHEME", "qt6ct")
hl.env("QT_WAYLAND_DISABLE_WINDOWDECORATION", "1")
hl.env("QT_AUTO_SCREEN_SCALE_FACTOR", "1")

-- GTK
hl.env("GDK_SCALE", "1")


hl.env("GTK_IM_MODULE", "wayland")
hl.env("XMODIFIERS", "@im=ibus")
hl.env("QT_IM_MODULES", "wayland;ibus")
hl.env("QT_IM_MODULE", "ibus")

hl.env("XCURSOR_SIZE", "20")
hl.env("HYPRCURSOR_SIZE", "20")
hl.env("HYPRCURSOR_THEME", "Volantes Cursors")

-- Mozilla
hl.env("MOZ_ENABLE_WAYLAND", "1")
hl.env("EGL_PLATFORM", "wayland")

-- Disable appimage launcher by default
hl.env("APPIMAGELAUNCHER_DISABLE", "1")

-- OZONE
hl.env("OZONE_PLATFORM", "wayland")

-- NVIDIA https://wiki.hyprland.org/Nvidia/
hl.env("WLR_NO_HARDWARE_CURSORS", "1")
hl.env("LIBVA_DRIVER_NAME", "nvidia")
hl.env("GBM_BACKEND", "nvidia-drm")
hl.env("SDL_VIDEODRIVER", "wayland")
hl.env("WLR_DRM_NO_ATOMIC", "1")
hl.env("__GLX_VENDOR_LIBRARY_NAME", "nvidia")
hl.env("__GL_VRR_ALLOWED", "1")
hl.env("__NV_PRIME_RENDER_OFFLOAD", "1")
hl.env("__VK_LAYER_NV_optimus", "NVIDIA_only")

-- Default Apps
hl.env("TERMINAL", "$terminal")
hl.env("VISUAL", "vim")
hl.env("EDITOR", "vim")
hl.env("SHELL", "fish")
hl.env("BROWSER", "$browser")

hl.env("MANGOHUD", "1")

hl.config({
    cursor = {
        no_hardware_cursors = true,
    },
})

