Emacs 27 introduced `display-fill-column-indicator-mode` which replaces `hl-fill-column`. This commit adds some conditionals to use `display-fill-column-indicator-mode` on Emacs 27+, or falls back to `hl-fill-column-mode` on older versions.
12 lines
513 B
EmacsLisp
12 lines
513 B
EmacsLisp
;;; ui/fill-column/autoload.el -*- lexical-binding: t; -*-
|
|
|
|
;;;###autoload (autoload 'hl-fill-column-mode "hl-fill-column" nil t)
|
|
|
|
;;;###autoload
|
|
;; Emacs 27 introduced `display-fill-column-indicator-mode' which should be
|
|
;; used instead of `hl-fill-column-mode'
|
|
(if (>= emacs-major-version 27)
|
|
(add-hook! '(text-mode-hook prog-mode-hook conf-mode-hook)
|
|
#'display-fill-column-indicator-mode)
|
|
(add-hook! '(text-mode-hook prog-mode-hook conf-mode-hook)
|
|
#'hl-fill-column-mode))
|