On 13/03/11 08:46, John Little wrote:
On Mar 13, 7:07 pm, Tony Mechelynck<antoine.mechely...@gmail.com>
wrote:
Are you sure you did it in Console mode?

Well, I thought I had.  But I just tried it, and it worked.  Checking
my bash history, yes I did run vim in gnome-terminal; the plot
thickens.

If I run vim, and type your

     :set t_kb="\x7F"

I never did that.

What didn't work for me was

        :let &t_kb = "\x7F"

which I used precisely because :let (unlike :set) does the double quoted string thing;

what did work was

        :exe 'set t_kb=' . "\x7F"

which is usable in a script, and uses a double quoted string, but otherwise is equivalent to

        :set t_kb=^?

where ^? is entered by Ctrl-V followed by x7F (or by Ctrl-? but not if you know only the hex code, or if you don't know how to produce it with your national keyboard)


then try

     :set t_kb

I get E518.  The set does not do the double quoted string thing, so I
effectively unset it as if I'd typed

     :set t_kb=

and it became an undefined option.  Experimenting, one can set any
option of the form t_xy for any x and y that I tried, including non-
printable characters.  F. ex.

     :set t_^A^B=tony

and unset them by setting them empty.  So there's a bunch of special
handling for terminal options.  Whether it's worth documenting, I'm
not sure, though your original use seems a valid one.

Regards, John


Best regards,
Tony.
--
Then a man said: Speak to us of Expectations.

He then said: If a man does not see or hear the waters of the Jordan,
then he should not taste the pomegranate or ply his wares in an open
market.

If a man would not labour in the salt and rock quarries then he should
not accept of the Earth that which he refuses to give of himself.

Such a man would expect a pear of a peach tree.
Such a man would expect a stone to lay an egg.
Such a man would expect Sears to assemble a lawnmower.
                -- Kehlog Albran, "The Profit"

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Reply via email to