]> code.delx.au - gnu-emacs/commitdiff
If a resolved ASCII font name doesn't conform to
authorKenichi Handa <handa@m17n.org>
Wed, 11 Nov 1998 03:36:15 +0000 (03:36 +0000)
committerKenichi Handa <handa@m17n.org>
Wed, 11 Nov 1998 03:36:15 +0000 (03:36 +0000)
full XLFD, don't try get information of WEIGHT and SLANT from that
font name.

lisp/term/x-win.el

index d9370a66536f345c1e3e4dc6c32fb7e7365a7bf3..4728a05eda3876ea70f34203493444f52f8c3c1d 100644 (file)
@@ -708,18 +708,17 @@ This is in addition to the primary selection.")
                (let ((weight (aref xlfd-fields xlfd-regexp-weight-subnum))
                      (slant (aref xlfd-fields xlfd-regexp-slant-subnum))
                      xlfd-temp)
-                 (if (or (not weight) (string-match "[*?]*" weight))
-                     (progn
-                       (setq xlfd-temp (x-decompose-font-name resolved-name))
-                       (aset xlfd-fields xlfd-regexp-weight-subnum
-                             (aref xlfd-temp xlfd-regexp-weight-subnum))))
-                 (if (or (not slant) (string-match "[*?]*" slant))
-                     (progn
-                       (or xlfd-temp
-                           (setq xlfd-temp
-                                 (x-decompose-font-name resolved-name)))
-                       (aset xlfd-fields xlfd-regexp-slant-subnum
-                             (aref xlfd-temp xlfd-regexp-slant-subnum)))))
+                 (if (and (or (not weight) (string-match "[*?]*" weight))
+                          (setq xlfd-temp
+                                (x-decompose-font-name resolved-name)))
+                     (aset xlfd-fields xlfd-regexp-weight-subnum
+                           (aref xlfd-temp xlfd-regexp-weight-subnum)))
+                 (if (and (or (not slant) (string-match "[*?]*" slant))
+                          (or xlfd-temp
+                              (setq xlfd-temp
+                                    (x-decompose-font-name resolved-name))))
+                     (aset xlfd-fields xlfd-regexp-slant-subnum
+                           (aref xlfd-temp xlfd-regexp-slant-subnum))))
                (setq fontset (x-compose-font-name xlfd-fields))
                (create-fontset-from-fontset-spec
                 (concat fontset ", ascii:" font) styles)