Compare commits
2
Commits
f4f40442a8
...
e419727c6d
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e419727c6d | ||
|
|
aaf8ae59df |
+12
-11
@@ -1,12 +1,13 @@
|
|||||||
hl.on("hyprland.start", function()
|
hl.on('hyprland.start', function()
|
||||||
hl.exec_cmd("uwsm-app -- hypridle")
|
hl.exec_cmd 'uwsm-app -- hypridle'
|
||||||
hl.exec_cmd("uwsm-app -- mako")
|
hl.exec_cmd 'uwsm-app -- mako'
|
||||||
hl.exec_cmd("uwsm-app -- hyprsunset")
|
hl.exec_cmd 'uwsm-app -- hyprsunset'
|
||||||
hl.exec_cmd("uwsm-app -- fcitx5 --disable notificationitem")
|
hl.exec_cmd 'uwsm-app -- fcitx5 --disable notificationitem'
|
||||||
hl.exec_cmd("uwsm-app -- Enpass -minimize")
|
hl.exec_cmd 'uwsm-app -- Enpass -minimize'
|
||||||
hl.exec_cmd("uwsm-app -- steam")
|
hl.exec_cmd 'uwsm-app -- steam'
|
||||||
hl.exec_cmd("nextcloud")
|
hl.exec_cmd 'nextcloud'
|
||||||
hl.exec_cmd("station-bg-random")
|
hl.exec_cmd 'station-bg-random'
|
||||||
hl.exec_cmd("/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1")
|
hl.exec_cmd '/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1'
|
||||||
hl.exec_cmd("dbus-update-activation-environment --systemd --all")
|
hl.exec_cmd 'dbus-update-activation-environment --systemd --all'
|
||||||
end)
|
end)
|
||||||
|
|
||||||
|
|||||||
+43
-11
@@ -113,20 +113,52 @@ bind('SUPER + CTRL + L', function()
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
if workspace.special then
|
hl.workspace_rule { workspace = 'name:' .. tostring(workspace.name), layout = next_layout }
|
||||||
hl.workspace_rule { workspace = tostring(workspace.name), layout = next_layout }
|
|
||||||
else
|
|
||||||
hl.workspace_rule { workspace = tostring(workspace.id), layout = next_layout }
|
|
||||||
end
|
|
||||||
|
|
||||||
notify(' Workspace layout set to ' .. next_layout)
|
notify(' Workspace layout set to ' .. next_layout)
|
||||||
end, 'Toggle workspace layout')
|
end, 'Toggle workspace layout')
|
||||||
|
|
||||||
|
local get_current_layout = function()
|
||||||
|
local workspace = hl.get_active_workspace()
|
||||||
|
if hl.get_active_special_workspace() then
|
||||||
|
workspace = hl.get_active_special_workspace()
|
||||||
|
end
|
||||||
|
if not workspace then
|
||||||
|
return 'dwindle'
|
||||||
|
end
|
||||||
|
|
||||||
|
return workspace.tiled_layout
|
||||||
|
end
|
||||||
|
|
||||||
-- Move focus with SUPER + arrow keys
|
-- Move focus with SUPER + arrow keys
|
||||||
bind('SUPER + H', hl.dsp.focus { direction = 'left' }, 'Move window focus left')
|
bind('SUPER + H', function()
|
||||||
bind('SUPER + L', hl.dsp.focus { direction = 'right' }, 'Move window focus right')
|
if get_current_layout() == 'monocle' then
|
||||||
bind('SUPER + K', hl.dsp.focus { direction = 'up' }, 'Move window focus up')
|
hl.dispatch(hl.dsp.window.cycle_next { tiled = true, next = false })
|
||||||
bind('SUPER + J', hl.dsp.focus { direction = 'down' }, 'Move window focus down')
|
else
|
||||||
|
hl.dispatch(hl.dsp.focus { direction = 'left' })
|
||||||
|
end
|
||||||
|
end, 'Move window focus left')
|
||||||
|
bind('SUPER + L', function()
|
||||||
|
if get_current_layout() == 'monocle' then
|
||||||
|
hl.dispatch(hl.dsp.window.cycle_next { tiled = true, next = true })
|
||||||
|
else
|
||||||
|
hl.dispatch(hl.dsp.focus { direction = 'right' })
|
||||||
|
end
|
||||||
|
end, 'Move window focus right')
|
||||||
|
bind('SUPER + K', function()
|
||||||
|
if get_current_layout() == 'monocle' then
|
||||||
|
hl.dispatch(hl.dsp.window.cycle_next { tiled = true, next = false })
|
||||||
|
else
|
||||||
|
hl.dispatch(hl.dsp.focus { direction = 'up' })
|
||||||
|
end
|
||||||
|
end, 'Move window focus up')
|
||||||
|
bind('SUPER + J', function()
|
||||||
|
if get_current_layout() == 'monocle' then
|
||||||
|
hl.dispatch(hl.dsp.window.cycle_next { tiled = true, next = true })
|
||||||
|
else
|
||||||
|
hl.dispatch(hl.dsp.focus { direction = 'down' })
|
||||||
|
end
|
||||||
|
end, 'Move window focus down')
|
||||||
bind('SUPER + SHIFT + H', hl.dsp.window.move { direction = 'left' }, 'Move window left')
|
bind('SUPER + SHIFT + H', hl.dsp.window.move { direction = 'left' }, 'Move window left')
|
||||||
bind('SUPER + SHIFT + L', hl.dsp.window.move { direction = 'right' }, 'Move window right')
|
bind('SUPER + SHIFT + L', hl.dsp.window.move { direction = 'right' }, 'Move window right')
|
||||||
bind('SUPER + SHIFT + K', hl.dsp.window.move { direction = 'up' }, 'Move window up')
|
bind('SUPER + SHIFT + K', hl.dsp.window.move { direction = 'up' }, 'Move window up')
|
||||||
@@ -162,8 +194,8 @@ bind('SUPER + D', function()
|
|||||||
end, 'Toggle comms workspace')
|
end, 'Toggle comms workspace')
|
||||||
|
|
||||||
-- Cycle through applications on active workspace
|
-- Cycle through applications on active workspace
|
||||||
bind('SUPER + TAB', hl.dsp.window.cycle_next { next = true }, 'Cycle to next window')
|
bind('SUPER + TAB', hl.dsp.window.cycle_next { tiled = true, next = true }, 'Cycle to next window')
|
||||||
bind('SUPER + SHIFT + TAB', hl.dsp.window.cycle_next { next = false }, 'Cycle to prev window')
|
bind('SUPER + SHIFT + TAB', hl.dsp.window.cycle_next { tiled = true, next = false }, 'Cycle to prev window')
|
||||||
-- bind("SUPER + TAB", /*bringactivetotop*/, "Reveal active window on top")
|
-- bind("SUPER + TAB", /*bringactivetotop*/, "Reveal active window on top")
|
||||||
-- bind("SUPER SHIFT + TAB", /*bringactivetotop*/, "Reveal active window on top")
|
-- bind("SUPER SHIFT + TAB", /*bringactivetotop*/, "Reveal active window on top")
|
||||||
|
|
||||||
|
|||||||
+43
-42
@@ -1,11 +1,11 @@
|
|||||||
-- Variables
|
-- Variables
|
||||||
|
|
||||||
local colors = dofile(os.getenv("HOME") .. "/.cache/wal/colors-hypr.lua")
|
local colors = dofile(os.getenv 'HOME' .. '/.cache/wal/colors-hypr.lua')
|
||||||
|
|
||||||
local activeBorderColor = colors.color14
|
local activeBorderColor = colors.color14
|
||||||
local inactiveBorderColor = colors.background
|
local inactiveBorderColor = colors.background
|
||||||
|
|
||||||
hl.config({
|
hl.config {
|
||||||
-- https://wiki.hyprland.org/Configuring/Variables/#general
|
-- https://wiki.hyprland.org/Configuring/Variables/#general
|
||||||
general = {
|
general = {
|
||||||
gaps_in = 5,
|
gaps_in = 5,
|
||||||
@@ -26,7 +26,7 @@ hl.config({
|
|||||||
allow_tearing = false,
|
allow_tearing = false,
|
||||||
|
|
||||||
-- layout = scrolling, # Change to niri-like side-scrolling layout
|
-- layout = scrolling, # Change to niri-like side-scrolling layout
|
||||||
layout = "dwindle",
|
layout = 'dwindle',
|
||||||
},
|
},
|
||||||
|
|
||||||
-- https://wiki.hyprland.org/Configuring/Variables/#decoration
|
-- https://wiki.hyprland.org/Configuring/Variables/#decoration
|
||||||
@@ -42,7 +42,7 @@ hl.config({
|
|||||||
enabled = true,
|
enabled = true,
|
||||||
range = 2,
|
range = 2,
|
||||||
render_power = 3,
|
render_power = 3,
|
||||||
color = "rgba(1a1a1aee)",
|
color = 'rgba(1a1a1aee)',
|
||||||
},
|
},
|
||||||
|
|
||||||
-- https://wiki.hyprland.org/Configuring/Variables/#blur
|
-- https://wiki.hyprland.org/Configuring/Variables/#blur
|
||||||
@@ -66,9 +66,9 @@ hl.config({
|
|||||||
|
|
||||||
groupbar = {
|
groupbar = {
|
||||||
font_size = 12,
|
font_size = 12,
|
||||||
font_family = "monospace",
|
font_family = 'monospace',
|
||||||
font_weight_active = "ultraheavy",
|
font_weight_active = 'ultraheavy',
|
||||||
font_weight_inactive = "normal",
|
font_weight_inactive = 'normal',
|
||||||
|
|
||||||
indicator_height = 0,
|
indicator_height = 0,
|
||||||
indicator_gap = 5,
|
indicator_gap = 5,
|
||||||
@@ -76,11 +76,11 @@ hl.config({
|
|||||||
gaps_in = 5,
|
gaps_in = 5,
|
||||||
gaps_out = 0,
|
gaps_out = 0,
|
||||||
|
|
||||||
text_color = "rgb(ffffff)",
|
text_color = 'rgb(ffffff)',
|
||||||
text_color_inactive = "rgba(ffffff90)",
|
text_color_inactive = 'rgba(ffffff90)',
|
||||||
col = {
|
col = {
|
||||||
active = "rgba(00000040)",
|
active = 'rgba(00000040)',
|
||||||
inactive = "rgba(00000020)",
|
inactive = 'rgba(00000020)',
|
||||||
},
|
},
|
||||||
|
|
||||||
gradients = true,
|
gradients = true,
|
||||||
@@ -91,7 +91,7 @@ hl.config({
|
|||||||
-- https://wiki.hyprland.org/Configuring/Variables/#animations
|
-- https://wiki.hyprland.org/Configuring/Variables/#animations
|
||||||
animations = {
|
animations = {
|
||||||
-- enabled = no # Disable all animations
|
-- enabled = no # Disable all animations
|
||||||
enabled = true,
|
enabled = false,
|
||||||
},
|
},
|
||||||
-- See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more
|
-- See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more
|
||||||
dwindle = {
|
dwindle = {
|
||||||
@@ -102,7 +102,7 @@ hl.config({
|
|||||||
|
|
||||||
-- See https://wiki.hyprland.org/Configuring/Master-Layout/ for more
|
-- See https://wiki.hyprland.org/Configuring/Master-Layout/ for more
|
||||||
master = {
|
master = {
|
||||||
new_status = "master",
|
new_status = 'master',
|
||||||
},
|
},
|
||||||
|
|
||||||
-- https://wiki.hyprland.org/Configuring/Variables/#misc
|
-- https://wiki.hyprland.org/Configuring/Variables/#misc
|
||||||
@@ -131,39 +131,40 @@ hl.config({
|
|||||||
-- Avoid overly wide single-window layouts on wide screens
|
-- Avoid overly wide single-window layouts on wide screens
|
||||||
-- single_window_aspect_ratio = 1 1,
|
-- single_window_aspect_ratio = 1 1,
|
||||||
},
|
},
|
||||||
})
|
}
|
||||||
|
|
||||||
-- Default curves and animations, see https://wiki.hypr.land/Configuring/Advanced-and-Cool/Animations/
|
-- Default curves and animations, see https://wiki.hypr.land/Configuring/Advanced-and-Cool/Animations/
|
||||||
hl.curve("easeOutQuint", { type = "bezier", points = { { 0.23, 1 }, { 0.32, 1 } } })
|
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('easeInOutCubic', { type = 'bezier', points = { { 0.65, 0.05 }, { 0.36, 1 } } })
|
||||||
hl.curve("linear", { type = "bezier", points = { { 0, 0 }, { 1, 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('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('quick', { type = 'bezier', points = { { 0.15, 0 }, { 0.1, 1 } } })
|
||||||
|
|
||||||
-- Default springs
|
-- Default springs
|
||||||
hl.curve("easy", { type = "spring", mass = 1, stiffness = 71.2633, dampening = 15.8273644 })
|
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 = 'global', enabled = true, speed = 10, bezier = 'default' }
|
||||||
hl.animation({ leaf = "border", enabled = true, speed = 5.39, bezier = "easeOutQuint" })
|
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 = '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 = '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 = '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 = 'fadeIn', enabled = true, speed = 1.73, bezier = 'almostLinear' }
|
||||||
hl.animation({ leaf = "fadeOut", enabled = true, speed = 1.46, 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 = 'fade', enabled = true, speed = 3.03, bezier = 'quick' }
|
||||||
hl.animation({ leaf = "layers", enabled = true, speed = 3.81, bezier = "easeOutQuint" })
|
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 = '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 = 'layersOut', enabled = true, speed = 1.5, bezier = 'linear', style = 'fade' }
|
||||||
hl.animation({ leaf = "fadeLayersIn", enabled = true, speed = 1.79, bezier = "almostLinear" })
|
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 = 'fadeLayersOut', enabled = true, speed = 1.39, bezier = 'almostLinear' }
|
||||||
hl.animation({ leaf = "workspaces", enabled = true, speed = 1.94, bezier = "almostLinear", style = "fade" })
|
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 = '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 = 'workspacesOut', enabled = true, speed = 1.94, bezier = 'almostLinear', style = 'fade' }
|
||||||
hl.animation({ leaf = "zoomFactor", enabled = true, speed = 7, bezier = "quick" })
|
hl.animation { leaf = 'zoomFactor', enabled = true, speed = 7, bezier = 'quick' }
|
||||||
|
|
||||||
-- Style Gum confirm to match terminal theme
|
-- Style Gum confirm to match terminal theme
|
||||||
hl.env("GUM_CONFIRM_PROMPT_FOREGROUND", "6") -- Cyan
|
hl.env('GUM_CONFIRM_PROMPT_FOREGROUND', '6') -- Cyan
|
||||||
hl.env("GUM_CONFIRM_SELECTED_FOREGROUND", "0") -- Black
|
hl.env('GUM_CONFIRM_SELECTED_FOREGROUND', '0') -- Black
|
||||||
hl.env("GUM_CONFIRM_SELECTED_BACKGROUND", "2") -- Green
|
hl.env('GUM_CONFIRM_SELECTED_BACKGROUND', '2') -- Green
|
||||||
hl.env("GUM_CONFIRM_UNSELECTED_FOREGROUND", "7") -- White
|
hl.env('GUM_CONFIRM_UNSELECTED_FOREGROUND', '7') -- White
|
||||||
hl.env("GUM_CONFIRM_UNSELECTED_BACKGROUND", "8") -- Dark grey
|
hl.env('GUM_CONFIRM_UNSELECTED_BACKGROUND', '8') -- Dark grey
|
||||||
|
|
||||||
|
|||||||
@@ -77,3 +77,21 @@ hl.bind('switch:on:Lid Switch', function()
|
|||||||
setup_monitors()
|
setup_monitors()
|
||||||
end)
|
end)
|
||||||
|
|
||||||
|
hl.on('monitor.focused', function()
|
||||||
|
local workspace = hl.get_active_workspace()
|
||||||
|
if hl.get_active_special_workspace() then
|
||||||
|
workspace = hl.get_active_special_workspace()
|
||||||
|
end
|
||||||
|
if not workspace then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
local layout = workspace.tiled_layout
|
||||||
|
|
||||||
|
local monitor = hl.get_active_monitor()
|
||||||
|
|
||||||
|
if monitor.description == 'BOE NE160QDM-NZ6' then
|
||||||
|
hl.workspace_rule { workspace = 'name:' .. tostring(workspace.name), layout = 'monocle' }
|
||||||
|
end
|
||||||
|
end)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user