home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / sys / hp / 12861 < prev    next >
Encoding:
Internet Message Format  |  1992-11-13  |  5.8 KB

  1. Path: sparky!uunet!know!mips2!news.bbn.com!usc!zaphod.mps.ohio-state.edu!darwin.sura.net!uvaarpa!concert!sas!mozart.unx.sas.com!kent
  2. From: kent@manzi.unx.sas.com (Paul Kent)
  3. Newsgroups: comp.sys.hp
  4. Subject: Re: Need hpterm or xterm keys to emulate VT100/VT200 keys on VMS
  5. Message-ID: <BxMM55.2y9@unx.sas.com>
  6. Date: 12 Nov 92 23:19:52 GMT
  7. References: <BxMFr5.4CF@world.std.com>
  8. Sender: news@unx.sas.com (Noter of Newsworthy Events)
  9. Organization: SAS Institute Inc.
  10. Lines: 151
  11. Originator: kent@manzi.unx.sas.com
  12. Nntp-Posting-Host: manzi.unx.sas.com
  13.  
  14.  
  15. In article <BxMFr5.4CF@world.std.com>, kovar@world.std.com (David C Kovar) writes:
  16. >  Some of the people in my office are trying to use their HP 700 XTerminals
  17. >on VMS for development work. Their primary complaint is that they cannot
  18. >get the application keypad to generate VT100 key sequences. This means
  19. >that they can not really use the VMS debugger. So we have a lot of
  20. >engineers with HPs and VT100s on their desks. They've apparently
  21. >tried modmap, no no avail. But we're new to this game so we could
  22. >have done something wrong.
  23. >
  24. >  Does anyone have a xmodmap, or some other tool, that will map
  25. >the HP keyboard to a VT100 keyboard when using an xterminal window?
  26. >
  27. >  Any leads would be most appreciated.
  28. >
  29.  
  30.  
  31.  
  32. this really should be in the FAQ (and it may even be, i don't have one handy).
  33. does the FAQ maintainer read this list??
  34.  
  35.  
  36.  
  37. folks here at SAS do this by:
  38.  
  39. establishing an alternate name for xterm and defining xterm key translation resources
  40. for that alternately named xterm... (we use "vaxterm") 
  41.  
  42. VUE complicates how this file is loaded, but one sure way is to clip the
  43. attachment below into $HOME/vax.Xdef and do 
  44.  
  45. prompt> xrdb -m $HOME/vax.Xdef
  46. prompt> xterm -name vaxterm &
  47.  
  48.  
  49. voila, you have an xterm that
  50.  
  51.  
  52. a) uses 8x13 fonts
  53.  
  54. b) has different colors, so you remember itsa a VAX (as if you needed that :-)
  55.  
  56. c) uses 80x60 rows... i find a "set term/dec_crt/tab/adv/page=60/width=80"
  57.    in my vax LOGIN.COM helps a lot.
  58.  
  59. d) has 2048 lines of scroll back (which is not enough if you have been spoiled
  60.    by the excellent apollo DM pads)
  61.  
  62. e) a charclass definition such that a double-click fishes out a VAX style path
  63.    name (or at least enough to fool me)
  64.  
  65. f) a short cut key for logging on if your username is KENT and your password 
  66.    is SILLY -- just press extend-1 at the USERNAME: prompt.
  67.  
  68. g) translations for the vax-style keypad. these may not be a complete set. i was
  69.    never more than a two finger typer on a vax.
  70.  
  71.  
  72.  
  73.  
  74. the cool thing about this approach over xmodmap is that you dont have to butcher the
  75. keys in your honest-to-goodness xterms.
  76.  
  77.  
  78. if you wanted to get even fancier, xterm has a function :
  79.  
  80.     keymap(name)
  81.               This action dynamically defines a new translation table whose
  82.               resource name is name with the suffix Keymap (case is
  83.               significant).  The name None restores the original translation
  84.               table.
  85.  
  86. you could define a number of keymaps and the keys to rotate around them
  87. but i have not ventured down that path.
  88.  
  89.  
  90.  
  91.  
  92. hope this helps you.
  93. paul.
  94.  
  95.  
  96.  
  97. this be the file you wanna merge with xrdb (or make available as xterm resources in
  98. one of the many ways (i use the XAPPLRESDIR scheme myself)
  99. ------------------------------------------------------------------------------------
  100.  
  101. !
  102. ! vaxterm is for DEC terminals.
  103. !
  104. ! fonts
  105. vaxterm*font:            8x13
  106. vaxterm*boldFont:        8x13bold
  107. ! colors
  108. vaxterm*background:        #029
  109. vaxterm*foreground:        white
  110. vaxterm*cursorColor:        red
  111. vaxterm*pointerColor:        red
  112. vaxterm*pointerColorBackground:    red
  113. ! other
  114. vaxterm*curses:            on
  115. vaxterm*VT100.geometry:        =80x60
  116. vaxterm*logging:        off
  117. vaxterm*saveLines:        2048
  118. vaxterm*scrollBar:        on
  119. vaxterm*ttyModes:        erase ^h intr ^c kill ^u eof ^d
  120. vaxterm*visualBell:        off
  121. vaxterm*utmpInhibit:        true
  122. ! cut behaviour
  123. vaxterm*cutToBeginningOfLine:   false
  124. vaxterm*charClass:              33:48,45-47:48,58-59:48,64:48,91:48,93:48
  125. !
  126. ! BackSpace is mapped to DEL which is more natural for DEC boxen
  127. !
  128. ! I think the rest map the keypad to a VAXlike keypad
  129. !
  130. vaxterm*VT100.Translations:    #override \
  131.         Meta<Key>1:             string(KENT) string(0x0d) string(SILLY) string(0x0d) \n\
  132.         Shift<Key>Next:         scroll-forw(1,page) \n\
  133.         Shift<Key>Prior:        scroll-back(1,page) \n\
  134.         <Key>DeleteLine:        string(0x1b) string([3~)   \n\
  135.         <Key>InsertLine:        string(0x1b) string([2~)   \n\
  136.         <Key>BackSpace:         string(0x7f)               \n\
  137.         <Key>Next:              string(0x1b) string([6~)   \n\
  138.         <Key>Prior:             string(0x1b) string([5~)   \n\
  139.         <Key>DeleteChar:        string(0x1b) string([1~)   \n\
  140.         <Key>F1:                string(0x1b) string([31~)  \n\
  141.         <Key>F2:                string(0x1b) string([32~)  \n\
  142.         <Key>F3:                string(0x1b) string([33~)  \n\
  143.         <Key>F4:                string(0x1b) string([34~)  \n\
  144.         <Key>KP_Multiply:    string(0x1b) string(OP)    \n\
  145.         <Key>KP_Divide:        string(0x1b) string(OQ)    \n\
  146.         <Key>KP_Add:        string(0x1b) string(OR)    \n\
  147.         <Key>KP_Subtract:    string(0x1b) string(OS)    \n\
  148.         <Key>KP_0:        string(0x1b) string(Op)    \n\
  149.         <Key>KP_1:        string(0x1b) string(Oq)    \n\
  150.         <Key>KP_2:        string(0x1b) string(Or)    \n\
  151.         <Key>KP_3:        string(0x1b) string(Os)    \n\
  152.         <Key>KP_4:        string(0x1b) string(Ot)    \n\
  153.         <Key>KP_5:        string(0x1b) string(Ou)    \n\
  154.         <Key>KP_6:        string(0x1b) string(Ov)    \n\
  155.         <Key>KP_7:        string(0x1b) string(Ow)    \n\
  156.         <Key>KP_8:        string(0x1b) string(Ox)    \n\
  157.         <Key>KP_9:        string(0x1b) string(Oy)    \n\
  158.  
  159. -------------------------------------------------------------------------------------------
  160.  
  161. -- 
  162.  
  163. Paul Kent (SQL r&d)                   " nothing ventured, nothing disclaimed "
  164. kent@unx.sas.com         SAS Institute Inc, SAS Campus Dr, Cary NC 27513-2414.
  165.