Can't get --meta8 working
jae at zhar.net
Sun Aug 24 20:37:29 CEST 2008
Carlos Pita wrote:
> Hi all,
> I'm having trouble configuring urxvt to send the 8th bit with alt key. The
> character I see after pressing Alt-<X> is the same one that I see for xterm,
> but I need to press Alt-<X> three times before it appears. I've keyboard
> mappings in vim for <M-X> that are perfectly working under xterm, but are
> not being triggered at all under urxvt --meta8.
My guess is that it is working fine, you just are expecting a different
behaviour than what you are seeing. If you have your LANG set to a Unicode
charset (eg. en_US.UTF-8) then urxvt is interpreting the 8bit char as the
first byte in a 2 byte unicode character.
Eg. using utf8 hold down meta-shift and hit 'c' then '1' fast (ie.
'\xc3\xa1') you should see your 'á' character.
Another way to set this in action is to change your LANG to en_US.iso88591.
Then hitting meta-a will produce the 'á'.
I ran into the same problem with vim and resolved it by not using meta8 at
all and using the standard behaviour of meta sending the escape sequence.
There are a couple tips in the vim wiki about dealing with meta keys
sending escape codes like this.
I took that latter one and wrote a more full featured script. It is well
commented and should just work if you stick it in your ~/.vim/plugins
directory. It's a small script, so I've gone ahead and attached it.
[jae at zhar.net - http://zhar.net]
"It is difficult to produce a television documentary that is both incisive
and probing when every twelve minutes one is interrupted by twelve dancing
rabbits singing about toilet paper." - Rod Serling
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 1350 bytes
Desc: not available
More information about the rxvt-unicode