]> ncurses.scripts.mit.edu Git - ncurses.git/blob - man/captoinfo.1m
ncurses 6.4 - patch 20231001
[ncurses.git] / man / captoinfo.1m
1 '\" t
2 .\"***************************************************************************
3 .\" Copyright 2018-2022,2023 Thomas E. Dickey                                *
4 .\" Copyright 1998-2010,2016 Free Software Foundation, Inc.                  *
5 .\"                                                                          *
6 .\" Permission is hereby granted, free of charge, to any person obtaining a  *
7 .\" copy of this software and associated documentation files (the            *
8 .\" "Software"), to deal in the Software without restriction, including      *
9 .\" without limitation the rights to use, copy, modify, merge, publish,      *
10 .\" distribute, distribute with modifications, sublicense, and/or sell       *
11 .\" copies of the Software, and to permit persons to whom the Software is    *
12 .\" furnished to do so, subject to the following conditions:                 *
13 .\"                                                                          *
14 .\" The above copyright notice and this permission notice shall be included  *
15 .\" in all copies or substantial portions of the Software.                   *
16 .\"                                                                          *
17 .\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS  *
18 .\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF               *
19 .\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.   *
20 .\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,   *
21 .\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR    *
22 .\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR    *
23 .\" THE USE OR OTHER DEALINGS IN THE SOFTWARE.                               *
24 .\"                                                                          *
25 .\" Except as contained in this notice, the name(s) of the above copyright   *
26 .\" holders shall not be used in advertising or otherwise to promote the     *
27 .\" sale, use or other dealings in this Software without prior written       *
28 .\" authorization.                                                           *
29 .\"***************************************************************************
30 .\"
31 .\" $Id: captoinfo.1m,v 1.50 2023/10/01 22:22:00 tom Exp $
32 .TH @CAPTOINFO@ 1M 2023-10-01 "ncurses 6.4" "User commands"
33 .ie \n(.g .ds `` \(lq
34 .el       .ds `` ``
35 .ie \n(.g .ds '' \(rq
36 .el       .ds '' ''
37 .ie \n(.g .ds `` \(lq
38 .el       .ds `` ``
39 .ie \n(.g .ds '' \(rq
40 .el       .ds '' ''
41 .ds n 5
42 .ds d /etc/termcap
43 .SH NAME
44 \fB\%@CAPTOINFO@\fP \-
45 convert a \fItermcap\fR description into a \fIterminfo\fR description
46 .SH SYNOPSIS
47 .B @CAPTOINFO@
48 .RI [ tic-option ]
49 .RI [ file
50 \&.\|.\|.]
51 .P
52 .B "@CAPTOINFO@ \-V"
53 .SH DESCRIPTION
54 \fB\%@CAPTOINFO@\fP looks in each given text
55 \fIfile\fP for \fItermcap\fP descriptions.
56 For each one found,
57 it writes an equivalent \fIterminfo\fP description to the standard
58 output stream.
59 \fItermcap\fP \fBtc\fP capabilities are translated directly to
60 \fIterminfo\fP \*(``\fBuse\fP\*('' capabilities.
61 .PP
62 If no \fIfile\fPs are specified,
63 \fB\%@CAPTOINFO@\fP interprets the content of the environment variable
64 \fB\%TERMCAP\fP as a file name,
65 and extracts only the entry for the terminal named in the environment
66 variable \fB\%TERM\fP from it.
67 If the environment variable \fB\%TERMCAP\fP is not set,
68 \fB\%@CAPTOINFO@\fP reads \fI\%\*d\fP.
69 .PP
70 This utility is implemented as a link to \fB\%@TIC@\fP(1M),
71 with the latter's
72 .B \-I
73 option implied.
74 You can use other \fB\%@TIC@\fP options such as
75 .BR \-1 ,
76 .BR \-f ,
77 .BR \-v ,
78 .BR \-w ,
79 and
80 .BR \-x .
81 .SS "Translations from nonstandard capabilities"
82 \fB\%@CAPTOINFO@\fP translates some obsolete,
83 nonstandard capabilities into standard (SVr4/XSI Curses) \fIterminfo\fP
84 capabilities.
85 It issues a diagnostic to the standard error stream for each,
86 inviting the user to check that it has not mistakenly translated an
87 unknown or mistyped capability name.
88 .PP
89 .TS
90 cb cb cb cb
91 cb cb cb cb
92 cb cb l  lb.
93 Nonstandard     Standard        \&      \f(BIterminfo\fP
94 name    name    From    capability
95 _
96 BO      mr      AT&T    enter_reverse_mode
97 CI      vi      AT&T    cursor_invisible
98 CV      ve      AT&T    cursor_normal
99 DS      mh      AT&T    enter_dim_mode
100 EE      me      AT&T    exit_attribute_mode
101 FE      LF      AT&T    label_on
102 FL      LO      AT&T    label_off
103 XS      mk      AT&T    enter_secure_mode
104 EN      @7      XENIX   key_end
105 GE      ae      XENIX   exit_alt_charset_mode
106 GS      as      XENIX   enter_alt_charset_mode
107 HM      kh      XENIX   key_home
108 LD      kL      XENIX   key_dl
109 PD      kN      XENIX   key_npage
110 PN      po      XENIX   prtr_off
111 PS      pf      XENIX   prtr_on
112 PU      kP      XENIX   key_ppage
113 RT      @8      XENIX   kent
114 UP      ku      XENIX   kcuu1
115 KA      k;      Tek     key_f10
116 KB      F1      Tek     key_f11
117 KC      F2      Tek     key_f12
118 KD      F3      Tek     key_f13
119 KE      F4      Tek     key_f14
120 KF      F5      Tek     key_f15
121 BC      Sb      Tek     set_background
122 FC      Sf      Tek     set_foreground
123 HS      mh      Iris    enter_dim_mode
124 .TE
125 .PP
126 XENIX \fItermcap\fP had a set of extension capabilities,
127 corresponding to box drawing characters of CCSID
128 (\*(``code page\*('') 437,
129 as follows.
130 .PP
131 .TS
132 cb cb
133 cb cb
134 cb l .
135 Termcap
136 Name    Graphic
137 _
138 G2      upper left corner
139 G3      lower left corner
140 G1      upper right corner
141 G4      lower right corner
142 GR      tee pointing right
143 GL      tee pointing left
144 GU      tee pointing up
145 GD      tee pointing down
146 GH      horizontal line
147 GV      vertical line
148 GC      intersection
149 G6      double upper left corner
150 G7      double lower left corner
151 G5      double upper right corner
152 G8      double lower right corner
153 Gr      double tee pointing right
154 Gr      double tee pointing left
155 Gu      double tee pointing up
156 Gd      double tee pointing down
157 Gh      double horizontal line
158 Gv      double vertical line
159 Gc      double intersection
160 .\" TODO: There are about 40 box drawing code points in CCSID 437;
161 .\" were there no XENIX capabilities for the mixed single- and double-
162 .\" line intersections?
163 .\"
164 .\" TODO: GG doesn't seem to fit with the others; explain it.
165 GG      ACS magic cookie count
166 .TE
167 .PP
168 If the single-line capabilities occur in an entry,
169 they are composed into an \fBacsc\fP string.
170 The double-line capabilities and
171 \fBGG\fP are discarded with a warning message.
172 .PP
173 IBM's AIX has a \fIterminfo\fP facility descended from SVr1
174 \fIterminfo\fP,
175 but which is incompatible with the SVr4 format.
176 \fB\%@CAPTOINFO@\fP translates the following AIX extensions.
177 .PP
178 .TS
179 cb cb
180 l  l .
181 IBM     XSI
182 _
183 ksel    kslt
184 kbtab   kcbt
185 font0   s0ds
186 font1   s1ds
187 font2   s2ds
188 font3   s3ds
189 .TE
190 .PP
191 Additionally,
192 this program translates the AIX \fBbox1\fP capability to an \fBacsc\fP
193 string.
194 .PP
195 The HP-UX \fIterminfo\fP library supports two nonstandard \fIterminfo\fP
196 capabilities,
197 \fBmeml\fP (memory lock) and \fBmemu\fP (memory unlock).
198 \fB\%@CAPTOINFO@\fP discards these with a warning message.
199 .SH FILES
200 .TP
201 \fI\*d\fP
202 default \fItermcap\fP terminal capability database
203 .SH NOTES
204 The verbose option is not identical to SVr4's.
205 Under SVr4, instead of following
206 the \fB\-v\fP with a trace level \fIn\fP,
207 you repeat it \fIn\fP times.
208 .SH PORTABILITY
209 X/Open Curses, Issue 7 (2009) describes \fBtic\fP briefly,
210 but omits this program.
211 SVr4 systems provide \fB\%captoinfo\fP as a separate application from
212 \fBtic\fP.
213 .PP
214 NetBSD does not provide this application.
215 .SH AUTHOR
216 Eric S. Raymond <esr@snark.thyrsus.com>
217 and
218 .br
219 Thomas E. Dickey <dickey@invisible-island.net>
220 .SH SEE ALSO
221 \fB\%@INFOCMP@\fP(1M),
222 \fB\%@TIC@\fP(1M),
223 \fB\%curses\fP(3X),
224 \fB\%terminfo\fP(\*n)