On Thu, Jun 08, 2000 at 12:15:55 +0300, Baurjan Ismagulov wrote:
> hi,
>
> i have to change my charset frequently. currently, i'm typing ":set
> c<TAB>="<charset> (occasionally, "charset" is the first keyword
> completed). but after that i have to type "iso-8859-9" and "koi8-r"
> manually each time, which is quite annoying. how can i speed up
> this process?
You could use macros to change charset. One for each charset:
macro index <Esc>TI 'set charset=iso-8859-9' 'Change to iso-8859-9'
macro index <Esc>TK 'set charset=koi8-r' 'Change to koi8-r'
It is also possible to make a real toggle. This example uses an
external script:
macro index <Esc>T 'set charset=`charset-toggle`' 'Toggle charset'
where "charset-toggle" contains something like:
#!/bin/sh
# Find the current charset:
if test -f charset; then
charset=`cat charset`
else
charset=koi8-r
fi
# Toggle to the other charset:
if test $charset = koi8-r; then
charset=iso-8859-9
else
charset=koi8-r
fi
# save and output the new value:
echo $charset > charset
echo $charset
> btw, i still can't mix two languages in the single message. mime gurus?
If you use UTF-8, you can mix any languages.
--
Byrial
http://home.worldonline.dk/~byrial/