summaryrefslogtreecommitdiff
path: root/lisp/descr-text.el
diff options
context:
space:
mode:
authorKenichi Handa <handa@m17n.org>2009-11-19 01:11:47 +0000
committerKenichi Handa <handa@m17n.org>2009-11-19 01:11:47 +0000
commitb2f0be0f79c0275c1677fee1a2ff62c42febc623 (patch)
tree02a60b48b0dae41037534aaa94360ff7965055e1 /lisp/descr-text.el
parent9f0ad26051de9994255555ada66dc41ebc89fb32 (diff)
downloademacs-b2f0be0f79c0275c1677fee1a2ff62c42febc623.tar.gz
(describe-char-padded-string): Compose with TAB
only if there's a font for CH. (describe-char): Fix the condition for detecting a trivial composition.
Diffstat (limited to 'lisp/descr-text.el')
-rw-r--r--lisp/descr-text.el7
1 files changed, 5 insertions, 2 deletions
diff --git a/lisp/descr-text.el b/lisp/descr-text.el
index 77b6bb8254d..c952ef1d796 100644
--- a/lisp/descr-text.el
+++ b/lisp/descr-text.el
@@ -353,7 +353,9 @@ This function is semi-obsolete. Use `get-char-code-property'."
;; Return a string of CH with composition for padding on both sides.
;; It is displayed without overlapping with the left/right columns.
(defsubst describe-char-padded-string (ch)
- (compose-string (string ch) 0 1 (format "\t%c\t" ch)))
+ (if (internal-char-font nil ch)
+ (compose-string (string ch) 0 1 (format "\t%c\t" ch))
+ (string ch)))
;; Return a nicely formated list of categories; extended category
;; description is added to the category name as a tooltip
@@ -446,7 +448,8 @@ as well as widgets, buttons, overlays, and text properties."
(setq glyph (lgstring-glyph components j))
(= (lglyph-from glyph) glyph-from))
(setq j (1+ j)))
- (if (and (= i (1- j))
+ (if (and (= to (1+ from))
+ (= i (1- j))
(setq glyph (lgstring-glyph components i))
(= char (lglyph-char glyph)))
;; The composition is trivial.