Variable: hl-line-overlay
hl-line-overlay is a buffer-local variable defined in hl-line.el.gz.
Documentation
Overlay used by Hl-Line mode to highlight the current line.
Source Code
;; Defined in /usr/src/emacs/lisp/hl-line.el.gz
;;; hl-line.el --- highlight the current line -*- lexical-binding:t -*-
;; Copyright (C) 1998, 2000-2022 Free Software Foundation, Inc.
;; Author: Dave Love <fx@gnu.org>
;; Maintainer: emacs-devel@gnu.org
;; Created: 1998-09-13
;; Keywords: faces, frames, emulations
;; This file is part of GNU Emacs.
;; GNU Emacs is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>.
;;; Commentary:
;; Provides a local minor mode (toggled by M-x hl-line-mode) and
;; a global minor mode (toggled by M-x global-hl-line-mode) to
;; highlight, on a suitable terminal, the line on which point is. The
;; global mode highlights the current line in the selected window only
;; (except when the minibuffer window is selected). This was
;; implemented to satisfy a request for a feature of Lesser Editors.
;; The local mode is sticky: it highlights the line about the buffer's
;; point even if the buffer's window is not selected. Caveat: the
;; buffer's point might be different from the point of a non-selected
;; window. Set the variable `hl-line-sticky-flag' to nil to make the
;; local mode behave like the global mode.
;; You probably don't really want to use the global mode; if the
;; cursor is difficult to spot, try changing its color, relying on
;; `blink-cursor-mode' or both. The hookery used might affect
;; response noticeably on a slow machine. The local mode may be
;; useful in non-editing buffers such as Gnus or PCL-CVS though.
;; An overlay is used. In the non-sticky cases, this overlay is
;; active only on the selected window. A hook is added to
;; `post-command-hook' to activate the overlay and move it to the line
;; about point.
;; You could make variable `global-hl-line-mode' buffer-local and set
;; it to nil to avoid highlighting specific buffers, when the global
;; mode is used.
;; By default the whole line is highlighted. The range of highlighting
;; can be changed by defining an appropriate function as the
;; buffer-local value of `hl-line-range-function'.
;;; Code:
(defvar-local hl-line-overlay nil
"Overlay used by Hl-Line mode to highlight the current line.")