From: Kenichi Handa Date: Fri, 23 Apr 2004 02:08:22 +0000 (+0000) Subject: (char-displayable-p): Simplified by using internal-char-font. X-Git-Tag: ttn-vms-21-2-B4~6638 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=44416f23ab21dfbc8adb741875c47fd3f657a562;p=emacs.git (char-displayable-p): Simplified by using internal-char-font. --- diff --git a/lisp/international/mule-util.el b/lisp/international/mule-util.el index 3a3539359ec..1d1fe539116 100644 --- a/lisp/international/mule-util.el +++ b/lisp/international/mule-util.el @@ -373,27 +373,7 @@ basis, this may not be accurate." ;; On a window system, a character is displayable if we have ;; a font for that character in the default face of the ;; currently selected frame. - (let ((fontset (frame-parameter (selected-frame) 'font)) - font-pattern) - (if (query-fontset fontset) - (setq font-pattern (fontset-font fontset char))) - (or font-pattern - (setq font-pattern (fontset-font "fontset-default" char))) - (if font-pattern - (progn - ;; Now FONT-PATTERN is a string or a cons of family - ;; field pattern and registry field pattern. - (or (stringp font-pattern) - (let ((family (or (car font-pattern) "*")) - (registry (or (cdr font-pattern) "*"))) - (or (string-match "-" family) - (setq family (concat "*-" family))) - (or (string-match "-" registry) - (setq registry (concat registry "-*"))) - (setq font-pattern - (format "-%s-*-*-*-*-*-*-*-*-*-*-%s" - family registry)))) - (x-list-fonts font-pattern 'default (selected-frame) 1))))) + (car (internal-char-font nil char))) (t (let ((coding (terminal-coding-system))) (if coding