[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/descr-text.el
From: |
Juri Linkov |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/descr-text.el |
Date: |
Tue, 19 Jul 2005 07:23:14 -0400 |
Index: emacs/lisp/descr-text.el
diff -c emacs/lisp/descr-text.el:1.36 emacs/lisp/descr-text.el:1.37
*** emacs/lisp/descr-text.el:1.36 Mon Jul 4 23:08:52 2005
--- emacs/lisp/descr-text.el Tue Jul 19 11:23:14 2005
***************
*** 479,491 ****
(format ", U+%04X" unicode)
"")))
("charset"
! ,(symbol-name charset)
,(format "(%s)" (charset-description charset)))
("code point"
,(let ((split (split-char char)))
! (if (= (charset-dimension charset) 1)
! (format "%d" (nth 1 split))
! (format "%d %d" (nth 1 split) (nth 2 split)))))
("syntax"
,(let ((syntax (syntax-after pos)))
(with-temp-buffer
--- 479,503 ----
(format ", U+%04X" unicode)
"")))
("charset"
! ,`(widget-create 'link
! :notify (lambda (&rest ignore)
! (describe-character-set ',charset))
! ,(symbol-name charset))
,(format "(%s)" (charset-description charset)))
("code point"
,(let ((split (split-char char)))
! `(widget-create
! 'link
! :notify (lambda (&rest ignore)
! (list-charset-chars ',charset)
! (with-selected-window
! (get-buffer-window "*Character List*")
! (goto-char (point-min))
! (search-forward ,(char-to-string char)
! nil t)))
! ,(if (= (charset-dimension charset) 1)
! (format "%d" (nth 1 split))
! (format "%d %d" (nth 1 split) (nth 2 split))))))
("syntax"
,(let ((syntax (syntax-after pos)))
(with-temp-buffer
***************
*** 512,518 ****
(if (consp key-list)
(list "type"
(mapconcat #'(lambda (x) (concat "\"" x "\""))
! key-list " or ")))))
("buffer code"
,(encoded-string-description
(string-as-unibyte (char-to-string char)) nil))
--- 524,537 ----
(if (consp key-list)
(list "type"
(mapconcat #'(lambda (x) (concat "\"" x "\""))
! key-list " or ")
! "with"
! `(widget-create
! 'link
! :notify (lambda (&rest ignore)
! (describe-input-method
! ',current-input-method))
! ,(format "%s" current-input-method))))))
("buffer code"
,(encoded-string-description
(string-as-unibyte (char-to-string char)) nil))
***************
*** 536,546 ****
(format "by display table entry [%s] (see below)"
(mapconcat
#'(lambda (x)
! (if (> (car x) #x7ffff)
! (format "?%c<face-id=%s>"
! (logand (car x) #x7ffff)
! (lsh (car x) -19))
! (format "?%c" (car x))))
disp-vector " ")))
(composition
(let ((from (car composition))
--- 555,561 ----
(format "by display table entry [%s] (see below)"
(mapconcat
#'(lambda (x)
! (format "?%c" (logand (car x) #x7ffff)))
disp-vector " ")))
(composition
(let ((from (car composition))
***************
*** 571,581 ****
(if display
(format "terminal code %s" display)
"not encodable for terminal"))))))
,@(let ((unicodedata (and unicode
(describe-char-unicode-data unicode))))
(if unicodedata
(cons (list "Unicode data" " ") unicodedata)))))
! (setq max-width (apply #'max (mapcar #'(lambda (x) (length (car x)))
item-list)))
(with-output-to-temp-buffer "*Help*"
(with-current-buffer standard-output
--- 586,616 ----
(if display
(format "terminal code %s" display)
"not encodable for terminal"))))))
+ ,@(let ((face
+ (if (not (or disp-vector composition))
+ (cond
+ ((and show-trailing-whitespace
+ (save-excursion (goto-char pos)
+ (looking-at "[ \t]+$")))
+ 'trailing-whitespace)
+ ((and nobreak-char-display unicode (eq unicode '#xa0))
+ 'nobreak-space)
+ ((and nobreak-char-display unicode (eq unicode '#xad))
+ 'escape-glyph)
+ ((and (< char 32) (not (memq char '(9 10))))
+ 'escape-glyph)))))
+ (if face (list (list "hardcoded face"
+ `(widget-create
+ 'link
+ :notify (lambda (&rest ignore)
+ (describe-face ',face))
+ ,(format "%s" face))))))
,@(let ((unicodedata (and unicode
(describe-char-unicode-data unicode))))
(if unicodedata
(cons (list "Unicode data" " ") unicodedata)))))
! (setq max-width (apply #'max (mapcar #'(lambda (x)
! (if (cadr x) (length (car x)) 0))
item-list)))
(with-output-to-temp-buffer "*Help*"
(with-current-buffer standard-output
***************
*** 585,597 ****
(when (cadr elt)
(insert (format formatter (car elt)))
(dolist (clm (cdr elt))
! (when (>= (+ (current-column)
! (or (string-match "\n" clm)
! (string-width clm)) 1)
! (window-width))
! (insert "\n")
! (indent-to (1+ max-width)))
! (insert " " clm))
(insert "\n"))))
(save-excursion
--- 620,635 ----
(when (cadr elt)
(insert (format formatter (car elt)))
(dolist (clm (cdr elt))
! (if (eq (car-safe clm) 'widget-create)
! (progn (insert " ") (eval clm))
! (when (>= (+ (current-column)
! (or (string-match "\n" clm)
! (string-width clm))
! 1)
! (window-width))
! (insert "\n")
! (indent-to (1+ max-width)))
! (insert " " clm)))
(insert "\n"))))
(save-excursion
***************
*** 619,625 ****
(format "%s (0x%02X)" (cadr (aref disp-vector i))
(cddr (aref disp-vector i)))
"-- no font --")
! "\n ")))
(insert "these terminal codes:\n")
(dotimes (i (length disp-vector))
(insert (car (aref disp-vector i))
--- 657,677 ----
(format "%s (0x%02X)" (cadr (aref disp-vector i))
(cddr (aref disp-vector i)))
"-- no font --")
! "\n")
! (when (> (car (aref disp-vector i)) #x7ffff)
! (let* ((face-id (lsh (car (aref disp-vector i)) -19))
! (face (car (delq nil (mapcar (lambda (face)
! (and (eq (face-id
face)
! face-id)
face))
! (face-list))))))
! (when face
! (insert (propertize " " 'display '(space :align-to 5))
! "face: ")
! (widget-create 'link
! :notify `(lambda (&rest ignore)
! (describe-face ',face))
! (format "%S" face))
! (insert "\n"))))))
(insert "these terminal codes:\n")
(dotimes (i (length disp-vector))
(insert (car (aref disp-vector i))
***************
*** 667,673 ****
(describe-text-mode)))))
(defalias 'describe-char-after 'describe-char)
! (make-obsolete 'describe-char-after 'describe-char "21.5")
(provide 'descr-text)
--- 719,725 ----
(describe-text-mode)))))
(defalias 'describe-char-after 'describe-char)
! (make-obsolete 'describe-char-after 'describe-char "22.1")
(provide 'descr-text)