Ar an seachtú lá is fiche de mí Iúil, scríobh Mike FABIAN:
[...] Is there a possibility to set a preference list of Unicode →
Mule
mappings which is used always?
Yes, but you don’t want to do that; it would mean disabling
set-language-unicode-precedence list, for one. For what you’re looking for,
it is enough to put a call to that function in startup.el, after the call to
init-mule-at-startup and before the window system initialisation code. For
reference, the patch I tested that with is below; I tested it with an XEmacs
that had a windows-1252 coding system with the non-Latin-1 characters mapped
into the jit-ucs-charset-0 character set.
(If you’re planning on distributing code with that Windows-1252 coding
system, by the way, you will also want the change in
http://mid.gmane.org/18091.3408.152729.823883@parhasard.net )
It looks like Ben’s original design intended to set the language Unicode
precedence list during the language environment setup, which would have, to
a certain extent, avoided this problem. But not for the specific characters
you’re talking about.
> I had planned to make available an XEmacs with Unicode as an
internal
> encoding (and I have most of the necessary work for that on my disk),
> but I don’t think that is maintainable in the presence of both the Mule
> and the non-Mule compilation options (which means, in the presence of
> Unicode internally, four ./configure options with which everything
> needs to be tested when anyone makes any change that’s relevant to
> character encoding). And the elimination of the non-Mule compilation
> options has been vetoed, so it looks like users are stuck with the
> internal Mule encoding.
That is really a pity. I think it would be a big advantage to use
Unicode as an internal encoding.
Well, thanks to your earlier suggestion for just-in-time mapping the Unicode
code point support is much better right now than it was. And I hope to
commit another patch soon that preserves invalid UTF-8 sequences on
decoding, which avoids the problem where Latin-1 files can be corrupted if
they are opened as UTF-8 and then a small change is made. See
http://mid.gmane.org/18082.9316.913823.211586@parhasard.net .
But yes, for adding real support for things like shaping, bidirectional
text, the Unicode properties, composite characters and so on, using Unicode
as an internal encoding is the only practical thing.
Index: startup.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/startup.el,v
retrieving revision 1.58
diff -u -u -r1.58 startup.el
--- startup.el 2007/05/25 15:47:56 1.58
+++ startup.el 2007/07/28 09:08:23
@@ -713,6 +713,9 @@
(when (featurep 'mule)
(declare-fboundp (init-mule-at-startup)))
+ (set-language-unicode-precedence-list
+ '(ascii latin-iso8859-1 latin-iso8859-2 latin-iso8859-3 latin-iso8859-4
jit-ucs-charset-0 thai-tis620 greek-iso8859-7 arabic-iso8859-6 hebrew-iso8859-8
katakana-jisx0201 latin-jisx0201 cyrillic-iso8859-5 latin-iso8859-9 latin-iso8859-15
composite control-1 japanese-jisx0208-1978 chinese-gb2312 japanese-jisx0208 korean-ksc5601
japanese-jisx0212 chinese-cns11643-1 chinese-cns11643-2 chinese-big5-1 chinese-big5-2
arabic-digit arabic-1-column arabic-2-column chinese-sisheng latin-iso8859-16
indian-is13194 lao latin-iso8859-14 ipa vietnamese-viscii-upper vietnamese-viscii-lower
jit-ucs-charset-0 chinese-cns11643-3 chinese-cns11643-4 chinese-cns11643-5
chinese-cns11643-6 chinese-cns11643-7 chinese-isoir165 ethiopic indian-2-column
indian-1-column japanese-jisx0213-1 japanese-jisx0213-2 thai-xtis tibetan
tibetan-1-column))
+
(if (featurep 'toolbar)
(if (featurep 'infodock)
(require 'id-x-toolbar)
--
On the quay of the little Black Sea port, where the rescued pair came once
more into contact with civilization, Dobrinton was bitten by a dog which was
assumed to be mad, though it may only have been indiscriminating. (Saki)
_______________________________________________
XEmacs-Beta mailing list
XEmacs-Beta(a)xemacs.org
http://calypso.tux.org/cgi-bin/mailman/listinfo/xemacs-beta