aboutsummaryrefslogtreecommitdiff
path: root/autoload/relative-numbers.kak
diff options
context:
space:
mode:
authorAkshay Nair <phenax5@gmail.com>2026-06-12 10:01:40 +0530
committerAkshay Nair <phenax5@gmail.com>2026-06-12 10:02:38 +0530
commit0daf54486bceddf399930bcb8777d9e5f24ad003 (patch)
treef2ecdaa3931d432c04e65a55cb2b76847b62007b /autoload/relative-numbers.kak
parent4af1b7773819d0f04f50471057ac680a10402a93 (diff)
downloadkakoune-config-0daf54486bceddf399930bcb8777d9e5f24ad003.tar.gz
kakoune-config-0daf54486bceddf399930bcb8777d9e5f24ad003.zip
Split init file
Diffstat (limited to 'autoload/relative-numbers.kak')
-rw-r--r--autoload/relative-numbers.kak22
1 files changed, 22 insertions, 0 deletions
diff --git a/autoload/relative-numbers.kak b/autoload/relative-numbers.kak
new file mode 100644
index 0000000..2e3163b
--- /dev/null
+++ b/autoload/relative-numbers.kak
@@ -0,0 +1,22 @@
+# declare-option line-specs relative_markers
+
+# define-command -hidden update_relative_markers %{
+# evaluate-commands %sh{
+# indicators=14
+# line_specs=$(seq $(($indicators + 1)) | while IFS= read n; do
+# diff=$(echo "($n - ($indicators/2) - 1) * 5" | bc)
+# line=$(echo "$kak_cursor_line + $diff" | bc)
+# if [ "$line" -gt 0 ] && [ ! "$line" = "$kak_cursor_line" ]; then
+# echo -e "$line|{gray}$(echo "$diff" | sed 's/^-//')"
+# fi
+# done);
+# echo "set-option window relative_markers %val{timestamp} $(printf ' %s' $line_specs)"
+# }
+# }
+
+# hook global WinCreate .* %{
+# hook window NormalIdle .* %{ update_relative_markers }
+# }
+
+# add-highlighter global/ flag-lines blue relative_markers
+