help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How can I change a buffer-local glyphless char table?


From: Nick Helm
Subject: How can I change a buffer-local glyphless char table?
Date: Wed, 06 Jun 2018 14:27:59 +1200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (darwin)

Occasionally, I find it useful to use
glyphless-char-display-control to visualise normally invisible
characters. I do this with something like:

  (update-glyphless-char-display 'glyphless-char-display-control
    '((c0-control     . empty-box)
      (c1-control     . empty-box)
      (format-control . empty-box)
      (no-font        . hex-code)))

and turn it off again with:

  (update-glyphless-char-display 'glyphless-char-display-control
    (eval (car (get 'glyphless-char-display-control
                    'standard-value))))

However this has a global effect. I would like it to only act on the
current buffer. I've tried creating a buffer-local char table with:

  (make-local-variable 'glyphless-char-display)

and repeating the call to update-glyphless-char-display, but it
affects both local and global values regardless.

If I make glyphless-char-display buffer-local and tweak its value
directly, it works fine.

Any ideas how I can do this more easily?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]