xref: /freebsd/usr.bin/tabs/tabs.1 (revision 732a02b4e77866604a120a275c082bb6221bd2ff)
1.\" Copyright (c) 2002 Tim J. Robbins.
2.\" All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\"    notice, this list of conditions and the following disclaimer.
9.\" 2. Redistributions in binary form must reproduce the above copyright
10.\"    notice, this list of conditions and the following disclaimer in the
11.\"    documentation and/or other materials provided with the distribution.
12.\"
13.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23.\" SUCH DAMAGE.
24.\"
25.\" $FreeBSD$
26.\"
27.Dd May 20, 2002
28.Dt TABS 1
29.Os
30.Sh NAME
31.Nm tabs
32.Nd set terminal tabs
33.Sh SYNOPSIS
34.Nm
35.Op Fl Ar n | Fl a | a2 | c | c2 | c3 | f | p | s | u
36.Op Cm +m Ns Op Ar n
37.Op Fl T Ar type
38.Nm
39.Op Fl T Ar type
40.Op Cm + Ns Op Ar n
41.Ar n1 Ns Op Ns , Ns Ar n2 , Ns ...
42.Sh DESCRIPTION
43The
44.Nm
45utility displays a series of characters that clear the hardware terminal
46tab settings then initialises tab stops at specified positions, and
47optionally adjusts the margin.
48.Pp
49In the first synopsis form, the tab stops set depend on the command line
50options used, and may be one of the predefined formats or at regular
51intervals.
52.Pp
53In the second synopsis form, tab stops are set at positions
54.Ar n1 , n2 ,
55etc.
56If a position is preceded by a
57.Ql + ,
58it is relative to the previous position set.
59No more than 20 positions may be specified.
60.Pp
61If no tab stops are specified, the
62.Dq standard
63.Ux
64tab width of 8 is used.
65.Pp
66The options are as follows:
67.Bl -tag -width indent
68.It Fl Ar n
69Set a tab stop every
70.Ar n
71columns.
72If
73.Ar n
74is 0, the tab stops are cleared but no new ones are set.
75.It Fl a
76Assembler format (columns 1, 10, 16, 36, 72).
77.It Fl a2
78Assembler format (columns 1, 10, 16, 40, 72).
79.It Fl c
80.Tn COBOL
81normal format (columns 1, 8, 12, 16, 20, 55)
82.It Fl c2
83.Tn COBOL
84compact format (columns 1, 6, 10, 14, 49)
85.It Fl c3
86.Tn COBOL
87compact format (columns 1, 6, 10, 14, 18, 22, 26, 30, 34, 38, 42, 46,
8850, 54, 58, 62, 67).
89.It Fl f
90.Tn FORTRAN
91format (columns 1, 7, 11, 15, 19, 23).
92.It Fl p
93.Tn PL/1
94format (columns 1, 5, 9, 13, 17, 21, 25, 29, 33, 37, 41, 45, 49, 53,
9557, 61).
96.It Fl s
97.Tn SNOBOL
98format (columns 1, 10, 55).
99.It Fl u
100Assembler format (columns 1, 12, 20, 44).
101.It Xo
102.Cm +m Ns Op Ar n ,
103.Cm + Ns Op Ar n
104.Xc
105Set an
106.Ar n
107character left margin, or 10 if
108.Ar n
109is omitted.
110.It Fl T Ar type
111Output escape sequence for the terminal type
112.Ar type .
113.El
114.Sh ENVIRONMENT
115The
116.Ev LANG , LC_ALL , LC_CTYPE
117and
118.Ev TERM
119environment variables affect the execution of
120.Nm
121as described in
122.Xr environ 7 .
123.Pp
124The
125.Fl T
126option overrides the setting of the
127.Ev TERM
128environment variable.
129If neither
130.Ev TERM
131nor the
132.Fl T
133option are present,
134.Nm
135will fail.
136.Sh EXIT STATUS
137.Ex -std
138.Sh SEE ALSO
139.Xr expand 1 ,
140.Xr stty 1 ,
141.Xr tput 1 ,
142.Xr unexpand 1 ,
143.Xr termcap 5
144.Sh STANDARDS
145The
146.Nm
147utility conforms to
148.St -p1003.1-2001 .
149.Sh HISTORY
150A
151.Nm
152utility appeared in PWB UNIX.
153This implementation was introduced in
154.Fx 5.0 .
155.Sh BUGS
156The current
157.Xr termcap 5
158database does not define the
159.Ql ML
160(set left soft margin) capability for any terminals.
161