/* Code conversion functions.
Copyright (C) 1991, 1995 Free Software Foundation, Inc.
Copyright (C) 1995 Sun Microsystems, Inc.
- Copyright (C) 1999,2000,2001,2002,2003,2004 MORIOKA Tomohiko
+ Copyright (C) 1999,2000,2001,2002,2003,2004,2005 MORIOKA Tomohiko
This file is part of XEmacs.
#ifdef UTF2000
Lisp_Object Qutf_8_mcs;
Lisp_Object Qdisable_composition;
+Lisp_Object Qccs_priority_list;
Lisp_Object Quse_entity_reference;
Lisp_Object Qd, Qx, QX;
#endif
parse_charset_conversion_specs (codesys->iso2022.output_conv,
value);
}
+#ifdef UTF2000
+ else if (EQ (key, Qccs_priority_list))
+ {
+ codesys->ccs_priority_list = value;
+ }
+#endif
else
signal_simple_error ("Unrecognized property", key);
}
return XCODING_SYSTEM_DISABLE_COMPOSITION (coding_system) ? Qt : Qnil;
else if (EQ (prop, Quse_entity_reference))
return XCODING_SYSTEM_USE_ENTITY_REFERENCE (coding_system) ? Qt : Qnil;
+ else if (EQ (prop, Qccs_priority_list))
+ return XCODING_SYSTEM_CCS_PRIORITY_LIST (coding_system);
#endif
else if (type == CODESYS_ISO2022)
{
{
Lisp_Object original_default_coded_charset_priority_list
= Vdefault_coded_charset_priority_list;
-
+ Vdefault_coded_charset_priority_list
+ = CODING_SYSTEM_CCS_PRIORITY_LIST (codesys);
+ while (!EQ (Vdefault_coded_charset_priority_list, Qnil))
+ {
+ code_point = ENCODE_CHAR (ch, charset);
+ if (XCHARSET_FINAL (charset))
+ goto found;
+ Vdefault_coded_charset_priority_list
+ = Fcdr (Fmemq (XCHARSET_NAME (charset),
+ Vdefault_coded_charset_priority_list));
+ }
+ Vdefault_coded_charset_priority_list
+ = original_default_coded_charset_priority_list;
while (!EQ (Vdefault_coded_charset_priority_list, Qnil))
{
code_point = ENCODE_CHAR (ch, charset);
#ifdef UTF2000
defsymbol (&Qutf_8_mcs, "utf-8-mcs");
defsymbol (&Qdisable_composition, "disable-composition");
+ defsymbol (&Qccs_priority_list, "ccs-priority-list");
defsymbol (&Quse_entity_reference, "use-entity-reference");
defsymbol (&Qd, "d");
defsymbol (&Qx, "x");
DEFINE_CODESYS_PROP (CODESYS_PROP_ISO2022, Qescape_quoted);
DEFINE_CODESYS_PROP (CODESYS_PROP_ISO2022, Qinput_charset_conversion);
DEFINE_CODESYS_PROP (CODESYS_PROP_ISO2022, Qoutput_charset_conversion);
+#ifdef UTF2000
+ DEFINE_CODESYS_PROP (CODESYS_PROP_ISO2022, Qccs_priority_list);
+#endif
DEFINE_CODESYS_PROP (CODESYS_PROP_CCL, Qencode);
DEFINE_CODESYS_PROP (CODESYS_PROP_CCL, Qdecode);