Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1 | <!-- |
| 2 | * t |
| 3 | **************************************************************************** |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 4 | * Copyright (c) 1998-2014,2015 Free Software Foundation, Inc. * |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 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 | **************************************************************************** |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 30 | * @Id: infocmp.1m,v 1.56 2015/05/23 20:50:00 tom Exp @ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 31 | --> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 32 | <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 33 | <HTML> |
| 34 | <HEAD> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 35 | <meta http-equiv="Content-Type" content="text/html; charset=us-ascii"> |
| 36 | <meta name="generator" content="Manpage converted by man2html - see http://invisible-island.net/scripts/readme.html#others_scripts"> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 37 | <TITLE>infocmp 1m</TITLE> |
| 38 | <link rev=made href="mailto:bug-ncurses@gnu.org"> |
| 39 | <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> |
| 40 | </HEAD> |
| 41 | <BODY> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 42 | <H1 class="no-header">infocmp 1m</H1> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 43 | <PRE> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 44 | <STRONG><A HREF="infocmp.1m.html">infocmp(1m)</A></STRONG> <STRONG><A HREF="infocmp.1m.html">infocmp(1m)</A></STRONG> |
| 45 | |
| 46 | |
| 47 | |
| 48 | |
| 49 | </PRE> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 50 | <H2><a name="h2-NAME">NAME</a></H2><PRE> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 51 | <STRONG>infocmp</STRONG> - compare or print out <EM>terminfo</EM> descriptions |
| 52 | |
| 53 | |
| 54 | </PRE> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 55 | <H2><a name="h2-SYNOPSIS">SYNOPSIS</a></H2><PRE> |
| 56 | <STRONG>infocmp</STRONG> [<STRONG>-1CDEFGIKLTUVcdegilnpqrtux</STRONG>] |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 57 | [<STRONG>-v</STRONG> <EM>n</EM>] [<STRONG>-s</STRONG> <STRONG>d</STRONG>| <STRONG>i</STRONG>| <STRONG>l</STRONG>| <STRONG>c</STRONG>] [<STRONG>-R</STRONG> <STRONG>subset</STRONG>] |
| 58 | [<STRONG>-w</STRONG> <EM>width</EM>] [<STRONG>-A</STRONG> <EM>directory</EM>] [<STRONG>-B</STRONG> <EM>directory</EM>] |
| 59 | [<EM>termname</EM>...] |
| 60 | |
| 61 | |
| 62 | </PRE> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 63 | <H2><a name="h2-DESCRIPTION">DESCRIPTION</a></H2><PRE> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 64 | <STRONG>infocmp</STRONG> can be used to compare a binary <STRONG>terminfo</STRONG> entry |
| 65 | with other terminfo entries, rewrite a <STRONG>terminfo</STRONG> descrip- |
| 66 | tion to take advantage of the <STRONG>use=</STRONG> terminfo field, or |
| 67 | print out a <STRONG>terminfo</STRONG> description from the binary file |
| 68 | (<STRONG>term</STRONG>) in a variety of formats. In all cases, the boolean |
| 69 | fields will be printed first, followed by the numeric |
| 70 | fields, followed by the string fields. |
| 71 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 72 | |
| 73 | </PRE> |
| 74 | <H3><a name="h3-Default-Options">Default Options</a></H3><PRE> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 75 | If no options are specified and zero or one <EM>termnames</EM> are |
| 76 | specified, the <STRONG>-I</STRONG> option will be assumed. If more than |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 77 | one <EM>termname</EM> is specified, the <STRONG>-d</STRONG> option will be assumed. |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 78 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 79 | |
| 80 | </PRE> |
| 81 | <H3><a name="h3-Comparison-Options-_-d_-_-c_-_-n_">Comparison Options [-d] [-c] [-n]</a></H3><PRE> |
| 82 | <STRONG>infocmp</STRONG> compares the <STRONG>terminfo</STRONG> description of the first |
| 83 | terminal <EM>termname</EM> with each of the descriptions given by |
| 84 | the entries for the other terminal's <EM>termnames</EM>. If a |
| 85 | capability is defined for only one of the terminals, the |
| 86 | value returned will depend on the type of the capability: |
| 87 | <STRONG>F</STRONG> for boolean variables, <STRONG>-1</STRONG> for integer variables, and |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 88 | <STRONG>NULL</STRONG> for string variables. |
| 89 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 90 | The <STRONG>-d</STRONG> option produces a list of each capability that is |
| 91 | different between two entries. This option is useful to |
| 92 | show the difference between two entries, created by dif- |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 93 | ferent people, for the same or similar terminals. |
| 94 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 95 | The <STRONG>-c</STRONG> option produces a list of each capability that is |
| 96 | common between two or more entries. Capabilities that are |
| 97 | not set are ignored. This option can be used as a quick |
| 98 | check to see if the <STRONG>-u</STRONG> option is worth using. |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 99 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 100 | The <STRONG>-n</STRONG> option produces a list of each capability that is |
| 101 | in none of the given entries. If no <EM>termnames</EM> are given, |
| 102 | the environment variable <STRONG>TERM</STRONG> will be used for both of the |
| 103 | <EM>termnames</EM>. This can be used as a quick check to see if |
| 104 | anything was left out of a description. |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 105 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 106 | |
| 107 | </PRE> |
| 108 | <H3><a name="h3-Source-Listing-Options-_-I_-_-L_-_-C_-_-r_">Source Listing Options [-I] [-L] [-C] [-r]</a></H3><PRE> |
| 109 | The <STRONG>-I</STRONG>, <STRONG>-L</STRONG>, and <STRONG>-C</STRONG> options will produce a source listing |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 110 | for each terminal named. |
| 111 | |
| 112 | <STRONG>-I</STRONG> use the <STRONG>terminfo</STRONG> names |
| 113 | <STRONG>-L</STRONG> use the long C variable name listed in <<STRONG>term.h</STRONG>> |
| 114 | <STRONG>-C</STRONG> use the <STRONG>termcap</STRONG> names |
| 115 | <STRONG>-r</STRONG> when using <STRONG>-C</STRONG>, put out all capabilities in <STRONG>termcap</STRONG> form |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 116 | <STRONG>-K</STRONG> modifies the <STRONG>-C</STRONG> option, improving BSD-compatibility. |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 117 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 118 | If no <EM>termnames</EM> are given, the environment variable <STRONG>TERM</STRONG> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 119 | will be used for the terminal name. |
| 120 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 121 | The source produced by the <STRONG>-C</STRONG> option may be used directly |
| 122 | as a <STRONG>termcap</STRONG> entry, but not all parameterized strings can |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 123 | be changed to the <STRONG>termcap</STRONG> format. <STRONG>infocmp</STRONG> will attempt to |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 124 | convert most of the parameterized information, and any- |
| 125 | thing not converted will be plainly marked in the output |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 126 | and commented out. These should be edited by hand. |
| 127 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 128 | For best results when converting to <STRONG>termcap</STRONG> format, you |
| 129 | should use both <STRONG>-C</STRONG> and <STRONG>-r</STRONG>. Normally a termcap description |
| 130 | is limited to 1023 bytes. infocmp trims away less essen- |
| 131 | tial parts to make it fit. If you are converting to one |
| 132 | of the (rare) termcap implementations which accept an |
| 133 | unlimited size of termcap, you may want to add the <STRONG>-T</STRONG> |
| 134 | option. More often however, you must help the termcap |
| 135 | implementation, and trim excess whitespace (use the <STRONG>-0</STRONG> |
| 136 | option for that). |
| 137 | |
| 138 | All padding information for strings will be collected |
| 139 | together and placed at the beginning of the string where |
| 140 | <STRONG>termcap</STRONG> expects it. Mandatory padding (padding informa- |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 141 | tion with a trailing '/') will become optional. |
| 142 | |
| 143 | All <STRONG>termcap</STRONG> variables no longer supported by <STRONG>terminfo</STRONG>, but |
| 144 | which are derivable from other <STRONG>terminfo</STRONG> variables, will be |
| 145 | output. Not all <STRONG>terminfo</STRONG> capabilities will be translated; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 146 | only those variables which were part of <STRONG>termcap</STRONG> will nor- |
| 147 | mally be output. Specifying the <STRONG>-r</STRONG> option will take off |
| 148 | this restriction, allowing all capabilities to be output |
| 149 | in <EM>termcap</EM> form. Normally you would use both the <STRONG>-C</STRONG> and |
| 150 | <STRONG>-r</STRONG> options. The actual format used incorporates some |
| 151 | improvements for escaped characters from terminfo format. |
| 152 | For a stricter BSD-compatible translation, use the <STRONG>-K</STRONG> |
| 153 | option rather than <STRONG>-C</STRONG>. |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 154 | |
| 155 | Note that because padding is collected to the beginning of |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 156 | the capability, not all capabilities are output. Manda- |
| 157 | tory padding is not supported. Because <STRONG>termcap</STRONG> strings |
| 158 | are not as flexible, it is not always possible to convert |
| 159 | a <STRONG>terminfo</STRONG> string capability into an equivalent <STRONG>termcap</STRONG> |
| 160 | format. A subsequent conversion of the <STRONG>termcap</STRONG> file back |
| 161 | into <STRONG>terminfo</STRONG> format will not necessarily reproduce the |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 162 | original <STRONG>terminfo</STRONG> source. |
| 163 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 164 | Some common <STRONG>terminfo</STRONG> parameter sequences, their <STRONG>termcap</STRONG> |
| 165 | equivalents, and some terminal types which commonly have |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 166 | such sequences, are: |
| 167 | |
| 168 | <STRONG>terminfo</STRONG> <STRONG>termcap</STRONG> Representative Terminals |
| 169 | --------------------------------------------------------------- |
| 170 | <STRONG>%p1%c</STRONG> <STRONG>%.</STRONG> adm |
| 171 | <STRONG>%p1%d</STRONG> <STRONG>%d</STRONG> hp, ANSI standard, vt100 |
| 172 | <STRONG>%p1%'x'%+%c</STRONG> <STRONG>%+x</STRONG> concept |
| 173 | <STRONG>%i</STRONG> <STRONG>%i</STRONG>q ANSI standard, vt100 |
| 174 | <STRONG>%p1%?%'x'%>%t%p1%'y'%+%;</STRONG> <STRONG>%>xy</STRONG> concept |
| 175 | <STRONG>%p2</STRONG> is printed before <STRONG>%p1</STRONG> <STRONG>%r</STRONG> hp |
| 176 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 177 | |
| 178 | </PRE> |
| 179 | <H3><a name="h3-Use_-Option-_-u_">Use= Option [-u]</a></H3><PRE> |
| 180 | The <STRONG>-u</STRONG> option produces a <STRONG>terminfo</STRONG> source description of |
| 181 | the first terminal <EM>termname</EM> which is relative to the sum |
| 182 | of the descriptions given by the entries for the other |
| 183 | terminals <EM>termnames</EM>. It does this by analyzing the dif- |
| 184 | ferences between the first <EM>termname</EM> and the other |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 185 | <EM>termnames</EM> and producing a description with <STRONG>use=</STRONG> fields for |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 186 | the other terminals. In this manner, it is possible to |
| 187 | retrofit generic terminfo entries into a terminal's |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 188 | description. Or, if two similar terminals exist, but were |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 189 | coded at different times or by different people so that |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 190 | each description is a full description, using <STRONG>infocmp</STRONG> will |
| 191 | show what can be done to change one description to be rel- |
| 192 | ative to the other. |
| 193 | |
| 194 | A capability will get printed with an at-sign (@) if it no |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 195 | longer exists in the first <EM>termname</EM>, but one of the other |
| 196 | <EM>termname</EM> entries contains a value for it. A capability's |
| 197 | value gets printed if the value in the first <EM>termname</EM> is |
| 198 | not found in any of the other <EM>termname</EM> entries, or if the |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 199 | first of the other <EM>termname</EM> entries that has this capabil- |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 200 | ity gives a different value for the capability than that |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 201 | in the first <EM>termname</EM>. |
| 202 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 203 | The order of the other <EM>termname</EM> entries is significant. |
| 204 | Since the terminfo compiler <STRONG>tic</STRONG> does a left-to-right scan |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 205 | of the capabilities, specifying two <STRONG>use=</STRONG> entries that con- |
| 206 | tain differing entries for the same capabilities will pro- |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 207 | duce different results depending on the order that the |
| 208 | entries are given in. <STRONG>infocmp</STRONG> will flag any such incon- |
| 209 | sistencies between the other <EM>termname</EM> entries as they are |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 210 | found. |
| 211 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 212 | Alternatively, specifying a capability <EM>after</EM> a <STRONG>use=</STRONG> entry |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 213 | that contains that capability will cause the second speci- |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 214 | fication to be ignored. Using <STRONG>infocmp</STRONG> to recreate a |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 215 | description can be a useful check to make sure that every- |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 216 | thing was specified correctly in the original source |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 217 | description. |
| 218 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 219 | Another error that does not cause incorrect compiled |
| 220 | files, but will slow down the compilation time, is speci- |
| 221 | fying extra <STRONG>use=</STRONG> fields that are superfluous. <STRONG>infocmp</STRONG> |
| 222 | will flag any other <EM>termname</EM> <EM>use=</EM> fields that were not |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 223 | needed. |
| 224 | |
| 225 | <STRONG>Changing</STRONG> <STRONG>Databases</STRONG> <STRONG>[-A</STRONG> <EM>directory</EM>] [-B <EM>directory</EM>] |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 226 | Like other <STRONG>ncurses</STRONG> utilities, infocmp looks for the termi- |
| 227 | nal descriptions in several places. You can use the <STRONG>TER-</STRONG> |
| 228 | <STRONG>MINFO</STRONG> and <STRONG>TERMINFO_DIRS</STRONG> environment variables to override |
| 229 | the compiled-in default list of places to search (see |
| 230 | <STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG> for details). |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 231 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 232 | You can also use the options <STRONG>-A</STRONG> and <STRONG>-B</STRONG> to override the |
| 233 | list of places to search when comparing terminal descrip- |
| 234 | tions: |
| 235 | |
| 236 | <STRONG>o</STRONG> The <STRONG>-A</STRONG> option sets the location for the first <EM>termname</EM> |
| 237 | |
| 238 | <STRONG>o</STRONG> The <STRONG>-B</STRONG> option sets the location for the other |
| 239 | <EM>termnames</EM>. |
| 240 | |
| 241 | Using these options, it is possible to compare descrip- |
| 242 | tions for a terminal with the same name located in two |
| 243 | different databases. For instance, you can use this fea- |
| 244 | ture for comparing descriptions for the same terminal cre- |
| 245 | ated by different people. |
| 246 | |
| 247 | |
| 248 | </PRE> |
| 249 | <H3><a name="h3-Other-Options">Other Options</a></H3><PRE> |
| 250 | <STRONG>-0</STRONG> causes the fields to be printed on one line, without |
| 251 | wrapping. |
| 252 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 253 | <STRONG>-1</STRONG> causes the fields to be printed out one to a line. |
| 254 | Otherwise, the fields will be printed several to a |
| 255 | line to a maximum width of 60 characters. |
| 256 | |
| 257 | <STRONG>-a</STRONG> tells <STRONG>infocmp</STRONG> to retain commented-out capabilities |
| 258 | rather than discarding them. Capabilities are com- |
| 259 | mented by prefixing them with a period. |
| 260 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 261 | <STRONG>-D</STRONG> tells <STRONG>infocmp</STRONG> to print the database locations that it |
| 262 | knows about, and exit. |
| 263 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 264 | <STRONG>-E</STRONG> Dump the capabilities of the given terminal as |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 265 | tables, needed in the C initializer for a TERMTYPE |
| 266 | structure (the terminal capability structure in the |
| 267 | <STRONG><term.h></STRONG>). This option is useful for preparing ver- |
| 268 | sions of the curses library hardwired for a given |
| 269 | terminal type. The tables are all declared static, |
| 270 | and are named according to the type and the name of |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 271 | the corresponding terminal entry. |
| 272 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 273 | Before ncurses 5.0, the split between the <STRONG>-e</STRONG> and <STRONG>-E</STRONG> |
| 274 | options was not needed; but support for extended |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 275 | names required making the arrays of terminal capabil- |
| 276 | ities separate from the TERMTYPE structure. |
| 277 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 278 | <STRONG>-e</STRONG> Dump the capabilities of the given terminal as a C |
| 279 | initializer for a TERMTYPE structure (the terminal |
| 280 | capability structure in the <STRONG><term.h></STRONG>). This option |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 281 | is useful for preparing versions of the curses |
| 282 | library hardwired for a given terminal type. |
| 283 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 284 | <STRONG>-F</STRONG> compare terminfo files. This assumes that two fol- |
| 285 | lowing arguments are filenames. The files are |
| 286 | searched for pairwise matches between entries, with |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 287 | two entries considered to match if any of their names |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 288 | do. The report printed to standard output lists |
| 289 | entries with no matches in the other file, and |
| 290 | entries with more than one match. For entries with |
| 291 | exactly one match it includes a difference report. |
| 292 | Normally, to reduce the volume of the report, use |
| 293 | references are not resolved before looking for dif- |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 294 | ferences, but resolution can be forced by also speci- |
| 295 | fying <STRONG>-r</STRONG>. |
| 296 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 297 | <STRONG>-f</STRONG> Display complex terminfo strings which contain |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 298 | if/then/else/endif expressions indented for readabil- |
| 299 | ity. |
| 300 | |
| 301 | <STRONG>-G</STRONG> Display constant literals in decimal form rather than |
| 302 | their character equivalents. |
| 303 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 304 | <STRONG>-g</STRONG> Display constant character literals in quoted form |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 305 | rather than their decimal equivalents. |
| 306 | |
| 307 | <STRONG>-i</STRONG> Analyze the initialization (<STRONG>is1</STRONG>, <STRONG>is2</STRONG>, <STRONG>is3</STRONG>), and reset |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 308 | (<STRONG>rs1</STRONG>, <STRONG>rs2</STRONG>, <STRONG>rs3</STRONG>), strings in the entry, as well as |
| 309 | those used for starting/stopping cursor-positioning |
| 310 | mode (<STRONG>smcup</STRONG>, <STRONG>rmcup</STRONG>) as well as starting/stopping |
| 311 | keymap mode (<STRONG>smkx</STRONG>, <STRONG>rmkx</STRONG>). |
| 312 | |
| 313 | For each string, the code tries to analyze it into |
| 314 | actions in terms of the other capabilities in the |
| 315 | entry, certain X3.64/ISO 6429/ECMA-48 capabilities, |
| 316 | and certain DEC VT-series private modes (the set of |
| 317 | recognized special sequences has been selected for |
| 318 | completeness over the existing terminfo database). |
| 319 | Each report line consists of the capability name, |
| 320 | followed by a colon and space, followed by a print- |
| 321 | able expansion of the capability string with sections |
| 322 | matching recognized actions translated into {}-brack- |
| 323 | eted descriptions. |
| 324 | |
| 325 | Here is a list of the DEC/ANSI special sequences rec- |
| 326 | ognized: |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 327 | |
| 328 | Action Meaning |
| 329 | ----------------------------------------- |
| 330 | RIS full reset |
| 331 | SC save cursor |
| 332 | RC restore cursor |
| 333 | LL home-down |
| 334 | RSR reset scroll region |
| 335 | ----------------------------------------- |
| 336 | DECSTR soft reset (VT320) |
| 337 | S7C1T 7-bit controls (VT220) |
| 338 | ----------------------------------------- |
| 339 | ISO DEC G0 enable DEC graphics for G0 |
| 340 | ISO UK G0 enable UK chars for G0 |
| 341 | ISO US G0 enable US chars for G0 |
| 342 | ISO DEC G1 enable DEC graphics for G1 |
| 343 | ISO UK G1 enable UK chars for G1 |
| 344 | ISO US G1 enable US chars for G1 |
| 345 | ----------------------------------------- |
| 346 | DECPAM application keypad mode |
| 347 | DECPNM normal keypad mode |
| 348 | DECANSI enter ANSI mode |
| 349 | ----------------------------------------- |
| 350 | ECMA[+-]AM keyboard action mode |
| 351 | ECMA[+-]IRM insert replace mode |
| 352 | ECMA[+-]SRM send receive mode |
| 353 | ECMA[+-]LNM linefeed mode |
| 354 | ----------------------------------------- |
| 355 | DEC[+-]CKM application cursor keys |
| 356 | DEC[+-]ANM set VT52 mode |
| 357 | DEC[+-]COLM 132-column mode |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 358 | DEC[+-]SCLM smooth scroll |
| 359 | DEC[+-]SCNM reverse video mode |
| 360 | DEC[+-]OM origin mode |
| 361 | DEC[+-]AWM wraparound mode |
| 362 | DEC[+-]ARM auto-repeat mode |
| 363 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 364 | It also recognizes a SGR action corresponding to |
| 365 | ANSI/ISO 6429/ECMA Set Graphics Rendition, with the |
| 366 | values NORMAL, BOLD, UNDERLINE, BLINK, and REVERSE. |
| 367 | All but NORMAL may be prefixed with `+' (turn on) or |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 368 | `-' (turn off). |
| 369 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 370 | An SGR0 designates an empty highlight sequence |
| 371 | (equivalent to {SGR:NORMAL}). |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 372 | |
| 373 | <STRONG>-l</STRONG> Set output format to terminfo. |
| 374 | |
| 375 | <STRONG>-p</STRONG> Ignore padding specifications when comparing strings. |
| 376 | |
| 377 | <STRONG>-q</STRONG> Make the comparison listing shorter by omitting sub- |
| 378 | headings, and using "-" for absent capabilities, "@" |
| 379 | for canceled rather than "NULL". |
| 380 | |
| 381 | <STRONG>-R</STRONG><EM>subset</EM> |
| 382 | Restrict output to a given subset. This option is |
| 383 | for use with archaic versions of terminfo like those |
| 384 | on SVr1, Ultrix, or HP/UX that do not support the |
| 385 | full set of SVR4/XSI Curses terminfo; and variants |
| 386 | such as AIX that have their own extensions incompati- |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 387 | ble with SVr4/XSI. |
| 388 | |
| 389 | Available terminfo subsets are "SVr1", "Ultrix", |
| 390 | "HP", and "AIX"; see <STRONG><A HREF="terminfo.5.html">terminfo(5)</A></STRONG> for details. You |
| 391 | can also choose the subset "BSD" which selects only |
| 392 | capabilities with termcap equivalents recognized by |
| 393 | 4.4BSD. |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 394 | |
| 395 | <STRONG>-s</STRONG> <EM>[d|i|l|c]</EM> |
| 396 | The <STRONG>-s</STRONG> option sorts the fields within each type |
| 397 | according to the argument below: |
| 398 | |
| 399 | <STRONG>d</STRONG> leave fields in the order that they are stored |
| 400 | in the <EM>terminfo</EM> database. |
| 401 | |
| 402 | <STRONG>i</STRONG> sort by <EM>terminfo</EM> name. |
| 403 | |
| 404 | <STRONG>l</STRONG> sort by the long C variable name. |
| 405 | |
| 406 | <STRONG>c</STRONG> sort by the <EM>termcap</EM> name. |
| 407 | |
| 408 | If the <STRONG>-s</STRONG> option is not given, the fields printed out |
| 409 | will be sorted alphabetically by the <STRONG>terminfo</STRONG> name |
| 410 | within each type, except in the case of the <STRONG>-C</STRONG> or the |
| 411 | <STRONG>-L</STRONG> options, which cause the sorting to be done by the |
| 412 | <STRONG>termcap</STRONG> name or the long C variable name, respec- |
| 413 | tively. |
| 414 | |
| 415 | <STRONG>-T</STRONG> eliminates size-restrictions on the generated text. |
| 416 | This is mainly useful for testing and analysis, since |
| 417 | the compiled descriptions are limited (e.g., 1023 for |
| 418 | termcap, 4096 for terminfo). |
| 419 | |
| 420 | <STRONG>-t</STRONG> tells <STRONG>tic</STRONG> to discard commented-out capabilities. |
| 421 | Normally when translating from terminfo to termcap, |
| 422 | untranslatable capabilities are commented-out. |
| 423 | |
| 424 | <STRONG>-U</STRONG> tells <STRONG>infocmp</STRONG> to not post-process the data after |
| 425 | parsing the source file. This feature helps when |
| 426 | comparing the actual contents of two source files, |
| 427 | since it excludes the inferences that <STRONG>infocmp</STRONG> makes |
| 428 | to fill in missing data. |
| 429 | |
| 430 | <STRONG>-V</STRONG> reports the version of ncurses which was used in this |
| 431 | program, and exits. |
| 432 | |
| 433 | <STRONG>-v</STRONG> <EM>n</EM> prints out tracing information on standard error as |
| 434 | the program runs. Higher values of n induce greater |
| 435 | verbosity. |
| 436 | |
| 437 | <STRONG>-w</STRONG> <EM>width</EM> |
| 438 | changes the output to <EM>width</EM> characters. |
| 439 | |
| 440 | <STRONG>-x</STRONG> print information for user-defined capabilities. |
| 441 | These are extensions to the terminfo repertoire which |
| 442 | can be loaded using the <STRONG>-x</STRONG> option of <STRONG>tic</STRONG>. |
| 443 | |
| 444 | |
| 445 | </PRE> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 446 | <H2><a name="h2-FILES">FILES</a></H2><PRE> |
| 447 | /usr/share/terminfo Compiled terminal description data- |
| 448 | base. |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 449 | |
| 450 | |
| 451 | </PRE> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 452 | <H2><a name="h2-EXTENSIONS">EXTENSIONS</a></H2><PRE> |
| 453 | The <STRONG>-0</STRONG>, <STRONG>-1</STRONG>, <STRONG>-E</STRONG>, <STRONG>-F</STRONG>, <STRONG>-G</STRONG>, <STRONG>-R</STRONG>, <STRONG>-T</STRONG>, <STRONG>-V</STRONG>, <STRONG>-a</STRONG>, <STRONG>-e</STRONG>, <STRONG>-f</STRONG>, <STRONG>-g</STRONG>, <STRONG>-i</STRONG>, |
| 454 | <STRONG>-l</STRONG>, <STRONG>-p</STRONG>, <STRONG>-q</STRONG> and <STRONG>-t</STRONG> options are not supported in SVr4 |
| 455 | curses. |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 456 | |
| 457 | The <STRONG>-r</STRONG> option's notion of `termcap' capabilities is System |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 458 | V Release 4's. Actual BSD curses versions will have a |
| 459 | more restricted set. To see only the 4.4BSD set, use <STRONG>-r</STRONG> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 460 | <STRONG>-RBSD</STRONG>. |
| 461 | |
| 462 | |
| 463 | </PRE> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 464 | <H2><a name="h2-BUGS">BUGS</a></H2><PRE> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 465 | The <STRONG>-F</STRONG> option of <STRONG><A HREF="infocmp.1m.html">infocmp(1m)</A></STRONG> should be a <STRONG><A HREF="toe.1m.html">toe(1m)</A></STRONG> mode. |
| 466 | |
| 467 | |
| 468 | </PRE> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 469 | <H2><a name="h2-SEE-ALSO">SEE ALSO</a></H2><PRE> |
| 470 | <STRONG><A HREF="captoinfo.1m.html">captoinfo(1m)</A></STRONG>, <STRONG><A HREF="infotocap.1m.html">infotocap(1m)</A></STRONG>, <STRONG><A HREF="tic.1m.html">tic(1m)</A></STRONG>, <STRONG><A HREF="toe.1m.html">toe(1m)</A></STRONG>, |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 471 | <STRONG><A HREF="ncurses.3x.html">curses(3x)</A></STRONG>, <STRONG><A HREF="terminfo.5.html">terminfo(5)</A></STRONG>. |
| 472 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 473 | http://invisible-island.net/ncurses/tctest.html |
| 474 | |
| 475 | This describes <STRONG>ncurses</STRONG> version 6.0 (patch 20150808). |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 476 | |
| 477 | |
| 478 | </PRE> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 479 | <H2><a name="h2-AUTHOR">AUTHOR</a></H2><PRE> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 480 | Eric S. Raymond <esr@snark.thyrsus.com> and |
| 481 | Thomas E. Dickey <dickey@invisible-island.net> |
| 482 | |
| 483 | |
| 484 | |
| 485 | <STRONG><A HREF="infocmp.1m.html">infocmp(1m)</A></STRONG> |
| 486 | </PRE> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 487 | <div class="nav"> |
| 488 | <ul> |
| 489 | <li><a href="#h2-NAME">NAME</a></li> |
| 490 | <li><a href="#h2-SYNOPSIS">SYNOPSIS</a></li> |
| 491 | <li><a href="#h2-DESCRIPTION">DESCRIPTION</a> |
| 492 | <ul> |
| 493 | <li><a href="#h3-Default-Options">Default Options</a></li> |
| 494 | <li><a href="#h3-Comparison-Options-_-d_-_-c_-_-n_">Comparison Options [-d] [-c] [-n]</a></li> |
| 495 | <li><a href="#h3-Source-Listing-Options-_-I_-_-L_-_-C_-_-r_">Source Listing Options [-I] [-L] [-C] [-r]</a></li> |
| 496 | <li><a href="#h3-Use_-Option-_-u_">Use= Option [-u]</a></li> |
| 497 | <li><a href="#h3-Other-Options">Other Options</a></li> |
| 498 | </ul> |
| 499 | </li> |
| 500 | <li><a href="#h2-FILES">FILES</a></li> |
| 501 | <li><a href="#h2-EXTENSIONS">EXTENSIONS</a></li> |
| 502 | <li><a href="#h2-BUGS">BUGS</a></li> |
| 503 | <li><a href="#h2-SEE-ALSO">SEE ALSO</a></li> |
| 504 | <li><a href="#h2-AUTHOR">AUTHOR</a></li> |
| 505 | </ul> |
| 506 | </div> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 507 | </BODY> |
| 508 | </HTML> |