mirror of
https://github.com/prdlk/dotfiles.git
synced 2026-11-02 11:32:42 +00:00
144 lines
5.3 KiB
Lua
144 lines
5.3 KiB
Lua
-- Change the default Omarchy look'n'feel.
|
|
--
|
|
-- Load order is Omarchy defaults -> current theme's hyprland.lua -> this file
|
|
-- (see $OMARCHY_PATH/default/hypr/omarchy.lua), so whatever is set here is the
|
|
-- last writer and wins over the theme. That is the point of this file: a theme
|
|
-- picks colours, the compositor's feel stays ours.
|
|
|
|
-- Flat by default, glass for terminals only.
|
|
--
|
|
-- Stock quattro is rounding 0, blur off, shadow off
|
|
-- ($OMARCHY_PATH/default/hypr/looknfeel.lua); themes that ship a hyprland.lua
|
|
-- turn all three on for every window (Cyberdream and Spectra both did), which
|
|
-- on this box is a bad trade: blur over an eDP panel plus a 5K Studio Display
|
|
-- is real frame time on an iGPU sharing system memory, and Chromium/Electron
|
|
-- windows cannot paint a transparent background, so fading them just shows
|
|
-- wallpaper where page background should be.
|
|
--
|
|
-- Blur has to be enabled globally to exist at all -- there is no positive
|
|
-- `blur` window rule, only `no_blur`, and kitty's own `background_blur` (the
|
|
-- ext-background-effect-v1 protocol, which Hyprland 0.56 does implement) is a
|
|
-- no-op while decoration:blur:enabled is false. So: switch it on here, then
|
|
-- opt every window out again except the terminals below.
|
|
hl.config({
|
|
general = {
|
|
-- Scrolling (niri-style tape) instead of Omarchy's dwindle. Per-workspace
|
|
-- layouts saved by omarchy-hyprland-workspace-layout-toggle (SUPER + W;
|
|
-- ~/.local/state/omarchy/workspace-layouts/*.lua) still win for the
|
|
-- workspaces they name.
|
|
layout = "scrolling",
|
|
},
|
|
|
|
decoration = {
|
|
rounding = 0,
|
|
|
|
-- Backdrop behind every scratch (special) workspace: the desktop under it
|
|
-- is darkened by this fraction.
|
|
dim_special = 0.33,
|
|
|
|
blur = {
|
|
enabled = true,
|
|
-- Cheaper than the themes' size 6 / 3 passes; with only terminals
|
|
-- blurred this is a handful of quads per frame, not the whole screen.
|
|
size = 5,
|
|
passes = 2,
|
|
brightness = 0.8,
|
|
contrast = 1.1,
|
|
vibrancy = 0.15,
|
|
noise = 0.01,
|
|
new_optimizations = true,
|
|
popups = false,
|
|
},
|
|
|
|
shadow = {
|
|
enabled = false,
|
|
},
|
|
},
|
|
|
|
group = {
|
|
groupbar = {
|
|
-- Square tab plates, to match rounding = 0 above.
|
|
gradient_rounding = 0,
|
|
},
|
|
},
|
|
})
|
|
|
|
-- Omarchy tags every mapped window `default-opacity` and fades it to
|
|
-- 0.985 / 0.96 ($OMARCHY_PATH/default/hypr/windows.lua); that stock fade is
|
|
-- kept. Rules are last-match-wins, so this only opts every window out of the
|
|
-- blur enabled above -- the few percent of wallpaper that shows through an
|
|
-- inactive window is the same as stock, where blur is off entirely.
|
|
o.window({ tag = "default-opacity" }, { no_blur = true })
|
|
|
|
-- The exception: terminals carry their own alpha (kitty's
|
|
-- `background_opacity`, 0.9 in ~/.config/kitty/kitty.conf), so they are the one
|
|
-- surface where blurring the backdrop buys anything. Full class list because
|
|
-- the kitty hosts run under their own app-ids (kitty-herdr, kitty-tmux,
|
|
-- kitty-goliath) and Omarchy tags nothing as `terminal`.
|
|
o.window(
|
|
"^(kitty(-.*)?|Alacritty|com\\.mitchellh\\.ghostty|foot|org\\.codeberg\\.dnkl\\.foot|wezterm)$",
|
|
{ no_blur = false }
|
|
)
|
|
|
|
-- Themes are also free to re-enable the workspace slide (Spectra sets
|
|
-- `workspaces` with its "flow" bezier); Omarchy's default is off. Restate it.
|
|
-- workspacesIn/workspacesOut are not overridden anywhere, so they inherit this.
|
|
hl.animation({ leaf = "workspaces", enabled = false })
|
|
|
|
-- Slow, constant rotation of the active-border gradient (the theme's
|
|
-- hyprland_active_border; Cyberdream's is accent -> cyan). `loop` restarts
|
|
-- the angle each turn so it never eases or stops; speed is deciseconds per
|
|
-- revolution, so 100 = one lap every 10 s. Costs a redraw of the border each
|
|
-- frame while a window is mapped.
|
|
hl.animation({ leaf = "borderangle", enabled = true, speed = 100, bezier = "linear", style = "loop" })
|
|
|
|
-- https://wiki.hypr.land/Configuring/Basics/Variables/#general
|
|
-- hl.config({
|
|
-- general = {
|
|
-- -- No gaps between windows or borders.
|
|
-- gaps_in = 0,
|
|
-- gaps_out = 0,
|
|
-- border_size = 0,
|
|
--
|
|
-- -- Change to niri-like side-scrolling layout.
|
|
-- layout = "scrolling",
|
|
-- },
|
|
-- })
|
|
|
|
-- https://wiki.hypr.land/Configuring/Basics/Variables/#animations
|
|
-- hl.config({
|
|
-- animations = {
|
|
-- -- Disable all animations.
|
|
-- enabled = false,
|
|
-- },
|
|
-- })
|
|
|
|
-- https://wiki.hypr.land/Configuring/Basics/Variables/#layout
|
|
-- hl.config({
|
|
-- layout = {
|
|
-- -- Avoid overly wide single-window layouts on wide screens.
|
|
-- single_window_aspect_ratio = { 1, 1 },
|
|
-- },
|
|
-- })
|
|
|
|
-- Scrolling layout, matched to niri's layout block
|
|
-- (~/.config/niri/config.d/20-layout-and-overview.kdl). Wins over Omarchy's
|
|
-- column_width = 0.49.
|
|
hl.config({
|
|
scrolling = {
|
|
-- default-column-width { proportion 0.5; }
|
|
column_width = 0.5,
|
|
-- preset-column-widths; SUPER + R / SUPER + SHIFT + R cycle these
|
|
-- (colresize +conf / -conf via omarchy-cycle-window-size).
|
|
explicit_column_widths = "0.333, 0.5, 0.667",
|
|
-- center-focused-column "never": scroll only as far as needed to fit the
|
|
-- focused column. SUPER + C centers on demand.
|
|
focus_fit_method = 1,
|
|
-- niri keeps a lone column at its own width instead of filling the screen.
|
|
fullscreen_on_one_column = false,
|
|
-- niri stops at the first/last column instead of wrapping around.
|
|
wrap_focus = false,
|
|
wrap_swapcol = false,
|
|
},
|
|
})
|