blob: f9a5da06911a28bfc498b5da285be2a7aae17c2e [file] [log] [blame]
micky3879b9f5e72025-07-08 18:04:53 -04001##############################################################################
2# Copyright 2019-2022,2023 Thomas E. Dickey #
3# #
4# Permission is hereby granted, free of charge, to any person obtaining a #
5# copy of this software and associated documentation files (the "Software"), #
6# to deal in the Software without restriction, including without limitation #
7# the rights to use, copy, modify, merge, publish, distribute, distribute #
8# with modifications, sublicense, and/or sell copies of the Software, and to #
9# permit persons to whom the Software is furnished to do so, subject to the #
10# following conditions: #
11# #
12# The above copyright notice and this permission notice shall be included in #
13# all copies or substantial portions of the Software. #
14# #
15# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR #
16# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, #
17# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL #
18# THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER #
19# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING #
20# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER #
21# DEALINGS IN THE SOFTWARE. #
22# #
23# Except as contained in this notice, the name(s) of the above copyright #
24# holders shall not be used in advertising or otherwise to promote the sale, #
25# use or other dealings in this Software without prior written #
26# authorization. #
27##############################################################################
28#
29# Author: Thomas E. Dickey
30#
31# $Id: Caps-ncurses,v 1.15 2023/10/28 21:55:47 tom Exp $
32#
33#############################################################################
34#
35# TERMINFO EXTENSION CAPABILITIES
36#
37# This section is all comments (selected lines are copied/uncommented into
38# specific "Caps" files). The section describes what capabilities need to be
39# squeezed out to get down to the XSI Curses standard set. They are flagged
40# with K.
41#
42# HP extensions
43#
44# These extensions follow ptr_non (replacing everything after it) in HP
45# terminfo files. Except for memory_lock and memory_unlock, they are
46# functionally identical to SVr4 extensions, but they make the binary format
47# different. Grrr....
48#
49#memory_lock meml str ml - - ----K lock memory above cursor
50#memory_unlock memu str mu - - ----K unlock memory
51#plab_norm pln str pn - - ----- program label #1 to show string #2
52#label_on smln str LO - - ----- turn on soft labels
53#label_off rmln str LF - - ----- turn off soft labels
54#key_f11 kf11 str F1 - - ----- F11 function key
55#key_f12 kf12 str F2 - - ----- F12 function key
56#key_f13 kf13 str F3 - - ----- F13 function key
57#key_f14 kf14 str F4 - - ----- F14 function key
58#key_f15 kf15 str F5 - - ----- F15 function key
59#key_f16 kf16 str F6 - - ----- F16 function key
60#key_f17 kf17 str F7 - - ----- F17 function key
61#key_f18 kf18 str F8 - - ----- F18 function key
62#key_f19 kf19 str F9 - - ----- F19 function key
63#key_f20 kf20 str FA - - ----- F20 function key
64#key_f21 kf21 str FB - - ----- F21 function key
65#key_f22 kf22 str FC - - ----- F22 function key
66#key_f23 kf23 str FD - - ----- F23 function key
67#key_f24 kf24 str FE - - ----- F24 function key
68#key_f25 kf25 str FF - - ----- F25 function key
69#key_f26 kf26 str FG - - ----- F26 function key
70#key_f27 kf27 str FH - - ----- F27 function key
71#key_f28 kf28 str FI - - ----- F28 function key
72#key_f29 kf29 str FJ - - ----- F29 function key
73#key_f30 kf30 str FK - - ----- F30 function key
74#key_f31 kf31 str FL - - ----- F31 function key
75#key_f32 kf32 str FM - - ----- F32 function key
76#key_f33 kf33 str FN - - ----- F33 function key
77#key_f34 kf34 str FO - - ----- F34 function key
78#key_f35 kf35 str FP - - ----- F35 function key
79#key_f36 kf36 str FQ - - ----- F36 function key
80#key_f37 kf37 str FR - - ----- F37 function key
81#key_f38 kf38 str FS - - ----- F38 function key
82#key_f39 kf39 str FT - - ----- F39 function key
83#key_f40 kf40 str FU - - ----- F40 function key
84#key_f41 kf41 str FV - - ----- F41 function key
85#key_f42 kf42 str FW - - ----- F42 function key
86#key_f43 kf43 str FX - - ----- F43 function key
87#key_f44 kf44 str FY - - ----- F44 function key
88#key_f45 kf45 str FZ - - ----- F45 function key
89#key_f46 kf46 str Fa - - ----- F46 function key
90#key_f47 kf47 str Fb - - ----- F47 function key
91#key_f48 kf48 str Fc - - ----- F48 function key
92#key_f49 kf49 str Fd - - ----- F49 function key
93#key_f50 kf50 str Fe - - ----- F50 function key
94#key_f51 kf51 str Ff - - ----- F51 function key
95#key_f52 kf52 str Fg - - ----- F52 function key
96#key_f53 kf53 str Fh - - ----- F53 function key
97#key_f54 kf54 str Fi - - ----- F54 function key
98#key_f55 kf55 str Fj - - ----- F55 function key
99#key_f56 kf56 str Fk - - ----- F56 function key
100#key_f57 kf57 str Fl - - ----- F57 function key
101#key_f58 kf58 str Fm - - ----- F58 function key
102#key_f59 kf59 str Fn - - ----- F59 function key
103#key_f60 kf60 str Fo - - ----- F60 function key
104#key_f61 kf61 str Fp - - ----- F61 function key
105#key_f62 kf62 str Fq - - ----- F62 function key
106#key_f63 kf63 str Fr - - ----- F63 function key
107#
108# IBM extensions
109#
110# These extensions follow ptr_non (replacing everything after it) in IBM
111# terminfo files.
112#
113# The places in the box[12] capabilities correspond to acsc characters, here is
114# the mapping:
115#
116# box1[0] = ACS_ULCORNER
117# box1[1] = ACS_HLINE
118# box1[2] = ACS_URCORNER
119# box1[3] = ACS_VLINE
120# box1[4] = ACS_LRCORNER
121# box1[5] = ACS_LLCORNER
122# box1[6] = ACS_TTEE
123# box1[7] = ACS_RTEE
124# box1[8] = ACS_BTEE
125# box1[9] = ACS_LTEE
126# box1[10] = ACS_PLUS
127#
128# The box2 characters are the double-line versions of these forms graphics.
129#
130#box_chars_1 box1 str bx - - ----K box characters primary set
131#box_chars_2 box2 str by - - ----K box characters secondary set
132#box_attr_1 batt1 str Bx - - ----K attributes for box1
133#box_attr_2 batt2 str By - - ----K attributes for box2
134#color_bg_0 colb0 str d0 - - ----K background color 0
135#color_bg_1 colb1 str d1 - - ----K background color 1
136#color_bg_2 colb2 str d2 - - ----K background color 2
137#color_bg_3 colb3 str d3 - - ----K background color 3
138#color_bg_4 colb4 str d4 - - ----K background color 4
139#color_bg_5 colb5 str d5 - - ----K background color 5
140#color_bg_6 colb6 str d6 - - ----K background color 6
141#color_bg_7 colb7 str d7 - - ----K background color 7
142#color_fg_0 colf0 str c0 - - ----K foreground color 0
143#color_fg_1 colf1 str c1 - - ----K foreground color 1
144#color_fg_2 colf2 str c2 - - ----K foreground color 2
145#color_fg_3 colf3 str c3 - - ----K foreground color 3
146#color_fg_4 colf4 str c4 - - ----K foreground color 4
147#color_fg_5 colf5 str c5 - - ----K foreground color 5
148#color_fg_6 colf6 str c6 - - ----K foreground color 6
149#color_fg_7 colf7 str c7 - - ----K foreground color 7
150#font_0 font0 str f0 - - ----- select font 0
151#font_1 font1 str f1 - - ----- select font 1
152#font_2 font2 str f2 - - ----- select font 2
153#font_3 font3 str f3 - - ----- select font 3
154#font_4 font4 str f4 - - ----K select font 4
155#font_5 font5 str f5 - - ----K select font 5
156#font_6 font6 str f6 - - ----K select font 6
157#font_7 font7 str f7 - - ----K select font 7
158#key_back_tab kbtab str k0 - - ----- backtab key
159#key_do kdo str ki - - ----K do request key
160#key_command kcmd str kd - - ----K command-request key
161#key_command_pane kcpn str kW - - ----K command-pane key
162#key_end kend str kw - - ----- end key
163#key_help khlp str kq - - ----- help key
164#key_newline knl str nl - - ----K newline key
165#key_next_pane knpn str kv - - ----K next-pane key
166#key_prev_cmd kppn str kp - - ----K previous-command key
167#key_prev_pane kppn str kV - - ----K previous-pane key
168#key_quit kquit str kQ - - ----K quit key
169#key_select ksel str kU - - ----- select key
170#key_scroll_left kscl str kz - - ----K scroll left
171#key_scroll_right kscr str kZ - - ----K scroll right
172#key_tab ktab str ko - - ----K tab key
173#key_smap_in1 kmpf1 str Kv - - ----K special mapped key 1 input
174#key_smap_out1 kmpt1 str KV - - ----K special mapped key 1 output
175#key_smap_in2 kmpf2 str Kw - - ----K special mapped key 2 input
176#key_smap_out2 kmpt2 str KW - - ----K special mapped key 2 output
177#key_smap_in3 kmpf3 str Kx - - ----K special mapped key 3 input
178#key_smap_out3 kmpt3 str KX - - ----K special mapped key 3 output
179#key_smap_in4 kmpf4 str Ky - - ----K special mapped key 4 input
180#key_smap_out4 kmpt4 str KY - - ----K special mapped key 4 output
181#key_smap_in5 kmpf5 str Kz - - ----K special mapped key 5 input
182#key_smap_out5 kmpt5 str KZ - - ----K special mapped key 5 output
183#appl_defined_str apstr str za - - ----K application-defined string
184# The key_smap_in[6789] and key_smap_out[6789] capabilities aren't described in
185# the IBM manual pages, so the cap name strings are guesses. The terminfo
186# names are almost certainly right, the termcap ones almost certainly wrong.
187#key_smap_in6 kmpf6 str k! - - ----K special mapped key 6 input
188#key_smap_out6 kmpt6 str K@ - - ----K special mapped key 6 output
189#key_smap_in7 kmpf7 str k# - - ----K special mapped key 7 input
190#key_smap_out7 kmpt7 str K$ - - ----K special mapped key 7 output
191#key_smap_in8 kmpf8 str k% - - ----K special mapped key 8 input
192#key_smap_out8 kmpt8 str K^ - - ----K special mapped key 8 output
193#key_smap_in9 kmpf9 str k& - - ----K special mapped key 9 input
194#key_smap_out9 kmpt9 str K* - - ----K special mapped key 9 output
195# Undocumented capabilities end here
196#key_sf1 ksf1 str S1 - - ----K special function key 1
197#key_sf2 ksf2 str S2 - - ----K special function key 2
198#key_sf3 ksf3 str S3 - - ----K special function key 3
199#key_sf4 ksf4 str S4 - - ----K special function key 4
200#key_sf5 ksf5 str S5 - - ----K special function key 5
201#key_sf6 ksf6 str S6 - - ----K special function key 6
202#key_sf7 ksf7 str S7 - - ----K special function key 7
203#key_sf8 ksf8 str S8 - - ----K special function key 8
204#key_sf9 ksf9 str S9 - - ----K special function key 9
205#key_sf10 ksf10 str SA - - ----K special function key 10
206# AIX version 3 documents different codes for F11, F12 and does not mention
207# F13-F64. AIX version 4 uses the same naming for F0-F63 as above.
208#key_f11 kf11 str k< - - ----- function key 11
209#key_f12 kf12 str k> - - ----- function key 12
210# Undocumented capabilities end here.
211#key_action kact str kJ - - ----K sent by action key
212# The IBM docs say these capabilities are for table-drawing, and are
213# valid only for aixterm descriptions.
214#enter_topline_mode topl str tp - - ----K start top-line mode
215#enter_bottom_mode btml str bm - - ----K start bottom-line mode
216#enter_rvert_mode rvert str rv - - ----K start right-vertical mode
217#enter_lvert_mode lvert str lv - - ----K start left-vertical mode
218#
219#############################################################################
220#
221# ALIAS DECLARATIONS
222#
223# Here we set up aliases for translating extensions into standard terminfo.
224#
225#---------------------------------- Termcap aliases -------------------------
226#
227# BSD aliases:
228#
229# This is a common error in many termcap files. We'll get notified during
230# translation when this (or any other alias) fires.
231#
232capalias sb sr BSD scroll text down
233#
234# AT&T extensions:
235#
236# The old AT&T 5410, 5420, 5425, pc6300plus, 610, and s4 entries used a set of
237# nonstandard capabilities. Its signature is the KM capability, used to name
238# some sort of keymap file. EE, BO, CI, CV, XS, DS, FL and FE are in this
239# set. Comments in the original, and a little cross-checking with other AT&T
240# documentation, seem to establish the following mappings:
241#
242capalias BO mr AT&T enter_reverse_mode
243capalias CI vi AT&T cursor_invisible
244capalias CV ve AT&T cursor_normal
245capalias DS mh AT&T enter_dim_mode
246#capalias EE me AT&T exit_attribute_mode
247capalias FE LF AT&T label_on
248capalias FL LO AT&T label_off
249capalias XS mk AT&T enter_secure_mode
250#
251# We comment out EE because the conflicting XENIX EE is more common in
252# old entries.
253#
254# XENIX extensions:
255#
256# These are the ones we know how to translate directly:
257#
258capalias EE mh XENIX exit_attribute_mode
259capalias GE ae XENIX exit_alt_charset_mode
260capalias GS as XENIX enter_alt_charset_mode
261capalias CF vi XENIX cursor_invis
262capalias CO ve XENIX cursor_normal
263capalias EN @7 XENIX key_end
264capalias HM kh XENIX key_home
265capalias LD kL XENIX key_dl
266capalias PD kN XENIX key_npage
267capalias PN po XENIX prtr_off
268capalias PS pf XENIX prtr_on
269capalias PU kP XENIX key_ppage
270capalias RT @8 XENIX kent
271capalias UP ku XENIX kcuu1
272capalias G6 IGNORE XENIX double-ACS_ULCORNER
273capalias G7 IGNORE XENIX double-ACS_LLCORNER
274capalias G5 IGNORE XENIX double-ACS_URCORNER
275capalias G8 IGNORE XENIX double-ACS_LRCORNER
276capalias Gr IGNORE XENIX double-ACS_LTEE
277capalias Gr IGNORE XENIX double-ACS_RTEE
278capalias Gu IGNORE XENIX double-ACS_BTEE
279capalias Gd IGNORE XENIX double ACS_TTEE
280capalias Gh IGNORE XENIX double-ACS_HLINE
281capalias Gv IGNORE XENIX double-ACS_VLINE
282capalias Gc IGNORE XENIX double-ACS_PLUS
283capalias GG IGNORE XENIX acs-glitch
284#
285# IBM extensions:
286#
287capalias kq %1 IBM key_help
288#
289# Iris extensions:
290#
291capalias HS mh IRIS enter_dim_mode
292#
293# Tektronix extensions:
294#
295capalias KA k; Tek key_f10
296capalias KB F1 Tek key_f11
297capalias KC F2 Tek key_f12
298capalias KD F3 Tek key_f13
299capalias KE F4 Tek key_f14
300capalias KF F5 Tek key_f15
301capalias BC Sb Tek set_background
302capalias FC Sf Tek set_foreground
303#
304# There are also the following:
305#
306# XENIX XENIX variable name name clash with terminfo?
307# ----- ------------------- -------------------------
308# CL key_char_left
309# CR key_char_right
310# CW key_change_window
311# HP ??
312# LF key_linefeed label_off
313# NU key_next_unlocked_cell
314# PL ??
315# PR ??
316# RC key_recalc remove_clock
317# RF key_toggle_ref req_for_input
318# WL key_word_left
319# WR key_word_right
320#
321# If you know what any of the question-marked ones mean, please tell us.
322#
323#--------------------------------- Terminfo aliases ------------------------
324#
325# IBM extensions:
326#
327infoalias font0 s0ds IBM set0_des_seq
328infoalias font1 s1ds IBM set1_des_seq
329infoalias font2 s2ds IBM set2_des_seq
330infoalias font3 s3ds IBM set3_des_seq
331infoalias kbtab kcbt IBM key_backtab
332infoalias ksel kslt IBM key_select
333#
334# Some others are identical to SVr4/XPG4 capabilities, in particular:
335# kcmd, kend, khlp, and kf11...kf63.
336#
337#############################################################################
338# This is a table of ncurses user-definable capabilities which applications
339# developers may have used. ncurses may use the table to check consistency of
340# types/parameters. Applications may have defined others (such as screen's
341# LP and NF), but where a standard capability is available, those alternatives
342# are not listed here.
343#
344used_by ncurses
345userdef CO num n number of indexed colors overlaying RGB space
346userdef E3 str - clears the terminal's scrollback buffer.
347userdef NQ bool - terminal does not support query/response
348userdef RGB bool - use direct colors with 1/3 of color-pair bits per color.
349userdef RGB num n use direct colors with given number of bits per color.
350userdef RGB str - use direct colors with given bit-layout.
351userdef TS str - like "tsl", but uses no parameter.
352userdef U8 num n terminal does/does not support VT100 SI/SO when processing UTF-8 encoding.
353userdef XM str n initialize alternate xterm mouse mode
354userdef grbom str - disable real bold (not intensity bright) mode.
355userdef gsbom str - enable real bold (not intensity bright) mode.
356userdef xm str - mouse response, no parameters
357userdef xm str n mouse response, p1 = y-ordinate
358userdef xm str nn mouse response, p2 = x-ordinate
359userdef xm str nnn mouse response, p3 = button
360userdef xm str nnns mouse response, p4 = state, e.g., pressed or released
361userdef xm str nnnsn mouse response, p5 = y-ordinate starting region
362userdef xm str nnnsnn mouse response, p6 = x-ordinate starting region
363userdef xm str nnnsnnn mouse response, p7 = y-ordinate ending region
364userdef xm str nnnsnnnn mouse response, p8 = x-ordinate ending region
365#
366used_by mintty
367userdef Rmol str - remove overline-mode
368userdef Smol str - set overline-mode
369userdef blink2 str - turn on rapid blinking
370userdef norm str - turn off bold and half-bright mode
371userdef opaq str - turn off blank mode
372userdef setal str n set underline-color
373userdef smul2 str - begin double underline mode
374#
375used_by screen
376userdef AN bool - turn on autonuke.
377userdef AX bool - understands ANSI set default fg/bg color (\E[39m / \E[49m).
378userdef C0 str - use the string as a conversion table for font '0', like acsc.
379userdef C8 bool - terminal shows bold as high-intensity colors.
380userdef CE str - switch cursor-keys back to normal mode.
381userdef CS str - switch cursor-keys to application mode.
382userdef E0 str - switch charset 'G0' back to standard charset. Default is '\E(B'.
383userdef G0 bool - terminal can deal with ISO 2022 font selection sequences.
384userdef KJ str s set the encoding of the terminal.
385userdef OL num n set the screen program's output buffer limit.
386userdef S0 str s switch charset 'G0' to the specified charset. Default is '\E(%.'.
387userdef TF bool - add missing capabilities to screen's termcap/info entry. (Set by default).
388userdef WS str nn resize display. This capability has the desired width and height as arguments. SunView(tm) example: '\E[8;%d;%dt'.
389userdef XC str s describe a translation of characters to strings depending on the current font.
390userdef XT bool - terminal understands special xterm sequences (OSC, mouse tracking).
391userdef Z0 str - change width to 132 columns.
392userdef Z1 str - change width to 80 columns.
393#
394used_by tmux
395userdef Cr str - restore the default cursor color.
396userdef Cs str s set the cursor color.
397userdef Csr str n change the cursor style, overriding Ss.
398userdef Ms str ss store the current buffer in the host terminal's selection (clipboard).
399userdef Se str - reset the cursor style to the terminal initial state.
400userdef Smulx str n modify the appearance of underlines in VTE.
401userdef Ss str n change the cursor style.
402userdef rmxx str - reset ECMA-48 strikeout/crossed-out attributes.
403userdef smxx str - set ECMA-48 strikeout/crossed-out attributes.
404#
405used_by vim
406userdef BD str - disables bracketed paste
407userdef BE str - enables bracketed paste
408userdef PE str - is sent after pasted text
409userdef PS str - is sent before pasted text
410userdef RV str - report terminal secondary device attributes
411userdef XR str - report terminal version as a free-format string.
412userdef XF bool - terminal supports xterm focus in/out
413userdef fd str - disable xterm focus-events
414userdef fe str - enable xterm focus-events
415userdef rv str - response to RV, regular expression
416userdef xr str - response to XR, regular expression
417#
418used_by xterm
419userdef csl str - clear status line
420userdef kDC3 str - alt delete-character
421userdef kDC4 str - shift+alt delete-character
422userdef kDC5 str - control delete-character
423userdef kDC6 str - shift+control delete-character
424userdef kDC7 str - alt+control delete-character
425userdef kDN str - shift down-cursor
426userdef kDN3 str - alt down-cursor
427userdef kDN4 str - shift+alt down-cursor
428userdef kDN5 str - control down-cursor
429userdef kDN6 str - shift+control down-cursor
430userdef kDN7 str - alt+control down-cursor
431userdef kEND3 str - alt end
432userdef kEND4 str - shift+alt end
433userdef kEND5 str - control end
434userdef kEND6 str - shift+control end
435userdef kEND7 str - alt+control end
436userdef kHOM3 str - alt home
437userdef kHOM4 str - shift+alt home
438userdef kHOM5 str - control home
439userdef kHOM6 str - shift+control home
440userdef kHOM7 str - alt+control home
441userdef kIC3 str - alt insert-character
442userdef kIC4 str - shift+alt insert-character
443userdef kIC5 str - control insert-character
444userdef kIC6 str - shift+control insert-character
445userdef kIC7 str - alt+control insert-character
446userdef kLFT3 str - alt left-cursor
447userdef kLFT4 str - shift+alt left-cursor
448userdef kLFT5 str - control left-cursor
449userdef kLFT6 str - shift+control left-cursor
450userdef kLFT7 str - alt+control left-cursor
451userdef kNXT3 str - alt next
452userdef kNXT4 str - shift+alt next
453userdef kNXT5 str - control next
454userdef kNXT6 str - shift+control next
455userdef kNXT7 str - alt+control next
456userdef kPRV3 str - alt previous
457userdef kPRV4 str - shift+alt previous
458userdef kPRV5 str - control previous
459userdef kPRV6 str - shift+control previous
460userdef kPRV7 str - alt+control previous
461userdef kRIT3 str - alt right-cursor
462userdef kRIT4 str - shift+alt right-cursor
463userdef kRIT5 str - control right-cursor
464userdef kRIT6 str - shift+control right-cursor
465userdef kRIT7 str - alt+control right-cursor
466userdef kUP str - shift up-cursor
467userdef kUP3 str - alt up-cursor
468userdef kUP4 str - shift+alt up-cursor
469userdef kUP5 str - control up-cursor
470userdef kUP6 str - shift+control up-cursor
471userdef kUP7 str - alt+control up-cursor
472userdef ka2 str - vt220-keypad extensions
473userdef kb1 str - vt220-keypad extensions
474userdef kb3 str - vt220-keypad extensions
475userdef kc2 str - vt220-keypad extensions
476userdef kxIN str - mouse response on focus-in
477userdef kxOUT str - mouse response on focus-out
478#############################################################################