- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- stty delete ^? ?
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-17-2004 09:41 PM
тАО02-17-2004 09:41 PM
I know we can set the erase key to function like :
stty erase ^H
However, my collegues will have to start using Midnight Commander for Unix, but start having a problem with not being able to use the
Once pressing the
stty delete ^?
Any advise? The above doesn't work. Thanks a lot for your help.
Regs David
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-17-2004 09:49 PM
тАО02-17-2004 09:49 PM
Re: stty delete ^? ?
check your settings
#stty -a
If your erase it set to the "delete key" revert that to the backspace
#stty erase ^H
you can also move things to their defaults using
#stty sane
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-17-2004 10:03 PM
тАО02-17-2004 10:03 PM
Re: stty delete ^? ?
Regs David
the output of stty -a is :
# stty -a
speed 9600 baud; line = 0;
rows = 24; columns = 80
min = 1; time = 1;
intr = ^C; quit = ^\; erase = ^H; kill = ^U
eof = ^D; eol = ^@; eol2 = ^@; swtch = ^@
stop = ^S; start = ^Q; susp = ^Z; dsusp = ^@
werase = ^@; lnext = ^@
parenb -parodd cs8 -cstopb hupcl cread -clocal -loblk -crts
-ignbrk brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl -iuclc
ixon -ixany ixoff -imaxbel -rtsxoff -ctsxon -ienqak
isig icanon -iexten -xcase echo echoe echok -echonl -noflsh
echoctl -echoprt echoke -flusho -pendin
opost -olcuc onlcr -ocrnl -onocr -onlret -ofill -ofdel -tostop
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-17-2004 10:11 PM
тАО02-17-2004 10:11 PM
Re: stty delete ^? ?
Some terminal emulators such as "konsole" have a keyboard schema specifically for midnight commander. Others, like xterm adn I think hpterm also allow you to change what the "delete" key sends. If not, then you are going to have to look at xmodmap (man xmodmap) to program it to what you want. If you use dtterm then you need to look at Motif resource files which are extremely annoying.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-17-2004 10:14 PM
тАО02-17-2004 10:14 PM
Re: stty delete ^? ?
I would search for a keyboard definition.
You know, when using terminal emulation programs (like telnet clients, putty) you have to define the backspace key? Other programs ask you if pressing the backspace must send a ^H or ^?. So what terminal are you using? hpterm dtterm?
JP.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-17-2004 10:18 PM
тАО02-17-2004 10:18 PM
Re: stty delete ^? ?
maybe my previous reply was too fast...
I have to think it over...
JP.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-17-2004 11:04 PM
тАО02-17-2004 11:04 PM
Re: stty delete ^? ?
Maybe my question still is not clear.
I am looking for an ssty definable function that removes a character after the current cursor position.
Just as backspace does it in front of the current cursor position.
Is there?
Regs David
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-17-2004 11:29 PM
тАО02-17-2004 11:29 PM
Re: stty delete ^? ?
stty doesn't have one of those. I think you might be barking up the wrong tree as they say. If this is what midnight commander does when you hit the delete key, then it is midnight commander that is erasing the character, not the terminal subsystem of the OS. What I suspect your problem is is that Midnight Commander is expecting to receive a DEL (ascii 127) when you press the delete key.
So, to solve this problem, you need to program your delete key to send a ascii 127(octal 177, hex 7F). This you can do wiht xmodmap
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-17-2004 11:42 PM
тАО02-17-2004 11:42 PM
Re: stty delete ^? ?
Unfortunetly this is beyond my reach of knowledge. If I show you an example config file of a vt100 file, do you know the answer then?
If so --> you have another ten-pointer.
If not, there's is nothing else than to say a big :
Thank You !
Regs David
# more vt100.ti
vt100|vt100-am|dec vt100 (w/advanced video),
am, mir, msgr, xenl, xon,
cols#80, it#8, lines#24, vt#3,
acsc=``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
bel=^G, blink=\E[5m$<2>, bold=\E[1m$<2>,
clear=\E[H\E[J$<50>, cr=\r, csr=\E[%i%p1%d;%p2%dr,
cub=\E[%p1%dD, cub1=\b, cud=\E[%p1%dB, cud1=\n,
cuf=\E[%p1%dC, cuf1=\E[C$<2>,
cup=\E[%i%p1%d;%p2%dH$<5>, cuu=\E[%p1%dA,
cuu1=\E[A$<2>, ed=\E[J$<50>, el=\E[K$<3>,
el1=\E[1K$<3>, enacs=\E(B\E)0, home=\E[H, ht=\t,
hts=\EH, ind=\n, ka1=\EOq, ka3=\EOs, kb2=\EOr, kbs=\b,
kc1=\EOp, kc3=\EOn, kcub1=\EOD, kcud1=\EOB,
kcuf1=\EOC, kcuu1=\EOA, kent=\EOM, kf0=\EOy, kf1=\EOP,
kf10=\EOx, kf2=\EOQ, kf3=\EOR, kf4=\EOS, kf5=\EOt,
kf6=\EOu, kf7=\EOv, kf8=\EOl, kf9=\EOw, rc=\E8,
rev=\E[7m$<2>, ri=\EM$<5>, rmacs=^O, rmkx=\E[?1l\E>,
rmso=\E[m$<2>, rmul=\E[m$<2>,
rs2=\E>\E[?3l\E[?4l\E[?5l\E[?7h\E[?8h, sc=\E7,
sgr=\E[0%?%p1%p6%|%t;1%;%?%p2%t;4%;%?%p1%p3%|%t;7%;%?%p4%t;5%;m%?%p9%t^N%e^O%;,
sgr0=\E[m^O$<2>, smacs=^N, smkx=\E[?1h\E=,
smso=\E[1;7m$<2>, smul=\E[4m$<2>, tbc=\E[3g,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-17-2004 11:56 PM
тАО02-17-2004 11:56 PM
Re: stty delete ^? ?
Try doing something like this with "xmodmap". First make sure your DISPLAY variable is set correctly and the try
xmodmap -e "keysym Delete = Delete"
This should make the Delete key send a real Delete. If I'm right Midnight Commander should be happy. You can check what your current keyboard config is with "xmodmap -pk | more" this might be useful too.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-17-2004 11:58 PM
тАО02-17-2004 11:58 PM
Re: stty delete ^? ?
xmodmap -e "keysym BackSpace = Delete"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-18-2004 12:19 AM
тАО02-18-2004 12:19 AM
Re: stty delete ^? ?
set -o vi
-denver
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-18-2004 01:58 AM
тАО02-18-2004 01:58 AM
Re: stty delete ^? ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-18-2004 05:24 AM
тАО02-18-2004 05:24 AM
SolutionAfter having a stroll, I figured out it probably had nothing to do with stty. But other people already said that.
(I think stty goes back to the real teletypes. Some keypresses don't make it to the program at all, but are captured by stty, termio or whatever. But that's only the way I look at it and how I understand it.)
I just had a look at Midnight Commander on Linux (I currently have no access to HP-UX).
Under the pull-down menu 'Options' you can learn the keys. You have to press all keys Midnight Commander uses and each key press marks a key as OK. Then you are probably left with the [Delete key} unmarked. Move the cursor to it and press the
Hope this works on HP-UX too.
JP.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-19-2004 04:25 AM
тАО02-19-2004 04:25 AM
Re: stty delete ^? ?
By reading the thread I am a little un clear as what the problem is but this is my take
the DELETE key returns ^?. Instead of deleting a the a character.
You can set the delete key to work for the ^? by editing the users .profile
you have to use a special key enter to enter ^? into the profile
Control V and then Control? will create the line.
stty erase ^V^?
Rory
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-19-2004 04:29 AM
тАО02-19-2004 04:29 AM
Re: stty delete ^? ?
The initial question is totaly different; read my quote :
# ------------------------------------------
I am looking for an ssty definable function that removes a character after the current cursor position.
Just as backspace does it in front of the current cursor position.
# ------------------------------------------
I already found out on unix.com that this is not possible. Don't know what Mark did, I do know he has a problem :)
Regs David
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-19-2004 04:36 AM
тАО02-19-2004 04:36 AM
Re: stty delete ^? ?
I thought,"which will be quicker, finding the correct xmodmap key symbols or logging out of X and then loggin in again".
Guess which one I chose.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-19-2004 05:29 AM
тАО02-19-2004 05:29 AM
Re: stty delete ^? ?
stty as mentioned, is a driver interface and can take a specific command string action based on certain characters. But erasing characters to the right on a command line is meaningless, thus the lack of information on how to do this.
Now menu programs are not command lines. They bounce all over the screen, just like vi. And the programmer has the choice to create the behavior you described. The characters are read one at a time, decoded and then the appropriate terminal-specific action taken. For instance, you can clear characters to the right by using the capname associated with clr_eol (see man terminfo) and typing the tput command:
tput el
What this command does is to use the Curses library to look in the terminfo database, and using the $TERM value, request the code for clear-to-EOL. Notre that the codes will be very different for different terminals. Try this:
$ TERM=hp tput el | xd -xc
0000000 1b4b
1b K
$ TERM=wy50 tput el | xd -xc
0000000 1b74
1b t
$ TERM=vt100 tput el | xd -xc
0000000 1b5b 304b
1b [ 0 K
So depending on the type of terminal you have, the codes will be different. But none of this applies if you are running a special program such as an Xwindow editor. These programs define everything and usually ignore anything in stty (they read characters in raw mode).
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-19-2004 07:07 AM
тАО02-19-2004 07:07 AM
Re: stty delete ^? ?
a correction on my last reply.
To define a key in MC, move to the corresponding menu-item, press
Are you still searching for a generic solution, or is it just Midnight Commander?
JP.