문제

I have a file (output from a program) that includes VT-100 escape sequences (colors, bold face, etc.). When I open the file in Fundamental mode, the escape sequences appear as are, and are not interpreted. How can display the file with the VT-100 sequences recognized as colors, etc?

도움이 되었습니까?

해결책

See https://unix.stackexchange.com/questions/19494/how-to-colorize-text-in-emacs

For example: put the following in your emacs init file:

(define-derived-mode fundamental-ansi-mode fundamental-mode "fundamental ansi"
  "Fundamental mode that understands ansi colors."
  (require 'ansi-color)
  (ansi-color-apply-on-region (point-min) (point-max)))

then run M-x fundamental-ansi-mode on the buffer with the escape sequences.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top