Show tabs with a different character (Emacs)

后端 未结 4 1042
眼角桃花
眼角桃花 2020-12-24 13:39

I\'d be happy to have very soft character \">>\" instead of white-space, like this:

Mono develop http://primates.ximian.com/~miguel/pictures/Valabinding-classpad.png

相关标签:
4条回答
  • 2020-12-24 14:34

    Use "M-:" (M-x eval-expression) and enter the following expression:

    (let ((d (make-display-table)))
      (aset d 9 (vector ?> ?>))
      (set-window-display-table nil d))
    

    To get back to normal enter:

    (set-window-display-table nil nil)
    
    0 讨论(0)
  • 2020-12-24 14:42

    On my Emacs version (24.3) no additional modules are needed. It's enough to launch

    M-x whitespace-mode
    

    To customize go to whitespace-style variable help,

    C-h C-h v whitespace-style
    

    This mode has many functionalities. To made it simpler one may choose not to use `Face visualization'.

    0 讨论(0)
  • 2020-12-24 14:44

    EDIT: Just realized that blank-mode is superseded by whitespace. Load this and customize whitespace-style to at least contain tabs and tabs-mark. I currently have:

    (setq whitespace-style '(trailing tabs newline tab-mark newline-mark))
    

    There is also blank-mode which allows you to achive what you want and it gives you some nice functions to cleanup the whitespace to your likings: http://www.emacswiki.org/emacs/BlankMode

    0 讨论(0)
  • 2020-12-24 14:44

    Google search brought up show whitespace-mode. Haven't tried it myself.

    0 讨论(0)
提交回复
热议问题