zsh-users
 help / color / mirror / code / Atom feed
From: "Bart Schaefer" <schaefer@candle.brasslantern.com>
To: Ville Herva <vherva@babbage.tky.hut.fi>, zsh-users@sunsite.auc.dk
Subject: Re: zsh & HP Term
Date: Fri, 28 Apr 2000 04:19:29 +0000	[thread overview]
Message-ID: <1000428041929.ZM21670@candle.brasslantern.com> (raw)
In-Reply-To: <20000427110231.A3075@babbage.tky.hut.fi>

On Apr 27, 11:02am, Ville Herva wrote:
} Subject: Re: zsh & HP Term
}
} Propably not strictly related to zsh, but I'll ask anyway: I'm having a
} bit different problem with terminal under HPUX 10.20. Most if not all
} programs I run seem to ruin my terminal settings so that when I return to
} zsh, arrow keys work no more.

Many terminals have two modes, the "normal" mode and the "keypad" mode.
The arrow keys often send different character sequences in the different
modes.  What's happening is that your terminal is getting switched from
one mode to the other and not switched back.  This is probably a result
of a problem with the termcap or terminfo description of your terminal.

The easiest thing to do is use bindkey to bind both the keypad and normal
arrow key sequences to the same ZLE actions.  Most probably that means
something like this:

bindkey '\e[A'	up-line-or-history
bindkey '\e[B'	down-line-or-history
bindkey '\e[C'	forward-char
bindkey '\e[D'	backward-char
bindkey '\eOA'	up-line-or-history
bindkey '\eOB'	down-line-or-history
bindkey '\eOC'	forward-char
bindkey '\eOD'	backward-char

If you use the vi keybindings, which it looks as though you might from
your description of the symptoms, then you should use:

bindkey -v
bindkey '\e[A'	vi-up-line-or-history
(etc., putting "vi-" into each of the above examples)

Hey, PWS:  You might want to mention keypad mode in the FAQ answer 3.8.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com


  reply	other threads:[~2000-04-28  4:20 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-04-27  8:02 Ville Herva
2000-04-28  4:19 ` Bart Schaefer [this message]
2000-04-28 12:27   ` Ville Herva
  -- strict thread matches above, loose matches on Subject: below --
2000-03-31 17:16 rodriguez_ruggeberg
2000-04-02  5:20 ` Bart Schaefer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1000428041929.ZM21670@candle.brasslantern.com \
    --to=schaefer@candle.brasslantern.com \
    --cc=vherva@babbage.tky.hut.fi \
    --cc=zsh-users@sunsite.auc.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).