Re: Backspace and Delete keys under PuTTY

2002-12-15 Thread Adrian Penisoara
Hi,

On Tue, 10 Dec 2002, Ryan Thompson wrote:

 Jonathan Chen wrote to Adrian Penisoara:
 
  On Tue, Dec 10, 2002 at 01:17:17PM +0200, Adrian Penisoara wrote:
 
  [...]
 
 But I have Bash as the default shell. And yes, it works changing
   the Terminal / Keyboard / Backspace key from Contrl-? (127) to
   Control-H, but the users are pissed off by the fact that Linux
   doesn't need this -- does it mean FreeBSD has broken termcap
   entries or that Linux is just stepping on the traditional
   standards ?
 
  It's Linux that's stepping on standards. Their default config is to
  have erase=DEL. All other UNIX boxen I've used have erase=BACKASPCE.
  I suspect the PUTTY writers have been heavily influenced by Linux.
 

 Here's the explanation from the PuTTY's web documentation page[1]:

-
4.4.1 Changing the action of the Backspace key
Some terminals believe that the Backspace key should send the same thing
to the server as Control-H (ASCII code 8). Other terminals believe that
the Backspace key should send ASCII code 127 (usually known as
Control-?) so that it can be distinguished from Control-H. This option
allows you to choose which code PuTTY generates when you press
Backspace.

If you are connecting to a Unix system, you will probably find that the
Unix stty command lets you configure which the server expects to see, so
you might not need to change which one PuTTY generates. On other
systems, the server's expectation might be fixed and you might have no
choice but to configure PuTTY.

If you do have the choice, we recommend configuring PuTTY to generate
Control-? and configuring the server to expect it, because that allows
applications such as emacs to use Control-H for help.
--

  Should all people go for this ?


 Has anyone taken the time to really fine tune PuTTY's settings to work
 well with FreeBSD and {n}curses apps? Somewhat ironically, the best
 results I have received thus far are to use xterm-color and ^H for
 erase. This works perfectly in tcsh/bash, but suffers somewhat in
 curses or ncurses programs such as PINE or lpe. Results with these
 settings vary depending on the application. PINE, for example, screams
 Unknown Command when I try to use Home/End/Delete/ PgUp/PgDn. With
 lpe, everything works except Home/End. Let me tell you, on a Dvorak
 keyboard, the usual ^Q and ^R aren't exactly intuitive or convenient.
 :-)


 Once again, let's see PuTTY's sideview on their site[1]:

-
4.4.2 Changing the action of the Home and End keys
The Unix terminal emulator rxvt disagrees with the rest of the world
about what character sequences should be sent to the server by the Home
and End keys.

xterm, and other terminals, send ESC [1~ for the Home key, and ESC [4~
for the End key. rxvt sends ESC [H for the Home key and ESC [Ow for the
End key.

If you find an application on which the Home and End keys aren't
working, you could try switching this option to see if it helps.


  On which side are we on ?

  And for this matter let's see how the F? keys are standing on:


4.4.3 Changing the action of the function keys and keypad
This option affects the function keys (F1 to F12) and the top row of the
numeric keypad.

In the default mode, labelled ESC [n~, the function keys generate
sequences like ESC [11~, ESC [12~ and so on. This matches the general
behaviour of Digital's terminals.
In Linux mode, F6 to F12 behave just like the default mode, but F1 to F5
generate ESC [[A through to ESC [[E. This mimics the Linux virtual
console.
In Xterm R6 mode, F5 to F12 behave like the default mode, but F1 to F4
generate ESC OP through to ESC OS, which are the sequences produced by
the top row of the keypad on Digital's terminals.
In VT400 mode, all the function keys behave like the default mode, but
the actual top row of the numeric keypad generates ESC OP through to ESC
OS.
In VT100+ mode, the function keys generate ESC OP through to ESC O[
In SCO mode, the function keys F1 to F12 generate ESC [M through to ESC
[X. Together with shift, they generate ESC [Y through to ESC [j. With
control they generate ESC [k through to ESC [v, and with shift and
control together they generate ESC [w through to ESC [{.

If you don't know what any of this means, you probably don't need to
fiddle with it.


  I know that I had problems with F10 in Midnight Commander in FreeBSD 
connected through PuTTY...

[1] http://www.chiark.greenend.org.uk/~sgtatham/putty/docs.html


 Ady (@freebsd.ady.ro)

| An age is called Dark not because the light fails to shine, but  |
| 

Re: Backspace and Delete keys under PuTTY

2002-12-11 Thread Roman Neuhauser
# [EMAIL PROTECTED] / 2002-12-11 11:04:09 +0200:
 On 2002-12-11 10:52, JacobRhoden [EMAIL PROTECTED] wrote:
  (Oh, and if you were writing an ssh client, would you default the
  settings to the standard, or to what works on all your machines
  *grin*)
 
 Neither.  I'd make it easy to configure the client differently,
 instead :-)

putty fits that bill, it just *defaults* to the linux behavior, and
I believe that's what mr. JacobRhoden meant.

the OP didn't want to have to do those two more clicks when saving
settings for a *BSD box.

-- 
If you cc me or remove the list(s) completely I'll most likely ignore
your message.see http://www.eyrie.org./~eagle/faqs/questions.html

To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message



Re: Backspace and Delete keys under PuTTY

2002-12-10 Thread Marcel Stangenberger
On Tue, 10 Dec 2002, Adrian Penisoara wrote:

   What is the proper solution ? I'd rather prefer to modify the termcaps
 than making adjustments in PuTTY, as some persons get cranky when it
 comes about changing PuTTY settings while Linux works well with the
 defaults.


proper way is to alter the putty settings for your connection to freebsd
machines. Another way is changing the default shell to bash.

Marcel


To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message



Re: Backspace and Delete keys under PuTTY

2002-12-10 Thread Adrian Penisoara
Hi,

On Tue, 10 Dec 2002, Marcel Stangenberger wrote:

 On Tue, 10 Dec 2002, Adrian Penisoara wrote:
 
What is the proper solution ? I'd rather prefer to modify the termcaps
  than making adjustments in PuTTY, as some persons get cranky when it
  comes about changing PuTTY settings while Linux works well with the
  defaults.
 
 
 proper way is to alter the putty settings for your connection to freebsd
 machines. Another way is changing the default shell to bash.

  But I have Bash as the default shell. And yes, it works changing the
Terminal / Keyboard / Backspace key from Contrl-? (127) to
Control-H, but the users are pissed off by the fact that Linux doesn't
need this -- does it mean FreeBSD has broken termcap entries or that
Linux is just stepping on the traditional standards ?

 Ady (@freebsd.ady.ro)

| An age is called Dark not because the light fails to shine, but  |
| because people refuse to see it. |
|   -- James Michener, Space |




To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message



Re: Backspace and Delete keys under PuTTY

2002-12-10 Thread Yann Golanski
Quoth Adrian Penisoara on Tue, Dec 10, 2002 at 13:17:17 +0200
   But I have Bash as the default shell. And yes, it works changing the
 Terminal / Keyboard / Backspace key from Contrl-? (127) to
 Control-H, but the users are pissed off by the fact that Linux doesn't
 need this -- does it mean FreeBSD has broken termcap entries or that
 Linux is just stepping on the traditional standards ?

How about just adding this mapping in the global .bashrc and in
.[t]cshrc in your FreeBSD box.  It's not that hard and will be totaly
transparent to your users since thier .*rc file should source the global
one first.

The same things used to happen between terminal on X11 on Linux.  Eterm
was notoriouse for it a few years ago.

-- 
[EMAIL PROTECTED]  -=*=-  www.kierun.org
PGP:   009D 7287 C4A7 FD4F 1680  06E4 F751 7006 9DE2 6318
IRC:   nick kierun, server spod.uk.amiganet.org, channel #sanctus
NNGS:  nick kierun, server nngs.cosmic.org, port 9696.



msg11624/pgp0.pgp
Description: PGP signature


Re: Backspace and Delete keys under PuTTY

2002-12-10 Thread Marcel Stangenberger
On Tue, 10 Dec 2002, Adrian Penisoara wrote:

 Hi,

 On Tue, 10 Dec 2002, Marcel Stangenberger wrote:

  On Tue, 10 Dec 2002, Adrian Penisoara wrote:
 
 What is the proper solution ? I'd rather prefer to modify the termcaps
   than making adjustments in PuTTY, as some persons get cranky when it
   comes about changing PuTTY settings while Linux works well with the
   defaults.
  
 
  proper way is to alter the putty settings for your connection to freebsd
  machines. Another way is changing the default shell to bash.

   But I have Bash as the default shell. And yes, it works changing the
 Terminal / Keyboard / Backspace key from Contrl-? (127) to
 Control-H, but the users are pissed off by the fact that Linux doesn't
 need this -- does it mean FreeBSD has broken termcap entries or that
 Linux is just stepping on the traditional standards ?


Since solaris has the same problem i suspect that linux is stepping
on the standards.

Marcel
--
I have often regretted my speech, never my silence.
- Xenocrates (396-314 B.C.)



To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message



Re: Backspace and Delete keys under PuTTY

2002-12-10 Thread Roman Neuhauser
# [EMAIL PROTECTED] / 2002-12-10 11:59:53 +0200:
  I'm getting pissed (me and some other professors) by the Backspace and
 Delete keystrokes that are incorrectly handled by either PuTTY or
 FreeBSD when connecting to a FreeBSD system from a Windows workstation
 with PuTTY. No need to mention that when it comes to Linux everything
 looks fine.

different terminals use different values for backspace/delete. linux
console uses ^? for backspace, ^[[~3 for delete, while freebsd uses
^H for backspace, and ^? for delete. putty assumes linux, so it
defaults to the codes linux terminal expects.

if you check the xterm definition in /etc/termcap, you'll see
that it defines kb=^H and kD=^?. putty claims to be xterm
(Connection - Terminal type string), so it is the liar here.
 
   What is the proper solution?

IMO: fixing the terminal, in this case: putty.

   I'd rather prefer to modify the termcaps than making adjustments in
   PuTTY, as some persons get cranky when it comes about changing PuTTY
   settings while Linux works well with the defaults.

IIRC this setting is session-wide, so you can have
^? / ^[[~3 for linux, and ^H / ^? for freebsd.

-- 
If you cc me or remove the list(s) completely I'll most likely ignore
your message.see http://www.eyrie.org./~eagle/faqs/questions.html

To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message



Re: Backspace and Delete keys under PuTTY

2002-12-10 Thread Brian
putty on win to freebsd works ok for me, except for bitchx, so I just set
term=vt102 prior to firing up BitchX.  My shell is tcsh.

Brian

- Original Message -
From: Adrian Penisoara [EMAIL PROTECTED]
To: Marcel Stangenberger [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Tuesday, December 10, 2002 3:17 AM
Subject: Re: Backspace and Delete keys under PuTTY


 Hi,

 On Tue, 10 Dec 2002, Marcel Stangenberger wrote:

  On Tue, 10 Dec 2002, Adrian Penisoara wrote:
 
 What is the proper solution ? I'd rather prefer to modify the
termcaps
   than making adjustments in PuTTY, as some persons get cranky when it
   comes about changing PuTTY settings while Linux works well with the
   defaults.
  
 
  proper way is to alter the putty settings for your connection to freebsd
  machines. Another way is changing the default shell to bash.

   But I have Bash as the default shell. And yes, it works changing the
 Terminal / Keyboard / Backspace key from Contrl-? (127) to
 Control-H, but the users are pissed off by the fact that Linux doesn't
 need this -- does it mean FreeBSD has broken termcap entries or that
 Linux is just stepping on the traditional standards ?

  Ady (@freebsd.ady.ro)
 
 | An age is called Dark not because the light fails to shine, but  |
 | because people refuse to see it. |
 |   -- James Michener, Space |




 To Unsubscribe: send mail to [EMAIL PROTECTED]
 with unsubscribe freebsd-questions in the body of the message



To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message



Re: Backspace and Delete keys under PuTTY

2002-12-10 Thread Jonathan Chen
On Tue, Dec 10, 2002 at 01:17:17PM +0200, Adrian Penisoara wrote:

[...]
   But I have Bash as the default shell. And yes, it works changing the
 Terminal / Keyboard / Backspace key from Contrl-? (127) to
 Control-H, but the users are pissed off by the fact that Linux doesn't
 need this -- does it mean FreeBSD has broken termcap entries or that
 Linux is just stepping on the traditional standards ?

It's Linux that's stepping on standards. Their default config is to
have erase=DEL. All other UNIX boxen I've used have erase=BACKASPCE.
I suspect the PUTTY writers have been heavily influenced by Linux.

Cheers.
-- 
Jonathan Chen [EMAIL PROTECTED]
--
 A person should be able to do a small bit of everything,
specialisation is for insects

To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message



Re: Backspace and Delete keys under PuTTY

2002-12-10 Thread Marc Perisa

Am Dienstag den, 10. Dezember 2002, um 20:46, schrieb Jonathan Chen:


On Tue, Dec 10, 2002 at 01:17:17PM +0200, Adrian Penisoara wrote:

[...]

  But I have Bash as the default shell. And yes, it works changing the
Terminal / Keyboard / Backspace key from Contrl-? (127) to
Control-H, but the users are pissed off by the fact that Linux 
doesn't
need this -- does it mean FreeBSD has broken termcap entries or that
Linux is just stepping on the traditional standards ?

It's Linux that's stepping on standards. Their default config is to
have erase=DEL. All other UNIX boxen I've used have erase=BACKASPCE.
I suspect the PUTTY writers have been heavily influenced by Linux.


Hi Adrian,

it is not only for FreeBSD and Solaris but for Reliant Unix and HP-UX 
too.

As Jonathan said - Linux doesn't  behave like the others.

I hope that helps with your boss.

Marc



To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message


Re: Backspace and Delete keys under PuTTY

2002-12-10 Thread Peter
On Wed, 11 Dec 2002 10:52:40 +1100
JacobRhoden [EMAIL PROTECTED](by way of JacobRhoden [EMAIL PROTECTED]) wrote:

 On Wed, 11 Dec 2002 06:46, Jonathan Chen wrote:
  It's Linux that's stepping on standards. Their default config is to
  have erase=DEL. All other UNIX boxen I've used have erase=BACKASPCE.
  I suspect the PUTTY writers have been heavily influenced by Linux.
 
 I myself am going insane in an environment where every second box requires a
 different setting (rgh!! and stuff). Is there a way to override the local
 settings on the Linux/Solaris/etc... ?
 
 (Oh, and if you were writing an ssh client, would you default the settings to
 the standard, or to what works on all your machines *grin*)
 
 Jacob RhodenPhone: +61 3 8344 6102
 ITS DivisionEmail: [EMAIL PROTECTED]
 Melbourne University   Mobile: +61 403 788 386
 
 
 To Unsubscribe: send mail to [EMAIL PROTECTED]
 with unsubscribe freebsd-questions in the body of the message
 

This is the main reason I quit using PuttyI keep it around for 
emergencies, but I regularly I use the ssh client from ssh.com, a little bigger, but 
works much better.
---Peter---

To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message