From b0db954ad98daa23bf3eb27f246158cb0364b454 Mon Sep 17 00:00:00 2001 From: Simon Pflaumer Date: Sun, 4 Jan 2026 21:42:20 +0000 Subject: [PATCH] ensure the new logic is used for the cursorline visibility check in a previous commit, the logic was changed from simply checking the cursorline option to also considering the related cursorlineopt option to verify that the full cursorline is drawn. there is unfortunately one more spot in the code i've missed --- lua/tiny-inline-diagnostic/highlights.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lua/tiny-inline-diagnostic/highlights.lua b/lua/tiny-inline-diagnostic/highlights.lua index 1791892..2fbdf22 100644 --- a/lua/tiny-inline-diagnostic/highlights.lua +++ b/lua/tiny-inline-diagnostic/highlights.lua @@ -144,7 +144,7 @@ end function M.get_diagnostic_highlights(blend_factor, diag_ret, curline, index_diag) local diag_hi, diag_inv_hi, body_hi = M.get_diagnostic_highlights_from_severity(diag_ret.severity) - local is_cursorline_enabled = vim.opt.cursorline:get() + local cursorline_is_visible = is_cursorline_visible() if (diag_ret.line and diag_ret.line == curline) @@ -161,7 +161,7 @@ function M.get_diagnostic_highlights(blend_factor, diag_ret, curline, index_diag (diag_ret.line and diag_ret.line ~= curline) or index_diag > 1 or diag_ret.need_to_be_under - or not is_cursorline_enabled + or not cursorline_is_visible then diag_inv_hi = diag_inv_hi .. "NoBg" end