Don't init prettify-symbols-mode in special modes
Or eshell, term and comint modes.
This commit is contained in:
parent
ee91748613
commit
04c66829eb
1 changed files with 8 additions and 6 deletions
|
@ -14,13 +14,15 @@ besides what is listed.")
|
||||||
(setq prettify-symbols-unprettify-at-point 'right-edge)
|
(setq prettify-symbols-unprettify-at-point 'right-edge)
|
||||||
|
|
||||||
(defun +pretty-code|init-pretty-symbols ()
|
(defun +pretty-code|init-pretty-symbols ()
|
||||||
"Enabled `prettify-symbols-mode'.
|
"Enable `prettify-symbols-mode'.
|
||||||
|
|
||||||
If the current major mode is disabled in `+pretty-code-enabled-modes', this
|
If in fundamental-mode, or a mode derived from special, comint, eshell or term
|
||||||
function does nothing. Otherwise, it sets the value of
|
modes, this function does nothing.
|
||||||
`prettify-code-symbols-alist' according to `+pretty-code-symbols-alist' for the
|
|
||||||
current major mode."
|
Otherwise it builds `prettify-code-symbols-alist' according to
|
||||||
(unless (eq major-mode 'fundamental-mode)
|
`+pretty-code-symbols-alist' for the current major-mode."
|
||||||
|
(unless (or (eq major-mode 'fundamental-mode)
|
||||||
|
(derived-mode-p 'special-mode 'comint-mode 'eshell-mode 'term-mode))
|
||||||
(when (or (eq +pretty-code-enabled-modes t)
|
(when (or (eq +pretty-code-enabled-modes t)
|
||||||
(if (eq (car +pretty-code-enabled-modes) 'not)
|
(if (eq (car +pretty-code-enabled-modes) 'not)
|
||||||
(not (memq major-mode (cdr +pretty-code-enabled-modes)))
|
(not (memq major-mode (cdr +pretty-code-enabled-modes)))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue