From 884ff0e52d2c7690bcc9e165d0542a2ad983eae9 Mon Sep 17 00:00:00 2001 From: tomo Date: Mon, 26 Aug 2002 08:41:52 +0000 Subject: [PATCH] (get_char_table): Add special code for the standard case table to use character attribute `->downcase' and `->uppercase' for case operations in UTF-2000. --- src/chartab.c | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/src/chartab.c b/src/chartab.c index 1a22127..ed78ba6 100644 --- a/src/chartab.c +++ b/src/chartab.c @@ -2061,7 +2061,26 @@ Lisp_Object get_char_table (Emchar ch, Lisp_Char_Table *ct) { #ifdef UTF2000 - return get_char_id_table (ct, ch); + { + Lisp_Object ret = get_char_id_table (ct, ch); + +#ifdef HAVE_DATABASE + if (NILP (ret)) + { + if (EQ (CHAR_TABLE_NAME (ct), Qdowncase)) + ret = Fget_char_attribute (make_char (ch), Q_lowercase, Qnil); + else if (EQ (CHAR_TABLE_NAME (ct), Qflippedcase)) + ret = Fget_char_attribute (make_char (ch), Q_uppercase, Qnil); + if (CONSP (ret)) + { + ret = XCAR (ret); + if (CONSP (ret)) + ret = Ffind_char (ret); + } + } +#endif + return ret; + } #elif defined(MULE) { Lisp_Object charset; -- 1.7.10.4