diff options
| author | Andrew Innes | 1999-05-02 20:39:19 +0000 |
|---|---|---|
| committer | Andrew Innes | 1999-05-02 20:39:19 +0000 |
| commit | 81af6e72e267e16bdf3c122bbaaa99e242abaa46 (patch) | |
| tree | 239e095e94b2e01ee69a017a836b2486cb17655f | |
| parent | 27401ec762a3101e6ab8a162ca5f96e1d520fabb (diff) | |
| download | emacs-81af6e72e267e16bdf3c122bbaaa99e242abaa46.tar.gz emacs-81af6e72e267e16bdf3c122bbaaa99e242abaa46.zip | |
(mouse-set-font): Ensure constructed fontset
matches the font selected in the dialog.
| -rw-r--r-- | lisp/term/w32-win.el | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/lisp/term/w32-win.el b/lisp/term/w32-win.el index 5f1f6d4ab09..39eb15bac29 100644 --- a/lisp/term/w32-win.el +++ b/lisp/term/w32-win.el | |||
| @@ -900,7 +900,7 @@ with the font." | |||
| 900 | (if (fboundp 'new-fontset) | 900 | (if (fboundp 'new-fontset) |
| 901 | (append w32-fixed-font-alist (list (generate-fontset-menu))))))) | 901 | (append w32-fixed-font-alist (list (generate-fontset-menu))))))) |
| 902 | (if fonts | 902 | (if fonts |
| 903 | (let (font fontset) | 903 | (let (font fontset xlfd resolved-font) |
| 904 | (while fonts | 904 | (while fonts |
| 905 | (condition-case nil | 905 | (condition-case nil |
| 906 | (progn | 906 | (progn |
| @@ -908,7 +908,17 @@ with the font." | |||
| 908 | (if (fontset-name-p font) | 908 | (if (fontset-name-p font) |
| 909 | (setq fontset font) | 909 | (setq fontset font) |
| 910 | (condition-case nil | 910 | (condition-case nil |
| 911 | (setq fontset (create-fontset-from-ascii-font font)) | 911 | (setq resolved-font (x-resolve-font-name font) |
| 912 | xlfd (x-decompose-font-name resolved-font) | ||
| 913 | fontset | ||
| 914 | (create-fontset-from-ascii-font | ||
| 915 | font resolved-font | ||
| 916 | (format "%s_%s_%s_%s" | ||
| 917 | (aref xlfd xlfd-regexp-family-subnum) | ||
| 918 | (aref xlfd xlfd-regexp-registry-subnum) | ||
| 919 | (aref xlfd xlfd-regexp-encoding-subnum) | ||
| 920 | (aref xlfd | ||
| 921 | xlfd-regexp-pixelsize-subnum)))) | ||
| 912 | (error nil))) | 922 | (error nil))) |
| 913 | (if fontset | 923 | (if fontset |
| 914 | (set-default-font fontset) | 924 | (set-default-font fontset) |