diff --git a/modules/ui/modeline/config.el b/modules/ui/modeline/config.el index e25aa9fd0..a7212ee61 100644 --- a/modules/ui/modeline/config.el +++ b/modules/ui/modeline/config.el @@ -503,8 +503,8 @@ Meant for `+modeline-buffer-path-function'." (cond ((eq category 'coding-category-undecided) "") ((or (eq category 'coding-category-utf-8) - (eq (plist-get sys :name) 'prefer-utf-8)) - "UTF-8 ") + (string-match-p "utf-8" (symbol-name (plist-get sys :name)))) + "") ((concat (upcase (symbol-name (plist-get sys :name))) " "))) 'help-echo (plist-get (coding-system-plist buffer-file-coding-system) :docstring)))))