Function: ghostel--cursor-blink-start
ghostel--cursor-blink-start is a natively compiled function defined in
ghostel.el.
Signature
(ghostel--cursor-blink-start)
Documentation
Begin blinking the cursor.
No-op on text terminals, when already blinking, or when the global
blink-cursor-mode(var)/blink-cursor-mode(fun) already drives the blink (avoids a double beat).
Source Code
;; Defined in /nix/store/1252krff0gb2kisjcpp45m50cpdskfrl-emacs-packages-deps/share/emacs/site-lisp/ghostel.el
(defun ghostel--cursor-blink-start ()
"Begin blinking the cursor.
No-op on text terminals, when already blinking, or when the global
`blink-cursor-mode' already drives the blink (avoids a double beat)."
(when (and (display-graphic-p)
(not ghostel--cursor-blink-timer)
(not blink-cursor-mode))
(add-hook 'kill-buffer-hook #'ghostel--cursor-blink-stop nil t)
;; Restore the cursor when the blinked window switches buffers, so a window
;; left in the blink's "off" phase never hides the next buffer's cursor.
(add-hook 'window-buffer-change-functions
#'ghostel--cursor-blink-restore-window nil t)
(setq ghostel--cursor-blink-window (selected-window))
(setq ghostel--cursor-blink-timer
(run-with-timer blink-cursor-interval blink-cursor-interval
#'ghostel--cursor-blink-tick (current-buffer)))))