diff lisp/mule/mule-charset.el @ 3659:98af8a976fc3

[xemacs-hg @ 2006-11-05 22:31:31 by aidan] Support specifying fonts for particular character sets in Mule; support translation to ISO 10646-1 for Mule character sets without an otherwise matching font; move to a vector of X11-charset-X11-registry instead of a regex for the charset-registry property.
author aidan
date Sun, 05 Nov 2006 22:31:46 +0000
parents 04a435415e1d
children 3131094eed8c
line wrap: on
line diff
--- a/lisp/mule/mule-charset.el	Sat Nov 04 22:51:03 2006 +0000
+++ b/lisp/mule/mule-charset.el	Sun Nov 05 22:31:46 2006 +0000
@@ -106,12 +106,31 @@
       0
     1))
 
-;; Not in Emacs/Mule
+;; Not in GNU Emacs/Mule
 (defun charset-registry (charset)
   "Return the registry of CHARSET.
 This is a regular expression matching the registry field of fonts
 that can display the characters in CHARSET."
-  (charset-property charset 'registry))
+  (lwarn 'xintl 'warning 
+    "charset-registry is obsolete--use charset-registries instead. ")
+  (when (charset-property charset 'registries)
+    (elt (charset-property charset 'registries) 0)))
+
+(defun charset-registries (charset)
+  "Return the registries of CHARSET."
+  (charset-property charset 'registries))
+
+(defun set-charset-registry (charset registry)
+  "Obsolete; use set-charset-registries instead. "
+  (check-argument-type 'stringp registry)
+  (check-argument-type 'charsetp (find-charset charset))
+  (unless (equal registry (regexp-quote registry))
+    (lwarn 'xintl 'warning
+      "Regexps no longer allowed for charset-registry. Treating %s%s"
+      registry " as a string."))
+  (set-charset-registries 
+   charset 
+   (apply 'vector registry (append (charset-registries charset) nil))))
 
 (defun charset-ccl-program (charset)
   "Return the CCL program of CHARSET.