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

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

Font Glyph bug


From: gnu-emacs-hacker
Subject: Font Glyph bug
Date: Sun, 16 May 2004 19:39:17 -0400 (EDT)

In GNU Emacs 21.3.3 (i386-unknown-freebsd4.8, X toolkit, Xaw3d scroll bars)
 of 2003-06-08 on grant.org
Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: nil
  locale-coding-system: nil
  default-enable-multibyte-characters: t

Please describe exactly what actions triggered the bug
and the precise symptoms of the bug:

$ emacs -q --no-site-file -nw

Paste the code below and type M-x eval-buffer for a slide show
of correct and incorrect displays at two seconds per display.

(defun demo-font-glyph-bug ()
  (interactive)
  (save-window-excursion
    (delete-other-windows)
                                        ;(select-window (split-window nil (- 
(window-height) 8)))
    (set-window-buffer nil (get-buffer-create "*demo-font-lock-glyph-bug*"))
    (or buffer-display-table
        (setq buffer-display-table (make-display-table)))
    (erase-buffer)
    (font-lock-mode -1)
    (insert "\n \^C\^O\^N\^T\^R\^O\^L ")
    (dolist (font-lock '(("plain" nil)
                         ("font" (set-text-properties (point-min) (point-max)
                                                      '(face 
font-lock-comment-face)))))
      (dolist (control '(("char" ?!)
                         ("glyph" (create-glyph "!"))))
        (eval (cadr font-lock))
        (set-display-table-slot buffer-display-table 'control (eval (cadr 
control)))
        (save-excursion
          (insert (format "<-- %s %s --"
                          (car font-lock) (car control)))
          (point))
        (sit-for 2)
        (delete-region (point) (point-max))))
    (message "Glyph/char bug demo done.  (aref glyph-table %d) => %S\n\
All four cases should have displayed !C!O!N!T!R!O!L."
             (display-table-slot buffer-display-table 'control)
             (aref glyph-table (display-table-slot buffer-display-table 
'control)))))

(demo-font-glyph-bug)
(setq glyph-table ["0" "1" "2" "3" "4" "5" "6" "7"])
(demo-font-glyph-bug)
(setq glyph-table ["0" "1" "2" "3" "4" "5" "6" "7" "8"])
(demo-font-glyph-bug)

Recent messages:
Loading font-lock...
Loading regexp-opt...done
Loading font-lock...done
Glyph/char bug demo done.  (aref glyph-table 1) => "!"
All cases should have displayed !C!O!N!T!R!O!L.
Glyph/char bug demo done.  (aref glyph-table 9) => "!"
All cases should have displayed !C!O!N!T!R!O!L.
Glyph/char bug demo done.  (aref glyph-table 10) => "!"
All cases should have displayed !C!O!N!T!R!O!L.
Loading emacsbug...done




reply via email to

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