From f8395e36a1cc9497e023ea976daa6722761d52c9 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 3 Sep 2018 09:48:53 +0530 Subject: [PATCH] Draw underlines under the text instead of over it --- docs/changelog.rst | 2 ++ kitty/cell_fragment.glsl | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/changelog.rst b/docs/changelog.rst index fc8c5fbb7..a6ffc6bdb 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -12,6 +12,8 @@ Changelog - Fix legacy invocation of icat as `kitty icat` not working (:iss:`850`) +- Draw underlines under the text instead of over it + 0.12.0 [2018-09-01] ------------------------------ diff --git a/kitty/cell_fragment.glsl b/kitty/cell_fragment.glsl index f9eaf768d..689e2334e 100644 --- a/kitty/cell_fragment.glsl +++ b/kitty/cell_fragment.glsl @@ -64,7 +64,7 @@ vec4 calculate_foreground() { // Since strike and text are the same color, we simply add the alpha values float combined_alpha = min(text_alpha + strike_alpha, 1.0f); // Underline color might be different, so alpha blend - vec4 ans = alpha_blend(decoration_fg, underline_alpha * effective_text_alpha, fg, combined_alpha * effective_text_alpha); + vec4 ans = alpha_blend(fg, combined_alpha * effective_text_alpha, decoration_fg, underline_alpha * effective_text_alpha); return mix(ans, cursor_color_vec, cursor_alpha); } #endif