updated kitty/ghostty etx

This commit is contained in:
liphh committed 2026-10-01 19:51:14 +02:00
1 parent 6079f6639b
commit 71b27f5ab7
31 files changed
+3784 -564

No files matched your search

+47 -37
View File
@@ -1,56 +1,66 @@
## name: Rosé Pine Moon
## author: mvllow
## license: MIT
## upstream: https://github.com/rose-pine/kitty/blob/main/dist/rose-pine-moon.conf
## blurb: All natural pine, faux fur and a bit of soho vibes for the classy minimalist
# https://draculatheme.com/kitty
#
# Installation instructions:
#
# cp dracula.conf ~/.config/kitty/
# echo "include dracula.conf" >> ~/.config/kitty/kitty.conf
#
# Then reload kitty for the config to take affect.
# Alternatively copy paste below directly into kitty.conf
foreground #e0def4
background #232136
selection_foreground #e0def4
selection_background #44415a
foreground #f8f8f2
background #282a36
selection_foreground #ffffff
selection_background #44475a
cursor #56526e
cursor_text_color #e0def4
url_color #c4a7e7
active_tab_foreground #e0def4
active_tab_background #393552
inactive_tab_foreground #6e6a86
inactive_tab_background #232136
active_border_color #3e8fb0
inactive_border_color #44415a
url_color #8be9fd
# black
color0 #393552
color8 #6e6a86
color0 #21222c
color8 #6272a4
# red
color1 #eb6f92
color9 #eb6f92
color1 #ff5555
color9 #ff6e6e
# green
color2 #3e8fb0
color10 #3e8fb0
color2 #50fa7b
color10 #69ff94
# yellow
color3 #f6c177
color11 #f6c177
color3 #f1fa8c
color11 #ffffa5
# blue
color4 #9ccfd8
color12 #9ccfd8
color4 #bd93f9
color12 #d6acff
# magenta
color5 #c4a7e7
color13 #c4a7e7
color5 #ff79c6
color13 #ff92df
# cyan
color6 #ea9a97
color14 #ea9a97
color6 #8be9fd
color14 #a4ffff
# white
color7 #e0def4
color15 #e0def4
color7 #f8f8f2
color15 #ffffff
# Cursor colors
cursor #f8f8f2
cursor_text_color background
# Tab bar colors
active_tab_foreground #282a36
active_tab_background #f8f8f2
inactive_tab_foreground #282a36
inactive_tab_background #6272a4
# Marks
mark1_foreground #282a36
mark1_background #ff5555
# Splits/Windows
active_border_color #f8f8f2
inactive_border_color #6272a4
File diff suppressed because it is too large. Load diff
+1 -1
View File
@@ -1,5 +1,5 @@
# BEGIN_KITTY_THEME
# Gruvbox Material
# Rosé Pine Moon
include current-theme.conf
# END_KITTY_THEME
#
@@ -0,0 +1,5 @@
startgroup
animation_start cursor-trail-move
animation_stop cursor-trail-stop
shaders cursor-trail-blaze
endgroup
@@ -0,0 +1,134 @@
#language slang 2026
// Copyright (C) 2026 Kovid Goyal <kovid at kovidgoyal.net>
// Distributed under terms of the GPLv3 license.
//
// Blaze cursor trail — port of https://gist.github.com/chardskarth/95874c54e29da6b5a36ab7b50ae2d088
// by chardskarth. Draws a fading parallelogram trail from the previous cursor
// position to the current one, coloured with an amber fill and red-orange border.
// Ported to slang for kitty
import kitty_custom_shader_types;
static const float4 TRAIL_COLOR = float4(1.0, 0.725, 0.161, 1.0);
static const float4 TRAIL_COLOR_ACCENT = float4(1.0, 0.0, 0.0, 1.0);
// Trail lifetime in seconds.
static const float DURATION = 0.5;
// pow(1 - x, 10) via repeated squaring — branchless ease-out.
static float
ease_out10(float x) {
float y = 1.0 - x;
float y2 = y * y;
float y4 = y2 * y2;
return y4 * y4 * y2;
}
// Smooth blend curve for the progress value.
static float
blend_smooth(float t) {
float s = t * t;
return s / (2.0 * (s - t) + 1.0);
}
// SDF of an axis-aligned box. p = query point, center = box centre, hext = half-extents.
static float
sdBox(float2 p, float2 center, float2 hext) {
float2 d = abs(p - center) - hext;
return length(max(d, float2(0.0))) + min(max(d.x, d.y), 0.0);
}
// Single edge contribution for the quadrilateral SDF (signed winding accumulation).
static float
seg(float2 p, float2 a, float2 b, inout float s, float d) {
float2 e = b - a;
float2 w = p - a;
float2 proj = a + e * clamp(dot(w, e) / dot(e, e), 0.0, 1.0);
d = min(d, dot(p - proj, p - proj));
float c0 = step(0.0, p.y - a.y);
float c1 = 1.0 - step(0.0, p.y - b.y);
float c2 = 1.0 - step(0.0, e.x * w.y - e.y * w.x);
float allCond = c0 * c1 * c2;
float noneCond = (1.0 - c0) * (1.0 - c1) * (1.0 - c2);
s *= lerp(1.0, -1.0, step(0.5, allCond + noneCond));
return d;
}
// SDF of an arbitrary quadrilateral (uses winding number via four edge contributions).
static float
sdQuad(float2 p, float2 v0, float2 v1, float2 v2, float2 v3) {
float s = 1.0;
float d = dot(p - v0, p - v0);
d = seg(p, v0, v3, s, d);
d = seg(p, v1, v0, s, d);
d = seg(p, v2, v1, s, d);
d = seg(p, v3, v2, s, d);
return s * sqrt(d);
}
// Returns 0 for diagonal movement (up-left / down-right), 1 otherwise.
// Selects which corner of the parallelogram aligns with the movement direction.
static float
movementVertexFactor(float2 a, float2 b) {
float c1 = step(b.x, a.x) * step(a.y, b.y);
float c2 = step(a.x, b.x) * step(b.y, a.y);
return 1.0 - max(c1, c2);
}
public float4
fragment_main(float4 color, KittyTextures t, KittyCustomShaderData d) {
if (d.cursor_trail_color.a <= 0.0) return color;
float age = clamp((d.timestamp - d.cursor_trail_change_time) / DURATION, 0.0, 1.0);
if (age >= 1.0) return color;
float easedProgress = ease_out10(blend_smooth(age));
if (easedProgress <= 0.0) return color;
// Work in pixel space for correct aspect-ratio distance measurements.
float2 pixelDims = float2(d.viewport_size_pixels) * t.viewport.zw;
float2 px = t.pos * pixelDims;
// Current cursor rect in pixel space (edge: .x=left .y=right .z=top .w=bottom, y-up).
float curLeft = d.cursor_trail_edge.x * pixelDims.x;
float curRight = d.cursor_trail_edge.y * pixelDims.x;
float curTop = d.cursor_trail_edge.z * pixelDims.y;
float curBottom = d.cursor_trail_edge.w * pixelDims.y;
float curWidth = curRight - curLeft;
float curHeight = curTop - curBottom;
float2 curCenter = float2((curLeft + curRight) * 0.5, (curTop + curBottom) * 0.5);
float prevLeft = d.cursor_trail_prev_edge.x * pixelDims.x;
float prevTop = d.cursor_trail_prev_edge.z * pixelDims.y;
float prevBottom = d.cursor_trail_prev_edge.w * pixelDims.y;
float2 prevCenter = float2(
(d.cursor_trail_prev_edge.x + d.cursor_trail_prev_edge.y) * 0.5 * pixelDims.x,
(d.cursor_trail_prev_edge.z + d.cursor_trail_prev_edge.w) * 0.5 * pixelDims.y);
float lineLength = length(curCenter - prevCenter);
// Alpha fades to 0 at the previous-cursor end, reaching full effect at the current cursor.
float alphaModifier = min(length(px - curCenter) / (lineLength * easedProgress), 1.0);
// Build parallelogram vertices in pixel space.
float vf = movementVertexFactor(curCenter, prevCenter);
float ivf = 1.0 - vf;
float2 v0 = float2(lerp(curLeft, curRight, vf), curBottom);
float2 v1 = float2(lerp(curLeft, curRight, ivf), curTop);
float2 v2 = float2(prevLeft + curWidth * ivf, prevTop);
float2 v3 = float2(prevLeft + curWidth * vf, prevBottom);
float sdfCursor = sdBox(px, curCenter, float2(curWidth, curHeight) * 0.5);
float sdfTrail = sdQuad(px, v0, v1, v2, v3);
// ~2-pixel anti-aliasing range in pixel space.
float aaRange = 2.0;
float4 newColor = color;
// Inner border accent (red-orange inside the trail edges).
newColor = lerp(newColor, TRAIL_COLOR_ACCENT, 1.0 - smoothstep(sdfTrail, -aaRange, aaRange * 0.05));
// Main amber fill.
newColor = lerp(newColor, TRAIL_COLOR, 1.0 - smoothstep(0.0, aaRange, sdfTrail));
// Fade: effect is weakest toward the previous cursor end.
newColor = lerp(color, newColor, 1.0 - alphaModifier);
// Restore original pixels inside the cursor rectangle.
return lerp(newColor, color, step(sdfCursor, 0.0));
}
@@ -0,0 +1,19 @@
# Dracula purple with pink accent (default)
startgroup
var float4 TRAIL_COLOR = float4(0.51, 0.29, 0.95, 1.0)
var float4 TRAIL_COLOR_ACCENT = float4(1.00, 0.19, 0.56, 1.0)
animation_start cursor-trail-move
animation_stop cursor-trail-stop
shaders cursor-trail-blaze
endgroup
# Alternate combos (comment out the two lines above, uncomment these):
# ---- cyan + green ----
# var float4 TRAIL_COLOR = float4(0.26, 0.82, 0.98, 1.0) # #8be9fd
# var float4 TRAIL_COLOR_ACCENT = float4(0.08, 0.96, 0.20, 1.0) # #50fa7b
# ---- orange + pink ----
# var float4 TRAIL_COLOR = float4(1.00, 0.48, 0.15, 1.0) # #ffb86c
# var float4 TRAIL_COLOR_ACCENT = float4(1.00, 0.19, 0.56, 1.0) # #ff79c6
# ---- yellow + pink ----
# var float4 TRAIL_COLOR = float4(0.88, 0.96, 0.26, 1.0) # #f1fa8c
# var float4 TRAIL_COLOR_ACCENT = float4(1.00, 0.19, 0.56, 1.0) # #ff79c6
@@ -0,0 +1,19 @@
# Dracula purple with pink accent (default)
startgroup
var float4 TRAIL_COLOR = float4(0.51, 0.29, 0.95, 1.0)
var float4 TRAIL_COLOR_ACCENT = float4(1.00, 0.19, 0.56, 1.0)
animation_start cursor-trail-move
animation_stop cursor-trail-stop
shaders cursor-trail-blaze
endgroup
# Alternate combos (comment out the two lines above, uncomment these):
# ---- cyan + green ----
# var float4 TRAIL_COLOR = float4(0.26, 0.82, 0.98, 1.0) # #8be9fd
# var float4 TRAIL_COLOR_ACCENT = float4(0.08, 0.96, 0.20, 1.0) # #50fa7b
# ---- orange + pink ----
# var float4 TRAIL_COLOR = float4(1.00, 0.48, 0.15, 1.0) # #ffb86c
# var float4 TRAIL_COLOR_ACCENT = float4(1.00, 0.19, 0.56, 1.0) # #ff79c6
# ---- yellow + pink ----
# var float4 TRAIL_COLOR = float4(0.88, 0.96, 0.26, 1.0) # #f1fa8c
# var float4 TRAIL_COLOR_ACCENT = float4(1.00, 0.19, 0.56, 1.0) # #ff79c6