help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: emacs coding system


From: Reiner Steib
Subject: Re: emacs coding system
Date: Sat, 13 Nov 2004 12:28:51 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/21.3.50 (gnu/linux)

On Sat, Nov 13 2004, Edward Casey wrote:

> "Reiner Steib" <reinersteib+from-uce@imap.cc> wrote...
[...]
>> (set-language-environment "UTF-8") if you use Emacs 21.3 or CVS Emacs.
>> Probably you can also use `prefer-coding-system' and friends, see the
>> manual for details:
>>
>> (info "(emacs)Recognize Coding")
>> (info "(emacs)Language Environments")
[...]
> I.
> What's the difference between (set-language-environment "UTF-8") and
> putting something like form below in .emacs? :
>
> (custom-set-variables
>    '(case-fold-search t)
>    '(current-language-environment "UTF-8")

How about reading the manual node that I have posted above?  ;-) Both
methods are equivalent:

,----[ (info "(emacs)Language Environments") ]
|    To select a language environment, you can customize the variable
| `current-language-environment' or use the command `M-x
| set-language-environment'.  It makes no difference which buffer is
| current when you use this command, because the effects apply globally to
| the Emacs session.
`----

>    '(default-input-method "latin-4-postfix"))
[...]
> I want to add upper and lower case y with macron to the
> \leim\quail\latin-post.el code. [...] The code points are U+0232 and
> U+0233 

AFAIK, the input methods are not well documented.  But it should work
like this:

--8<---------------cut here---------------start------------->8---
(when (and (load "quail/latin-post" t)
           ;; side effect: also change the default input method:
           (setq default-input-method "latin-4-postfix"))
  (quail-defrule "Y-" (decode-char 'ucs #x0232) "latin-4-postfix")
  (quail-defrule "y-" (decode-char 'ucs #x0233) "latin-4-postfix"))
--8<---------------cut here---------------end--------------->8---

Let's test it: `Y -' ==> Ȳ, and `y -' ==> ȳ.  Seem to work for me.

BTW: Using the TeX input method, you can get the characters
with `\ = Y' and `\ = y'.

> but I don't know how to insert these characters into the lisp code.

The thread with the subject "Unicode literals" in comp.emacs might
also be of interest for you:
http://groups.google.com/groups?rnum=1&threadm=m2lld7o3mh.fsf@seki.fr

Bye, Reiner.
-- 
       ,,,
      (o o)
---ooO-(_)-Ooo---  |  PGP key available  |  http://rsteib.home.pages.de/


reply via email to

[Prev in Thread] Current Thread [Next in Thread]