如何设置显示当前文件编码
-
== utf-8-unix:
Like ‘undecided’ but prefer UTF-8 when appropriate. On decoding, if the source contains 8-bit codes and they all are valid UTF-8 sequences, detect the source as UTF-8 encoding regardless of the coding priority.
On encoding, if the source contains non-ASCII characters, encode them by UTF-8.
Type: undecided (do automatic conversion)
EOL type: LF
U
== utf-8:
UTF-8 (no signature (BOM))
Type: utf-8 (UTF-8: Emacs internal multibyte form)
EOL type: Automatic selection from: [utf-8-unix utf-8-dos utf-8-mac]
看着费劲就顺手改了吧:
内容太多的话可以先只(add-to-list 'mode-line-format '(:eval (format " %s" buffer-file-coding-system)))
把encoding加到最前面,其他不变
2 个赞
感谢 准备试试