all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* how to display a character with a specific glyph and face ?
@ 2014-10-23 12:57 Boiteux Frederic
  2014-10-23 15:44 ` Eli Zaretskii
  0 siblings, 1 reply; 7+ messages in thread
From: Boiteux Frederic @ 2014-10-23 12:57 UTC (permalink / raw)
  To: help-gnu-emacs

	Hello,


When I was using Emacs23, I had a piece of config to display « no-break space » character with another glyph (centered dot) an a specific face (with a blue background) :

(make-face 'nbsp-face)
(set-face-background 'nbsp-face "LightBlue")

(require 'disp-table)
(aset standard-display-table
      (make-char 'latin-iso8859-1  (- ?\240 128))
      (vector (+ ?\267 (* 524288 (face-id 'nbsp-face)))))

It was very helpful when editing text mixing standard and no-break spaces. 
Now, I use Emacs24 and mainly UTF-8 encoded files/buffers, and I tried to do the same, without success. I tried :

(aset standard-display-table
      #xA0 ;; NO-BREAK SPACE
      (vector (+ #xB7 ;; MIDDLE DOT
                 (* 524288 (face-id 'nbsp-face)))))

But it doesn't work as expected : I get an Unicode character not mapped to a glyph (giving a number written in a square), with a red background (!).

Do you know how I could do this display with Emacs24 ?

    With regards,
               Fred.





^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2014-10-24 14:49 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <mailman.11860.1414070397.1147.help-gnu-emacs@gnu.org>
2014-10-23 13:30 ` how to display a character with a specific glyph and face ? Stefan Monnier
2014-10-24  6:14   ` Boiteux Frederic
2014-10-24  7:02     ` Eli Zaretskii
     [not found]     ` <<837fzq6jbw.fsf@gnu.org>
2014-10-24 14:01       ` Drew Adams
2014-10-24 14:49         ` Boiteux Frederic
2014-10-23 12:57 Boiteux Frederic
2014-10-23 15:44 ` Eli Zaretskii

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.