xterm.termcap 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243
  1. # $XTermId: termcap,v 1.80 2012/06/10 14:30:37 tom Exp $
  2. #
  3. # These are termcap entries that correspond to xterm's terminfo file.
  4. # The file is formatted using ncurses' "tic -CNx", but is not mechanically
  5. # derived from the terminfo.
  6. #
  7. #------------------------------------------------------------------------------
  8. # Copyright 1996-2011,2012 by Thomas E. Dickey
  9. #
  10. # All Rights Reserved
  11. #
  12. # Permission is hereby granted, free of charge, to any person obtaining a
  13. # copy of this software and associated documentation files (the
  14. # "Software"), to deal in the Software without restriction, including
  15. # without limitation the rights to use, copy, modify, merge, publish,
  16. # distribute, sublicense, and/or sell copies of the Software, and to
  17. # permit persons to whom the Software is furnished to do so, subject to
  18. # the following conditions:
  19. #
  20. # The above copyright notice and this permission notice shall be included
  21. # in all copies or substantial portions of the Software.
  22. #
  23. # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
  24. # OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  25. # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
  26. # IN NO EVENT SHALL THE ABOVE LISTED COPYRIGHT HOLDER(S) BE LIABLE FOR ANY
  27. # CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
  28. # TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
  29. # SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  30. #
  31. # Except as contained in this notice, the name(s) of the above copyright
  32. # holders shall not be used in advertising or otherwise to promote the
  33. # sale, use or other dealings in this Software without prior written
  34. # authorization.
  35. #------------------------------------------------------------------------------
  36. #
  37. # Note:
  38. # termcap format is limited to 1023 characters. This set of descriptions
  39. # is a subset of the terminfo, since not all features can be fit into
  40. # that limit. The 'xterm' description supports color. The monochrome
  41. # 'xterm-mono' drops color in favor of additional function keys. If you
  42. # need both, use terminfo.
  43. #
  44. # The 1023-character limit applies to each entry after resolving the
  45. # "tc=" strings. Some implementations may discount all or part of the
  46. # formatting characters in the entry (i.e., the backslash newline tab
  47. # colon). GNU termcap does not have this limit.
  48. #
  49. # I checked the limits using ncurses "captoinfo -CrTUvx", which prints
  50. # the resolved length of each entry in a comment at the end - T.Dickey
  51. #
  52. xf|xterm-new|modern xterm:\
  53. :*6=\EOF:@7=\EOF:F1=\E[23~:F2=\E[24~:K2=\EOE:Km=\E[M:\
  54. :k1=\EOP:k2=\EOQ:k3=\EOR:k4=\EOS:k5=\E[15~:k6=\E[17~:\
  55. :k7=\E[18~:k8=\E[19~:k9=\E[20~:k;=\E[21~:kB=\E[Z:kH=\EOF:\
  56. :kI=\E[2~:kN=\E[6~:kP=\E[5~:kd=\EOB:kh=\EOH:kl=\EOD:\
  57. :kr=\EOC:ku=\EOA:tc=xterm-basic:
  58. #
  59. # This chunk is used for building the VT220/Sun/PC keyboard variants.
  60. xb|xterm-basic|modern xterm common:\
  61. :am:bs:km:mi:ms:ut:xn:AX:\
  62. :Co#8:co#80:kn#12:li#24:pa#64:\
  63. :AB=\E[4%dm:AF=\E[3%dm:AL=\E[%dL:DC=\E[%dP:DL=\E[%dM:\
  64. :DO=\E[%dB:LE=\E[%dD:RI=\E[%dC:UP=\E[%dA:ae=\E(B:al=\E[L:\
  65. :as=\E(0:bl=^G:cd=\E[J:ce=\E[K:cl=\E[H\E[2J:\
  66. :cm=\E[%i%d;%dH:cs=\E[%i%d;%dr:ct=\E[3g:dc=\E[P:dl=\E[M:\
  67. :ei=\E[4l:ho=\E[H:im=\E[4h:is=\E[!p\E[?3;4l\E[4l\E>:\
  68. :kD=\E[3~:ke=\E[?1l\E>:ks=\E[?1h\E=:le=^H:md=\E[1m:\
  69. :me=\E[m:ml=\El:mr=\E[7m:mu=\Em:nd=\E[C:op=\E[39;49m:\
  70. :rc=\E8:rs=\E[!p\E[?3;4l\E[4l\E>:sc=\E7:se=\E[27m:sf=^J:\
  71. :so=\E[7m:sr=\EM:st=\EH:te=\E[?1049l:ti=\E[?1049h:\
  72. :ue=\E[24m:up=\E[A:us=\E[4m:ve=\E[?12l\E[?25h:vi=\E[?25l:\
  73. :vs=\E[?12;25h:tc=xterm+kbs:
  74. # The xterm-new description has all of the features, but is not completely
  75. # compatible with vt220. If you are using a Sun or PC keyboard, set the
  76. # sunKeyboard resource to true:
  77. # + maps the editing keypad
  78. # + interprets control-function-key as a second array of keys, so a
  79. # 12-fkey keyboard can support vt220's 20-fkeys.
  80. # + maps numeric keypad "+" to ",".
  81. # + uses DEC-style control sequences for the application keypad.
  82. #
  83. vt|xterm-vt220|xterm emulating vt220:\
  84. :*6=\E[4~:@7=\E[4~:K2=\EOu:Km=\E[M:kB=\E[Z:kH=\E[4~:\
  85. :kh=\E[1~:tc=xterm-basic:
  86. v1|xterm-24|xterms|vs100|24x80 xterm:\
  87. :li#24:tc=xterm-old:
  88. v2|xterm-65|65x80 xterm:\
  89. :li#65:tc=xterm-old:
  90. vb|xterm-bold|xterm with bold for underline:\
  91. :so=\E[7m:us=\E[1m:tc=xterm-old:
  92. vB|xterm-boldso|xterm with bold for standout:\
  93. :se=\E[m:so=\E[1m:tc=xterm-old:
  94. vm|xterm-mono|monochrome xterm:\
  95. :ut@:\
  96. :Co@:NC@:kn#20:pa@:\
  97. :AB@:AF@:Sb@:Sf@:op@:st@:tc=xterm-old:
  98. #
  99. # Alternate terminal description that "works" for interactive shells such as
  100. # tcsh and bash.
  101. xn|xterm-noapp|xterm with cursor keys in normal mode:\
  102. :kd=\E[B:ke=\E>:kl=\E[D:kr=\E[C:ks=\E=:ku=\E[A:te@:ti@:\
  103. :tc=xterm:
  104. #
  105. # This should work for the commonly used "color xterm" variations (XFree86
  106. # xterm, color_xterm, nxterm, rxvt). Note that it does not set 'bce', so for
  107. # XFree86 and rxvt, some applications that use colors will be less efficient,
  108. # and in a few special cases (with "smart" optimization) the wrong color will
  109. # be painted in spots.
  110. vc|xterm-color|generic "ANSI" color xterm:\
  111. :Co#8:NC@:pa#64:\
  112. :AB=\E[4%dm:AF=\E[3%dm:ac=:op=\E[m:tc=xterm-r6:
  113. #
  114. # These aliases are for compatibility with the terminfo; termcap cannot provide
  115. # the extra features such as color initialization, but termcap applications
  116. # still want the names.
  117. x1|xterm-16color|xterm alias:\
  118. :tc=xterm-new:
  119. x2|xterm-88color|xterm alias:\
  120. :Co#88:pa#7744:tc=xterm-256color:
  121. x3|xterm-256color|xterm alias:\
  122. :Co#256:pa#32767:\
  123. :AB=\E[48;5;%dm:AF=\E[38;5;%dm:tc=xterm-new:
  124. xi|xterm-nrc|xterm alias:\
  125. :tc=xterm:
  126. xr|xterm-rep|xterm alias:\
  127. :tc=xterm:
  128. xx|xterm-xmc|xterm alias:\
  129. :sg#1:tc=xterm:
  130. #
  131. # An 8-bit description is doable with termcap, but there are probably no
  132. # termcap (or BSD curses) applications that are able to use it.
  133. x8|xterm-8bit|xterm terminal emulator 8-bit controls (X Window System):\
  134. :am:km:mi:ms:xn:\
  135. :co#80:it#8:li#24:\
  136. :AL=\233%dL:DC=\233%dP:DL=\233%dM:DO=\233%dB:IC=\233%d@:\
  137. :K2=\217y:Km=\233M:LE=\233%dD:RI=\233%dC:UP=\233%dA:\
  138. :ae=\E(B:al=\233L:as=\E(0:bl=^G:bt=\233Z:cd=\233J:ce=\233K:\
  139. :cl=\233H\2332J:cm=\233%i%d;%dH:cr=^M:cs=\233%i%d;%dr:\
  140. :ct=\2333g:dc=\233P:dl=\233M:do=^J:ei=\2334l:ho=\233H:\
  141. :im=\2334h:\
  142. :is=\E[62"p\E G\233m\233?7h\E>\E7\233?1;3;4;6l\2334l\233r\E8:\
  143. :k1=\23311~:k2=\23312~:k3=\23313~:k4=\23314~:k5=\23315~:\
  144. :k6=\23317~:k7=\23318~:k8=\23319~:k9=\23320~:kD=\2333~:\
  145. :kI=\2332~:kN=\2336~:kP=\2335~:kd=\217B:ke=\233?1l\E>:\
  146. :kh=\2331~:kl=\217D:kr=\217C:ks=\233?1h\E=:ku=\217A:le=^H:\
  147. :mb=\2335m:md=\2331m:me=\233m:mr=\2337m:nd=\233C:rc=\E8:\
  148. :sc=\E7:se=\23327m:sf=^J:so=\2337m:sr=\215:st=\210:ta=^I:\
  149. :te=\233?1049l:ti=\233?1049h:ue=\23324m:up=\233A:\
  150. :us=\2334m:vb=\233?5h\233?5l:ve=\233?25l\233?25h:\
  151. :vi=\233?25l:vs=\233?12;25h:tc=xterm+kbs:
  152. #
  153. hp|xterm-hp|xterm with hpterm function keys:\
  154. :@7=\EF:k1=\Ep:k2=\Eq:k3=\Er:k4=\Es:k5=\Et:k6=\Eu:k7=\Ev:\
  155. :k8=\Ew:kC=\EJ:kD=\EP:kI=\EQ:kN=\ES:kP=\ET:kd=\EB:kh=\Eh:\
  156. :kl=\ED:kr=\EC:ku=\EA:tc=xterm-basic:
  157. #
  158. xS|xterm-sco|xterm with SCO function keys:\
  159. :@7=\E[F:F1=\E[W:F2=\E[X:F3=\E[Y:F5=\E[a:F6=\E[b:F7=\E[c:\
  160. :F8=\E[d:F9=\E[e:FA=\E[f:FB=\E[g:FC=\E[h:FD=\E[i:FE=\E[j:\
  161. :FF=\E[k:ac=:k1=\E[M:k2=\E[N:k3=\E[O:k4=\E[P:k5=\E[Q:\
  162. :k6=\E[R:k7=\E[S:k8=\E[T:k9=\E[U:k;=\E[V:kD=\177:kI=\E[L:\
  163. :kN=\E[G:kP=\E[I:kd=\E[B:kh=\E[H:kl=\E[D:kr=\E[C:ku=\E[A:\
  164. :tc=xterm-basic:
  165. #
  166. v5|xterm-vt52|xterm emulating vt52:\
  167. :bs:\
  168. :co#80:it#8:li#24:\
  169. :ae=\EG:as=\EF:bl=^G:cd=\EJ:ce=\EK:cl=\EH\EJ:cm=\EY%+ %+ :\
  170. :cr=^M:do=\EB:ho=\EH:kd=\EB:kl=\ED:kr=\EC:ku=\EA:le=\ED:\
  171. :nd=\EC:nw=^M^J:sf=^J:sr=\EI:ta=^I:up=\EA:tc=xterm+kbs:
  172. #
  173. xs|xterm-sun|xterm with Sun functionkeys:\
  174. :%1=\E[196z:&8=\E[195z:@0=\E[200z:@5=\E[197z:@7=\E[220z:\
  175. :F1=\E[192z:F2=\E[193z:K2=\E[218z:Km=\E[M:k1=\E[224z:\
  176. :k2=\E[225z:k3=\E[226z:k4=\E[227z:k5=\E[228z:k6=\E[229z:\
  177. :k7=\E[230z:k8=\E[231z:k9=\E[232z:k;=\E[233z:kD=\E[3z:\
  178. :kI=\E[2z:kN=\E[222z:kP=\E[216z:kh=\E[214z:\
  179. :tc=xterm-basic:
  180. #
  181. # vi may work better with this entry, because vi doesn't use insert mode much.
  182. # |xterm-ic|xterm-vi|xterm with insert character instead of insert mode:\
  183. vi|xterm-ic|xterm-vi|xterm with insert char:\
  184. :mi@:\
  185. :IC=\E[%d@:ei@:ic=\E[@:im@:tc=xterm:
  186. #
  187. # Compatible with the X11R6.3 xterm
  188. r6|xterm-r6|xterm-old|X11R6 xterm:\
  189. :am:bs:km:mi:ms:pt:xn:\
  190. :co#80:kn#20:li#24:\
  191. :*6=\E[4~:@0=\E[1~:@7=\E[4~:AL=\E[%dL:DC=\E[%dP:DL=\E[%dM:\
  192. :DO=\E[%dB:F1=\E[23~:F2=\E[24~:F3=\E[25~:F4=\E[26~:\
  193. :F5=\E[28~:F6=\E[29~:F7=\E[31~:F8=\E[32~:F9=\E[33~:\
  194. :FA=\E[34~:LE=\E[%dD:RI=\E[%dC:UP=\E[%dA:ae=^O:al=\E[L:\
  195. :as=^N:bl=^G:cd=\E[J:ce=\E[K:cl=\E[H\E[2J:cm=\E[%i%d;%dH:\
  196. :cs=\E[%i%d;%dr:ct=\E[3g:dc=\E[P:dl=\E[M:eA=\E)0:ei=\E[4l:\
  197. :ho=\E[H:im=\E[4h:\
  198. :is=\E[m\E[?7h\E[4l\E>\E7\E[r\E[?1;3;4;6l\E8:\
  199. :k1=\E[11~:k2=\E[12~:k3=\E[13~:k4=\E[14~:k5=\E[15~:\
  200. :k6=\E[17~:k7=\E[18~:k8=\E[19~:k9=\E[20~:k;=\E[21~:\
  201. :kD=\E[3~:kI=\E[2~:kN=\E[6~:kP=\E[5~:kd=\EOB:ke=\E[?1l\E>:\
  202. :kh=\E[1~:kl=\EOD:kr=\EOC:ks=\E[?1h\E=:ku=\EOA:md=\E[1m:\
  203. :me=\E[m:ml=\El:mr=\E[7m:mu=\Em:nd=\E[C:rc=\E8:\
  204. :rs=\E[m\E[?7h\E[4l\E>\E7\E[r\E[?1;3;4;6l\E8:sc=\E7:\
  205. :se=\E[m:sf=^J:so=\E[7m:sr=\EM:te=\E[2J\E[?47l\E8:\
  206. :ti=\E7\E[?47h:ue=\E[m:up=\E[A:us=\E[4m:tc=xterm+kbs:
  207. #
  208. # Compatible with the R5 xterm
  209. r5|xterm-r5|X11R5 xterm X11R5:\
  210. :am:bs:km:mi:ms:pt:xn:\
  211. :co#80:kn#4:li#24:\
  212. :@7=\E[4~:AL=\E[%dL:DC=\E[%dP:DL=\E[%dM:DO=\E[%dB:\
  213. :IC=\E[%d@:UP=\E[%dA:al=\E[L:cd=\E[J:ce=\E[K:cl=\E[H\E[2J:\
  214. :cm=\E[%i%d;%dH:cs=\E[%i%d;%dr:ct=\E[3g:dc=\E[P:dl=\E[M:\
  215. :ei=\E[4l:ho=\E[H:im=\E[4h:\
  216. :is=\E[r\E[m\E[2J\E[H\E[?7h\E[?1;3;4;6l\E[4l:\
  217. :k1=\E[11~:k2=\E[12~:k3=\E[13~:k4=\E[14~:kd=\EOB:\
  218. :ke=\E[?1l\E>:kh=\E[1~:kl=\EOD:kr=\EOC:ks=\E[?1h\E=:\
  219. :ku=\EOA:md=\E[1m:me=\E[m:mr=\E[7m:nd=\E[C:rc=\E8:\
  220. :rs=\E>\E[?1;3;4;5;6l\E[4l\E[?7h\E[m\E[r\E[2J\E[H:\
  221. :sc=\E7:se=\E[m:sf=^J:so=\E[7m:sr=\EM:te=\E[2J\E[?47l\E8:\
  222. :ti=\E7\E[?47h:ue=\E[m:up=\E[A:us=\E[4m:tc=xterm+kbs:
  223. #
  224. # Customization begins here.
  225. x0|xterm-xfree86|xterm terminal emulator (XFree86):\
  226. :tc=xterm-new:
  227. #
  228. # This is the only entry which you should have to customize, since "xterm"
  229. # is widely used for a variety of incompatible terminal emulations including
  230. # color_xterm and rxvt.
  231. v0|xterm|X11 terminal emulator:\
  232. :tc=xterm-new:
  233. # :tc=xterm-r6:
  234. # This fragment is for people who cannot agree on what the backspace key
  235. # should send.
  236. xterm+kbs|fragment for backspace key:\
  237. :kb=^H: