fix(god): remove hard coding of cursor color

This commit is contained in:
p4v4n 2023-02-18 11:17:35 +05:30 committed by GitHub
parent 7ba11a62ef
commit aa079b0e3c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,8 +1,5 @@
;;; editor/god/autoload.el -*- lexical-binding: t; -*-
(defvar +god-default-color (face-background 'cursor)
"Default cursor and bar color.")
(defvar +god-read-only-mode-color "Gray"
"Cursor and bar color when `read-only-mode' is enabled.")
@ -29,7 +26,7 @@
(cond (buffer-read-only +god-read-only-mode-color)
(is-fill-overflow +god-fill-overflow-color)
(overwrite-mode +god-overwrite-mode-color)
(t +god-default-color))))
(t previous-cursor-color))))
(setq cursor-type next-cursor-type)
(unless (eq previous-cursor-color next-cursor-and-modeline-color)
(set-cursor-color next-cursor-and-modeline-color))