NetBSD/usr.sbin/chrtbl/chrtbl.8

90 lines
4.1 KiB
Groff

.\" $NetBSD: chrtbl.8,v 1.1 1997/06/02 10:16:43 kleink Exp $
.\"
.\" Copyright (c) 1997 Christos Zoulas
.\" All rights reserved.
.\"
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted provided that the following conditions
.\" are met:
.\" 1. Redistributions of source code must retain the above copyright
.\" notice, this list of conditions and the following disclaimer.
.\" 2. Redistributions in binary form must reproduce the above copyright
.\" notice, this list of conditions and the following disclaimer in the
.\" documentation and/or other materials provided with the distribution.
.\" 3. All advertising materials mentioning features or use of this software
.\" must display the following acknowledgement:
.\" This product includes software developed by Christos Zoulas.
.\" 4. The name of the author may not be used to endorse or promote products
.\" derived from this software without specific prior written permission.
.\"
.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
.\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.\"
.Dd May 12, 1997
.Dt CHRTBL 8
.Os
.Sh NAME
.Nm chrtbl
.Nd create character classification and upper <-> lower conversion tables
.Sh SYNOPSIS
.Nm crtbl
.Op Fl o Ar ofile
.Ar ifile
.Sh DESCRIPTION
.Nm
creates character classification and upper <-> lower conversion tables for
single byte files. The
.Nm
command is modelled after the Solaris/SVR4 command. The input file is similar
and contains a keyword per line followed by characters or ranges. Valid
keywords are:
.Bl -tag -width indent
.It Nm LC_CTYPE Ar filename
Set the filename for the character classification output.
.It Nm LC_NUMERIC Ar filename
Set the filename for the numeric formatting output.
.It Nm isupper Ar begin-char Op - Ar end-char
Set the attribute of the specified characters range(s) to be upper case.
.It Nm islower Ar begin-char Op - Ar end-char
Set the attribute of the specified characters range(s) to be lower case.
.It Nm isdigit Ar begin-char Op - Ar end-char
Set the attribute of the specified characters range(s) to be numeric.
.It Nm isspace Ar begin-char Op - Ar end-char
Set the attribute of the specified characters range(s) to be space.
.It Nm ispunct Ar begin-char Op - Ar end-char
Set the attribute of the specified characters range(s) to be punctuation.
.It Nm iscntrl Ar begin-char Op - Ar end-char
Set the attribute of the specified characters range(s) to be control.
.It Nm isxdigit Ar begin-char Op - Ar end-char
Set the attribute of the specified characters range(s) to be hexadecimal digits.
.It Nm isblank Ar begin-char Op - Ar end-char
Set the attribute of the specified characters range(s) to be blank.
.It Nm ul Ar <upper-char lower-char> ...
Specify a case correspondance between upper and lower char.
.It Nm cswidth Ar n1,s1:n2,s2:n3,s3
Specify the character set byte width (n1,n2,n3) and the screen width(s1,s2,s3)
for the 3 character sets.
.It Nm decimal_point Ar char
Specify the decimal point numeric formatting character.
.It Nm thousands_sep Ar char
Specify the thousands separator numeric formatting character.
.El
.Ss Available options:
.Bl -tag -width indent
.It Fl o Ar ofile
Print the convertion tables in a human readable (C source) form.
.Sh SEE ALSO
.Xr setlocale 3
.Sh BUGS
Preliminary support of LC_NUMERIC is present, but not currently fully
implemented. No support for wide character locales. Support for alternate
localized character sets and numeric formatting is currently not implemented.