summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to 'doc')
-rw-r--r--doc/clock.n9
-rw-r--r--doc/fblocked.n4
-rw-r--r--doc/format.n14
-rw-r--r--doc/lsort.n26
-rw-r--r--doc/pkgMkIndex.n6
-rw-r--r--doc/regsub.n18
-rw-r--r--doc/scan.n29
-rw-r--r--doc/tclvars.n12
8 files changed, 68 insertions, 50 deletions
diff --git a/doc/clock.n b/doc/clock.n
index f4c3805..56a139e 100644
--- a/doc/clock.n
+++ b/doc/clock.n
@@ -161,12 +161,14 @@ the environment variable \fBTZ\fR.
.IP [3]
on Windows systems, the time zone settings from the Control Panel.
.RE
+.PP
If none of these is present, the C \fBlocaltime\fR and \fBmktime\fR
functions are used to attempt to convert times between local and
Greenwich. On 32-bit systems, this approach is likely to have bugs,
particularly for times that lie outside the window (approximately the
years 1902 to 2037) that can be represented in a 32-bit integer.
.SH "CLOCK ARITHMETIC"
+.PP
The \fBclock add\fR command performs clock arithmetic on a value
(expressed as nominal seconds from the epoch time of 1 January 1970, 00:00 UTC)
given as its first argument. The remaining arguments (other than the
@@ -275,6 +277,7 @@ years as they are when adding/subtracting days and weeks.
If multiple \fIcount unit\fR pairs are present on the command, they
are evaluated consecutively, from left to right.
.SH "HIGH RESOLUTION TIMERS"
+.PP
Most of the subcommands supported by the \fBclock\fR command deal with
times represented as a count of seconds from the epoch time, and this is the
representation that \fBclock seconds\fR returns. There are three exceptions,
@@ -289,6 +292,7 @@ epoch; it is simply intended to be the most precise interval timer
available, and is intended only for relative timing studies such as
benchmarks.
.SH "FORMATTING TIMES"
+.PP
The \fBclock format\fR command produces times for display to a user
or writing to an external medium. The command accepts times that are
expressed in seconds from the epoch time of 1 January 1970, 00:00 UTC,
@@ -327,6 +331,7 @@ platforms that do not define a user selection of date and time formats
separate from \fBLC_TIME\fR, \fB\-locale\fR \fBsystem\fR is
synonymous with \fB\-locale\fR \fBcurrent\fR.
.SH "SCANNING TIMES"
+.PP
The \fBclock scan\fR command accepts times that are formatted as
strings and converts them to counts of seconds from the epoch time
of 1 January 1970, 00:00 UTC. It normally takes a \fB\-format\fR
@@ -449,6 +454,7 @@ If this situation occurs, the first occurrence of the time is chosen.
time zone when converting local times. This caveat does not apply to
UTC times.)
.SH "FORMAT GROUPS"
+.PP
The following format groups are recognized by the \fBclock scan\fR and
\fBclock format\fR commands.
.TP
@@ -738,6 +744,7 @@ character.
Synonymous with
.QW "\fB%a %b %e %H:%M:%S %Z %Y\fR" .
.SH "TIME ZONES"
+.PP
When the \fBclock\fR command is processing a local time, it has several
possible sources for the time zone to use. In order of preference, they
are:
@@ -825,10 +832,12 @@ rules change again.
Any other time zone string is processed by prefixing a colon and attempting
to use it as a location name, as above.
.SH "LOCALIZATION"
+.PP
Developers wishing to localize the date and time formatting and parsing
are referred to \fIhttp://tip.tcl.tk/173\fR for a
specification.
.SH "FREE FORM SCAN"
+.PP
If the \fBclock scan\fR command is invoked without a \fB\-format\fR
option, then it requests a \fIfree-form scan.\fR \fI
This form of scan is deprecated.\fR The reason for the deprecation
diff --git a/doc/fblocked.n b/doc/fblocked.n
index 5b5efac..a426b27 100644
--- a/doc/fblocked.n
+++ b/doc/fblocked.n
@@ -4,7 +4,7 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
-'\" RCS: @(#) $Id: fblocked.n,v 1.8 2005/05/10 18:33:59 kennykb Exp $
+'\" RCS: @(#) $Id: fblocked.n,v 1.9 2009/02/24 21:04:58 dkf Exp $
.so man.macros
.TH fblocked n 7.5 Tcl "Tcl Built-In Commands"
.BS
@@ -63,9 +63,7 @@ proc echoLine {chan clientName} {
socket -server connect 12345
vwait forever
.CE
-
.SH "SEE ALSO"
gets(n), open(n), read(n), socket(n), Tcl_StandardChannels(3)
-
.SH KEYWORDS
blocking, nonblocking
diff --git a/doc/format.n b/doc/format.n
index efb3a4d..24f35df 100644
--- a/doc/format.n
+++ b/doc/format.n
@@ -5,7 +5,7 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
-'\" RCS: @(#) $Id: format.n,v 1.22 2008/12/10 18:21:46 ferrieux Exp $
+'\" RCS: @(#) $Id: format.n,v 1.23 2009/02/24 21:04:58 dkf Exp $
'\"
.so man.macros
.TH format n 8.1 Tcl "Tcl Built-In Commands"
@@ -48,6 +48,7 @@ and a conversion character.
Any of these fields may be omitted except for the conversion character.
The fields that are present must appear in the order given above.
The paragraphs below discuss each of these fields in turn.
+.SS "OPTIONAL POSITIONAL SPECIFIER"
.PP
If the \fB%\fR is followed by a decimal number and a \fB$\fR, as in
.QW \fB%2$d\fR ,
@@ -61,6 +62,7 @@ given by the number.
This follows the XPG3 conventions for positional specifiers.
If there are any positional specifiers in \fIformatString\fR
then all of the specifiers must be positional.
+.SS "OPTIONAL FLAGS"
.PP
The second portion of a conversion specifier may contain any of the
following flag characters, in any order:
@@ -94,6 +96,7 @@ For all floating-point conversions (\fBe\fR, \fBE\fR, \fBf\fR,
has a decimal point.
For \fBg\fR and \fBG\fR conversions it specifies that
trailing zeroes should not be removed.
+.SS "OPTIONAL FIELD WIDTH"
.PP
The third portion of a conversion specifier is a decimal number giving a
minimum field width for this conversion.
@@ -108,6 +111,7 @@ spaces on the right, respectively.
If the minimum field width is specified as \fB*\fR rather than
a number, then the next argument to the \fBformat\fR command
determines the minimum field width; it must be an integer value.
+.SS "OPTIONAL PRECISION/BOUND"
.PP
The fourth portion of a conversion specifier is a precision,
which consists of a period followed by a number.
@@ -125,6 +129,7 @@ printed; if the string is longer than this then the trailing characters will be
If the precision is specified with \fB*\fR rather than a number
then the next argument to the \fBformat\fR command determines the precision;
it must be a numeric string.
+.SS "OPTIONAL SIZE MODIFIER"
.PP
The fifth part of a conversion specifier is a size modifier,
which must be \fBll\fR, \fBh\fR, or \fBl\fR.
@@ -139,6 +144,7 @@ If neither \fBh\fR nor \fBl\fR are present, the integer value is
truncated to the same range as that produced by the \fBint()\fR
function of the \fBexpr\fR command (at least a 32-bit range, but
determined by the value of \fBtcl_platform(wordSize)\fR).
+.SS "MANDATORY CONVERSION TYPE"
.PP
The last thing in a conversion specifier is an alphabetic character
that determines what kind of conversion to perform.
@@ -201,11 +207,13 @@ The behavior of the format command is the same as the
ANSI C \fBsprintf\fR procedure except for the following
differences:
.IP [1]
-\fB%p\fR and \fB%n\fR specifiers are not supported.
+Tcl guarantees that it will be working with UNICODE characters.
.IP [2]
+\fB%p\fR and \fB%n\fR specifiers are not supported.
+.IP [3]
For \fB%c\fR conversions the argument must be an integer value,
which will then be converted to the corresponding character value.
-.IP [3]
+.IP [4]
The size modifiers are ignored when formatting floating-point values.
The \fBll\fR modifier has no \fBsprintf\fR counterpart.
The \fBb\fR specifier has no \fBsprintf\fR counterpart.
diff --git a/doc/lsort.n b/doc/lsort.n
index f83ace5..568f283 100644
--- a/doc/lsort.n
+++ b/doc/lsort.n
@@ -7,7 +7,7 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
-'\" RCS: @(#) $Id: lsort.n,v 1.32 2008/10/17 10:22:25 dkf Exp $
+'\" RCS: @(#) $Id: lsort.n,v 1.33 2009/02/24 21:04:58 dkf Exp $
'\"
.so man.macros
.TH lsort n 8.5 Tcl "Tcl Built-In Commands"
@@ -29,12 +29,12 @@ By default ASCII sorting is used with the result returned in
increasing order. However, any of the following options may be
specified before \fIlist\fR to control the sorting process (unique
abbreviations are accepted):
-.TP 20
+.TP
\fB\-ascii\fR
.
Use string comparison with Unicode code-point collation order (the
name is for backward-compatibility reasons.) This is the default.
-.TP 20
+.TP
\fB\-dictionary\fR
.
Use dictionary-style comparison. This is the same as \fB\-ascii\fR
@@ -43,15 +43,15 @@ strings contain embedded numbers, the numbers compare as integers,
not characters. For example, in \fB\-dictionary\fR mode, \fBbigBoy\fR
sorts between \fBbigbang\fR and \fBbigboy\fR, and \fBx10y\fR
sorts between \fBx9y\fR and \fBx11y\fR.
-.TP 20
+.TP
\fB\-integer\fR
.
Convert list elements to integers and use integer comparison.
-.TP 20
+.TP
\fB\-real\fR
.
Convert list elements to floating-point values and use floating comparison.
-.TP 20
+.TP
\fB\-command\0\fIcommand\fR
.
Use \fIcommand\fR as a comparison command.
@@ -61,23 +61,23 @@ arguments. The script should return an integer less than,
equal to, or greater than zero if the first element is to
be considered less than, equal to, or greater than the second,
respectively.
-.TP 20
+.TP
\fB\-increasing\fR
.
Sort the list in increasing order
.PQ smallest "items first" .
This is the default.
-.TP 20
+.TP
\fB\-decreasing\fR
.
Sort the list in decreasing order
.PQ largest "items first" .
-.TP 20
+.TP
\fB\-indices\fR
.
Return a list of indices into \fIlist\fR in sorted order instead of
the values themselves.
-.TP 20
+.TP
\fB\-index\0\fIindexList\fR
.
If this option is specified, each of the elements of \fIlist\fR must
@@ -120,7 +120,7 @@ returns \fB{{d e m o} 34512} {{b i g} 12345} {{c o d e} 54321}\fR
This option is much more efficient than using \fB\-command\fR
to achieve the same effect.
.RE
-.TP 20
+.TP
\fB\-stride\0\fIstrideLength\fR
.
If this option is specified, the list is treated as consisting of
@@ -151,13 +151,13 @@ lsort \-stride 2 \-index 1 \-integer {carrot 10 apple 50 banana 25}
returns
.QW "carrot 10 banana 25 apple 50" .
.RE
-.TP 20
+.TP
\fB\-nocase\fR
.
Causes comparisons to be handled in a case-insensitive manner. Has no
effect if combined with the \fB\-dictionary\fR, \fB\-integer\fR, or
\fB\-real\fR options.
-.TP 20
+.TP
\fB\-unique\fR
.
If this option is specified, then only the last set of duplicate
diff --git a/doc/pkgMkIndex.n b/doc/pkgMkIndex.n
index 809c63c..90d87b1 100644
--- a/doc/pkgMkIndex.n
+++ b/doc/pkgMkIndex.n
@@ -4,7 +4,7 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
-'\" RCS: @(#) $Id: pkgMkIndex.n,v 1.23 2007/12/13 15:22:33 dgp Exp $
+'\" RCS: @(#) $Id: pkgMkIndex.n,v 1.24 2009/02/24 21:04:58 dkf Exp $
'\"
.so man.macros
.TH pkg_mkIndex n 8.3 Tcl "Tcl Built-In Commands"
@@ -14,7 +14,7 @@
pkg_mkIndex \- Build an index for automatic loading of packages
.SH SYNOPSIS
.nf
-\fBpkg_mkIndex ?\fI\-direct\fR? ?\fI\-lazy\fR? ?\fI\-load pkgPat\fR? ?\fI\-verbose\fR? \fIdir\fR ?\fIpattern pattern ...\fR?
+\fBpkg_mkIndex ?\fIoptions...\fR? \fIdir\fR ?\fIpattern pattern ...\fR?
.fi
.BE
.SH DESCRIPTION
@@ -114,7 +114,7 @@ The index process will pre-load any packages that exist in the
current interpreter and match \fIpkgPat\fR into the slave interpreter used to
generate the index. The pattern match uses string match rules, but without
making case distinctions.
-See COMPLEX CASES below.
+See \fBCOMPLEX CASES\fR below.
.TP 15
\fB\-verbose\fR
Generate output during the indexing process. Output is via
diff --git a/doc/regsub.n b/doc/regsub.n
index 33a2e6f..471063e 100644
--- a/doc/regsub.n
+++ b/doc/regsub.n
@@ -6,7 +6,7 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
-'\" RCS: @(#) $Id: regsub.n,v 1.26 2008/10/17 10:22:25 dkf Exp $
+'\" RCS: @(#) $Id: regsub.n,v 1.27 2009/02/24 21:04:58 dkf Exp $
'\"
.so man.macros
.TH regsub n 8.3 Tcl "Tcl Built-In Commands"
@@ -56,7 +56,7 @@ backslashes.
If the initial arguments to \fBregsub\fR start with \fB\-\fR then
they are treated as switches. The following switches are
currently supported:
-.TP 10
+.TP
\fB\-all\fR
.
All ranges in \fIstring\fR that match \fIexp\fR are found and
@@ -69,13 +69,13 @@ and
.QW \e\fIn\fR
sequences are handled for each substitution using the information
from the corresponding match.
-.TP 15
+.TP
\fB\-expanded\fR
.
Enables use of the expanded regular expression syntax where
whitespace and comments are ignored. This is the same as specifying
the \fB(?x)\fR embedded option (see the \fBre_syntax\fR manual page).
-.TP 15
+.TP
\fB\-line\fR
.
Enables newline-sensitive matching. By default, newline is a
@@ -92,7 +92,7 @@ matches an empty string before any newline in
addition to its normal function. This flag is equivalent to
specifying both \fB\-linestop\fR and \fB\-lineanchor\fR, or the
\fB(?n)\fR embedded option (see the \fBre_syntax\fR manual page).
-.TP 15
+.TP
\fB\-linestop\fR
.
Changes the behavior of
@@ -102,7 +102,7 @@ bracket expressions and
so that they
stop at newlines. This is the same as specifying the \fB(?p)\fR
embedded option (see the \fBre_syntax\fR manual page).
-.TP 15
+.TP
\fB\-lineanchor\fR
.
Changes the behavior of
@@ -115,13 +115,13 @@ so they match the
beginning and end of a line respectively. This is the same as
specifying the \fB(?w)\fR embedded option (see the \fBre_syntax\fR
manual page).
-.TP 10
+.TP
\fB\-nocase\fR
.
Upper-case characters in \fIstring\fR will be converted to lower-case
before matching against \fIexp\fR; however, substitutions specified
by \fIsubSpec\fR use the original unconverted form of \fIstring\fR.
-.TP 10
+.TP
\fB\-start\fR \fIindex\fR
.
Specifies a character index offset into the string to start
@@ -133,7 +133,7 @@ When using this switch,
will not match the beginning of the line, and \eA will still
match the start of the string at \fIindex\fR.
\fIindex\fR will be constrained to the bounds of the input string.
-.TP 10
+.TP
\fB\-\|\-\fR
.
Marks the end of switches. The argument following this one will
diff --git a/doc/scan.n b/doc/scan.n
index f37ca59..48b5df1 100644
--- a/doc/scan.n
+++ b/doc/scan.n
@@ -6,7 +6,7 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
-'\" RCS: @(#) $Id: scan.n,v 1.27 2008/12/10 18:21:46 ferrieux Exp $
+'\" RCS: @(#) $Id: scan.n,v 1.28 2009/02/24 21:04:58 dkf Exp $
'\"
.so man.macros
.TH scan n 8.4 Tcl "Tcl Built-In Commands"
@@ -57,6 +57,7 @@ conversion character is \fB[\fR or \fBc\fR).
Then it converts the next input characters according to the
conversion specifier and stores the result in the variable given
by the next argument to \fBscan\fR.
+.SS "OPTIONAL POSITIONAL SPECIFIER"
.PP
If the \fB%\fR is followed by a decimal number and a \fB$\fR, as in
.QW \fB%2$d\fR ,
@@ -68,6 +69,7 @@ specifiers must be positional. Every \fIvarName\fR on the argument
list must correspond to exactly one conversion specifier or an error
is generated, or in the inline case, any position can be specified
at most once and the empty positions will be filled in with empty strings.
+.SS "OPTIONAL SIZE MODIFIER"
.PP
The size modifier field is used only when scanning a substring into
one of Tcl's integer values. The size modifier field dictates the
@@ -83,33 +85,34 @@ modifier. Either one indicates the integer range to be stored is
limited to the same range produced by the \fBwide()\fR function of
the \fBexpr\fR command. The \fBll\fR size modifier indicates that
the integer range to be stored is unlimited.
+.SS "MANDATORY CONVERSION CHARACTER"
.PP
The following conversion characters are supported:
-.TP 10
+.TP
\fBd\fR
.
The input substring must be a decimal integer.
It is read in and the integer value is stored in the variable,
truncated as required by the size modifier value.
-.TP 10
+.TP
\fBo\fR
.
The input substring must be an octal integer. It is read in and the
integer value is stored in the variable,
truncated as required by the size modifier value.
-.TP 10
+.TP
\fBx\fR
.
The input substring must be a hexadecimal integer.
It is read in and the integer value is stored in the variable,
truncated as required by the size modifier value.
-.TP 10
+.TP
\fBb\fR
.
The input substring must be a binary integer.
It is read in and the integer value is stored in the variable,
truncated as required by the size modifier value.
-.TP 10
+.TP
\fBu\fR
.
The input substring must be a decimal integer.
@@ -119,26 +122,26 @@ range is computed and stored in the variable as a decimal string.
The conversion makes no sense without reference to a truncation range,
so the size modifier \fBll\fR is not permitted in combination
with conversion character \fBu\fR.
-.TP 10
+.TP
\fBi\fR
.
The input substring must be an integer. The base (i.e. decimal, binary,
octal, or hexadecimal) is determined in the same fashion as described in
\fBexpr\fR. The integer value is stored in the variable,
truncated as required by the size modifier value.
-.TP 10
+.TP
\fBc\fR
.
A single character is read in and its Unicode value is stored in
the variable as an integer value.
Initial white space is not skipped in this case, so the input
substring may be a white-space character.
-.TP 10
+.TP
\fBs\fR
.
The input substring consists of all the characters up to the next
white-space character; the characters are copied to the variable.
-.TP 10
+.TP
\fBe\fR or \fBf\fR or \fBg\fR
.
The input substring must be a floating-point number consisting
@@ -147,7 +150,7 @@ containing a decimal point, and an optional exponent consisting
of an \fBe\fR or \fBE\fR followed by an optional sign and a string of
decimal digits.
It is read in and stored in the variable as a floating-point value.
-.TP 10
+.TP
\fB[\fIchars\fB]\fR
.
The input substring consists of one or more characters in \fIchars\fR.
@@ -160,7 +163,7 @@ contains a sequence of the form \fIa\fB\-\fIb\fR then any
character between \fIa\fR and \fIb\fR (inclusive) will match.
If the first or last character between the brackets is a \fB\-\fR, then
it is treated as part of \fIchars\fR rather than indicating a range.
-.TP 10
+.TP
\fB[^\fIchars\fB]\fR
.
The input substring consists of one or more characters not in \fIchars\fR.
@@ -174,7 +177,7 @@ character between \fIa\fR and \fIb\fR (inclusive) will be excluded
from the set.
If the first or last character between the brackets is a \fB\-\fR, then
it is treated as part of \fIchars\fR rather than indicating a range value.
-.TP 10
+.TP
\fBn\fR
.
No input is consumed from the input string. Instead, the total number
diff --git a/doc/tclvars.n b/doc/tclvars.n
index 3e3f7ac..60a16d7 100644
--- a/doc/tclvars.n
+++ b/doc/tclvars.n
@@ -5,7 +5,7 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
-'\" RCS: @(#) $Id: tclvars.n,v 1.39 2008/10/02 19:01:30 mistachkin Exp $
+'\" RCS: @(#) $Id: tclvars.n,v 1.40 2009/02/24 21:04:58 dkf Exp $
'\"
.so man.macros
.TH tclvars n 8.0 Tcl "Tcl Built-In Commands"
@@ -184,6 +184,11 @@ The \fImsg\fR element will be a human-readable
message corresponding to \fIerrName\fR, such as
.QW "no such file or directory"
for the \fBENOENT\fR case.
+.TP
+\fBTCL\fR ...
+.
+Indicates some sort of problem generated in relation to Tcl itself, e.g. a
+failure to look up a channel or variable.
.PP
To set the \fB\-errorcode\fR return option, applications should use library
procedures such as \fBTcl_SetObjErrorCode\fR, \fBTcl_SetReturnOptions\fR,
@@ -194,11 +199,6 @@ the Tcl interpreter will reset the variable to \fBNONE\fR after
the next error.
.RE
.TP
-\fBTCL\fR ...
-.
-Indicates some sort of problem generated in relation to Tcl itself, e.g. a
-failure to look up a channel or variable.
-.TP
\fBerrorInfo\fR
.
This variable holds the value of the \fB\-errorinfo\fR return option