From 5591115248ee778cbd33cb3463a259621745686d Mon Sep 17 00:00:00 2001 From: Daniel Fichtinger Date: Thu, 26 Jun 2025 14:44:47 -0400 Subject: [PATCH] AutoYADM commit: 2025-06-26 14:44:47 --- .config/kak/autoload/filetype.kak | 14 +++++++------- .config/kak/autoload/search-highlight.kak | 6 ++++++ .config/kak/kakrc | 3 +++ 3 files changed, 16 insertions(+), 7 deletions(-) diff --git a/.config/kak/autoload/filetype.kak b/.config/kak/autoload/filetype.kak index 3818a38b..4f3f5dff 100644 --- a/.config/kak/autoload/filetype.kak +++ b/.config/kak/autoload/filetype.kak @@ -82,13 +82,13 @@ hook global WinSetOption filetype=latex %{ set-option window formatcmd "tex-fmt --stdin" set-option window autowrap_fmtcmd 'tex-fmt --stdin -l %c' set-option window autowrap_format_paragraph true - hook -group latex-auto-format window BufWritePre .* %{ - try format - } - hook -once -always window WinSetOption filetype=.* %{ - unset-option window formatcmd - remove-hooks window latex-auto-format - } + # hook -group latex-auto-format window BufWritePre .* %{ + # try format + # } + # hook -once -always window WinSetOption filetype=.* %{ + # unset-option window formatcmd + # remove-hooks window latex-auto-format + # } # declare-filetype-mode latex # map window latex i } diff --git a/.config/kak/autoload/search-highlight.kak b/.config/kak/autoload/search-highlight.kak index 926d1f72..47d59c74 100644 --- a/.config/kak/autoload/search-highlight.kak +++ b/.config/kak/autoload/search-highlight.kak @@ -1,3 +1,7 @@ +## kak-search-highlight: interactive highlighting of search terms +## Author: Daniel Fichtinger sr.ht/~ficd +## License: ISC + provide-module search-highlight %— ## begin public options declare-option -docstring %{ @@ -36,10 +40,12 @@ provide-module search-highlight %— } } } + # remove the plugin's hooks define-command -hidden search-highlight-disable-impl %{ remove-hooks window search-highlight } + ## begin public commands define-command -docstring %{ Enable search highlighting. Press in normal mode to clear diff --git a/.config/kak/kakrc b/.config/kak/kakrc index f49ee0da..e746663e 100644 --- a/.config/kak/kakrc +++ b/.config/kak/kakrc @@ -155,7 +155,10 @@ hook global WinCreate .* %{ # and it makes it easy to see trailing spaces add-highlighter window/show-whitespaces show-whitespaces -only-trailing add-highlighter window/show-matching show-matching + # TODO: update plugin so it auto clears if escaped out of search, + # but if search is accepted then auto clear on in normal mode? require-module search-highlight + set window search_highlight_face %exp{%opt{orange_golden}+u} search-highlight-enable }