aboutsummaryrefslogtreecommitdiff
path: root/Tcl_shipped.html
diff options
context:
space:
mode:
authorSteve Bennett <steveb@workware.net.au>2010-11-15 11:24:31 +1000
committerSteve Bennett <steveb@workware.net.au>2010-11-24 09:40:45 +1000
commit96466972c70a61becc8c332d0b991038ab7028f1 (patch)
tree9dcead1ec018bb47361ac9a1781af499ab9c804f /Tcl_shipped.html
parent373b721510fd2d0754a41cc70a3b7cfd02e929bd (diff)
downloadjimtcl-96466972c70a61becc8c332d0b991038ab7028f1.zip
jimtcl-96466972c70a61becc8c332d0b991038ab7028f1.tar.gz
jimtcl-96466972c70a61becc8c332d0b991038ab7028f1.tar.bz2
Remove the bio extension and add 'copyto' to aio.
The bio extension is a hangover from TinyTcl. Since Jim supports binary strings, there isn't much need for it except for 'bio copy'. So move this to aio as 'copyto' and implement 'file copy' in terms of it. Signed-off-by: Steve Bennett <steveb@workware.net.au>
Diffstat (limited to 'Tcl_shipped.html')
-rw-r--r--Tcl_shipped.html828
1 files changed, 613 insertions, 215 deletions
diff --git a/Tcl_shipped.html b/Tcl_shipped.html
index ba1d32c..b0a1f85 100644
--- a/Tcl_shipped.html
+++ b/Tcl_shipped.html
@@ -2,8 +2,8 @@
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
-<meta name="generator" content="AsciiDoc 8.4.5" />
+<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" />
+<meta name="generator" content="AsciiDoc 8.6.1" />
<title>Jim Tcl(n)</title>
<style type="text/css">
/* Debug borders */
@@ -118,12 +118,14 @@ div#preamble {
div.tableblock, div.imageblock, div.exampleblock, div.verseblock,
div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock,
div.admonitionblock {
- margin-top: 1.5em;
+ margin-top: 1.0em;
margin-bottom: 1.5em;
}
div.admonitionblock {
- margin-top: 2.5em;
- margin-bottom: 2.5em;
+ margin-top: 2.0em;
+ margin-bottom: 2.0em;
+ margin-right: 10%;
+ color: #606060;
}
div.content { /* Block element content. */
@@ -165,21 +167,21 @@ div.listingblock > div.content {
padding: 0.5em;
}
-div.quoteblock {
- padding-left: 2.0em;
+div.quoteblock, div.verseblock {
+ padding-left: 1.0em;
+ margin-left: 1.0em;
margin-right: 10%;
+ border-left: 5px solid #dddddd;
+ color: #777777;
}
+
div.quoteblock > div.attribution {
padding-top: 0.5em;
text-align: right;
}
-div.verseblock {
- padding-left: 2.0em;
- margin-right: 10%;
-}
-div.verseblock > div.content {
- white-space: pre;
+div.verseblock > pre.content {
+ font-family: inherit;
}
div.verseblock > div.attribution {
padding-top: 0.75em;
@@ -200,12 +202,12 @@ div.admonitionblock .icon {
}
div.admonitionblock td.content {
padding-left: 0.5em;
- border-left: 2px solid silver;
+ border-left: 3px solid #dddddd;
}
div.exampleblock > div.content {
- border-left: 2px solid silver;
- padding: 0.5em;
+ border-left: 3px solid #dddddd;
+ padding-left: 0.5em;
}
div.imageblock div.content { padding-left: 0; }
@@ -255,9 +257,10 @@ div.compact div, div.compact div {
div.tableblock > table {
border: 3px solid #527bbd;
}
-thead {
+thead, p.table.header {
font-family: sans-serif;
font-weight: bold;
+ color: #527bbd;
}
tfoot {
font-weight: bold;
@@ -310,10 +313,50 @@ div.hdlist.compact tr {
background: yellow;
}
+.footnote, .footnoteref {
+ font-size: 0.8em;
+}
+
+span.footnote, span.footnoteref {
+ vertical-align: super;
+}
+
+#footnotes {
+ margin: 20px 0 20px 0;
+ padding: 7px 0 0 0;
+}
+
+#footnotes div.footnote {
+ margin: 0 0 5px 0;
+}
+
+#footnotes hr {
+ border: none;
+ border-top: 1px solid silver;
+ height: 1px;
+ text-align: left;
+ margin-left: 0;
+ width: 20%;
+ min-width: 100px;
+}
+
+div.colist td {
+ padding-right: 0.5em;
+ padding-bottom: 0.3em;
+ vertical-align: top;
+}
+div.colist td img {
+ margin-top: 0.3em;
+}
+
@media print {
div#footer-badges { display: none; }
}
+div#toc {
+ margin-bottom: 2.5em;
+}
+
div#toctitle {
color: #527bbd;
font-family: sans-serif;
@@ -339,6 +382,7 @@ div.toclevel4 {
margin-left: 6em;
font-size: 0.9em;
}
+
/* Overrides for manpage documents */
h1 {
padding-top: 0.5em;
@@ -357,50 +401,142 @@ div.sectionbody {
div#toc { display: none; }
}
-/* Workarounds for IE6's broken and incomplete CSS2. */
+</style>
+<script type="text/javascript">
+/*<![CDATA[*/
+window.onload = function(){asciidoc.footnotes();}
+var asciidoc = { // Namespace.
-div.sidebar-content {
- background: #ffffee;
- border: 1px solid silver;
- padding: 0.5em;
-}
-div.sidebar-title, div.image-title {
- color: #527bbd;
- font-family: sans-serif;
- font-weight: bold;
- margin-top: 0.0em;
- margin-bottom: 0.5em;
-}
+/////////////////////////////////////////////////////////////////////
+// Table Of Contents generator
+/////////////////////////////////////////////////////////////////////
-div.listingblock div.content {
- border: 1px solid silver;
- background: #f4f4f4;
- padding: 0.5em;
-}
+/* Author: Mihai Bazon, September 2002
+ * http://students.infoiasi.ro/~mishoo
+ *
+ * Table Of Content generator
+ * Version: 0.4
+ *
+ * Feel free to use this script under the terms of the GNU General Public
+ * License, as long as you do not remove or alter this notice.
+ */
-div.quoteblock-attribution {
- padding-top: 0.5em;
- text-align: right;
-}
+ /* modified by Troy D. Hanson, September 2006. License: GPL */
+ /* modified by Stuart Rackham, 2006, 2009. License: GPL */
-div.verseblock-content {
- white-space: pre;
-}
-div.verseblock-attribution {
- padding-top: 0.75em;
- text-align: left;
-}
+// toclevels = 1..4.
+toc: function (toclevels) {
-div.exampleblock-content {
- border-left: 2px solid silver;
- padding-left: 0.5em;
+ function getText(el) {
+ var text = "";
+ for (var i = el.firstChild; i != null; i = i.nextSibling) {
+ if (i.nodeType == 3 /* Node.TEXT_NODE */) // IE doesn't speak constants.
+ text += i.data;
+ else if (i.firstChild != null)
+ text += getText(i);
+ }
+ return text;
+ }
+
+ function TocEntry(el, text, toclevel) {
+ this.element = el;
+ this.text = text;
+ this.toclevel = toclevel;
+ }
+
+ function tocEntries(el, toclevels) {
+ var result = new Array;
+ var re = new RegExp('[hH]([2-'+(toclevels+1)+'])');
+ // Function that scans the DOM tree for header elements (the DOM2
+ // nodeIterator API would be a better technique but not supported by all
+ // browsers).
+ var iterate = function (el) {
+ for (var i = el.firstChild; i != null; i = i.nextSibling) {
+ if (i.nodeType == 1 /* Node.ELEMENT_NODE */) {
+ var mo = re.exec(i.tagName);
+ if (mo && (i.getAttribute("class") || i.getAttribute("className")) != "float") {
+ result[result.length] = new TocEntry(i, getText(i), mo[1]-1);
+ }
+ iterate(i);
+ }
+ }
+ }
+ iterate(el);
+ return result;
+ }
+
+ var toc = document.getElementById("toc");
+ var entries = tocEntries(document.getElementById("content"), toclevels);
+ for (var i = 0; i < entries.length; ++i) {
+ var entry = entries[i];
+ if (entry.element.id == "")
+ entry.element.id = "_toc_" + i;
+ var a = document.createElement("a");
+ a.href = "#" + entry.element.id;
+ a.appendChild(document.createTextNode(entry.text));
+ var div = document.createElement("div");
+ div.appendChild(a);
+ div.className = "toclevel" + entry.toclevel;
+ toc.appendChild(div);
+ }
+ if (entries.length == 0)
+ toc.parentNode.removeChild(toc);
+},
+
+
+/////////////////////////////////////////////////////////////////////
+// Footnotes generator
+/////////////////////////////////////////////////////////////////////
+
+/* Based on footnote generation code from:
+ * http://www.brandspankingnew.net/archive/2005/07/format_footnote.html
+ */
+
+footnotes: function () {
+ var cont = document.getElementById("content");
+ var noteholder = document.getElementById("footnotes");
+ var spans = cont.getElementsByTagName("span");
+ var refs = {};
+ var n = 0;
+ for (i=0; i<spans.length; i++) {
+ if (spans[i].className == "footnote") {
+ n++;
+ // Use [\s\S] in place of . so multi-line matches work.
+ // Because JavaScript has no s (dotall) regex flag.
+ note = spans[i].innerHTML.match(/\s*\[([\s\S]*)]\s*/)[1];
+ noteholder.innerHTML +=
+ "<div class='footnote' id='_footnote_" + n + "'>" +
+ "<a href='#_footnoteref_" + n + "' title='Return to text'>" +
+ n + "</a>. " + note + "</div>";
+ spans[i].innerHTML =
+ "[<a id='_footnoteref_" + n + "' href='#_footnote_" + n +
+ "' title='View footnote' class='footnote'>" + n + "</a>]";
+ var id =spans[i].getAttribute("id");
+ if (id != null) refs["#"+id] = n;
+ }
+ }
+ if (n == 0)
+ noteholder.parentNode.removeChild(noteholder);
+ else {
+ // Process footnoterefs.
+ for (i=0; i<spans.length; i++) {
+ if (spans[i].className == "footnoteref") {
+ var href = spans[i].getElementsByTagName("a")[0].getAttribute("href");
+ href = href.match(/#.*/)[0]; // Because IE return full URL.
+ n = refs[href];
+ spans[i].innerHTML =
+ "[<a href='#_footnote_" + n +
+ "' title='View footnote' class='footnote'>" + n + "</a>]";
+ }
+ }
+ }
}
-/* IE6 sets dynamically generated links as visited. */
-div#toc a:visited { color: blue; }
-</style>
+}
+/*]]>*/
+</script>
</head>
-<body>
+<body class="manpage">
<div id="header">
<h1>
Jim Tcl(n) Manual Page
@@ -412,6 +548,8 @@ Jim Tcl(n) Manual Page
</p>
</div>
</div>
+<div id="content">
+<div class="sect1">
<h2 id="_synopsis">SYNOPSIS</h2>
<div class="sectionbody">
<div class="literalblock">
@@ -446,6 +584,8 @@ Jim Tcl(n) Manual Page
</li>
</ul></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_introduction">INTRODUCTION</h2>
<div class="sectionbody">
<div class="paragraph"><p>Jim is a reimplementation of Tcl, combining some features from
@@ -560,6 +700,8 @@ The history command is not supported
</li>
</ol></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_changes">CHANGES</h2>
<div class="sectionbody">
<div class="paragraph"><p>Since v0.63:</p></div>
@@ -579,6 +721,11 @@ Add aio <em>$handle filename</em>
Add <em>info channels</em>
</p>
</li>
+<li>
+<p>
+The <em>bio</em> extension is gone. Now <em>aio</em> supports <em>copyto</em>.
+</p>
+</li>
</ol></div>
<div class="paragraph"><p>Since v0.62:</p></div>
<div class="olist arabic"><ol class="arabic">
@@ -792,6 +939,8 @@ Add <em>try &#8230; finally</em> command
</li>
</ol></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_tcl_introduction">TCL INTRODUCTION</h2>
<div class="sectionbody">
<div class="paragraph"><p>Tcl stands for <em>tool command language</em> and is pronounced <em>tickle.</em>
@@ -835,6 +984,8 @@ the language syntax and the built-in commands that will be available
in any application based on Tcl. The individual library procedures are
described in more detail in separate manual pages, one per procedure.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_interpreters">INTERPRETERS</h2>
<div class="sectionbody">
<div class="paragraph"><p>The central data structure in Tcl is an interpreter (C type <em>Jim_Interp</em>).
@@ -847,6 +998,8 @@ the application. Interpreters are relatively lightweight structures.
They can be created and deleted quickly, so application programmers should
feel free to use multiple interpreters if that simplifies the application.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_data_types">DATA TYPES</h2>
<div class="sectionbody">
<div class="paragraph"><p>Tcl supports only one type of data: strings. All commands, all arguments
@@ -867,6 +1020,8 @@ the interpretation, there are three common forms that strings take:
commands, expressions, and lists. The major sections below discuss
these three forms in more detail.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_basic_command_syntax">BASIC COMMAND SYNTAX</h2>
<div class="sectionbody">
<div class="paragraph"><p>The Tcl language has syntactic similarities to both the Unix shells
@@ -909,6 +1064,8 @@ other forms that will be re-used over time: changes to the command set
may cause abbreviations to become ambiguous, resulting in scripts that
no longer work.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_comments">COMMENTS</h2>
<div class="sectionbody">
<div class="paragraph"><p>If the first non-blank character in a command is <em>#</em>, then everything
@@ -919,6 +1076,8 @@ braces (this is necessary because when Tcl parses the top-level command
it doesn&#8217;t yet know that the nested field will be used as a command so
it cannot process the nested comment character as a comment).</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_grouping_arguments_with_double_quotes">GROUPING ARGUMENTS WITH DOUBLE-QUOTES</h2>
<div class="sectionbody">
<div class="paragraph"><p>Normally each argument field ends at the next white space, but
@@ -938,6 +1097,8 @@ and backslash substitutions still occur, as described below. If the
first character of a command field is not a quote, then quotes receive
no special interpretation in the parsing of that field.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_grouping_arguments_with_braces">GROUPING ARGUMENTS WITH BRACES</h2>
<div class="sectionbody">
<div class="paragraph"><p>Curly braces may also be used for grouping arguments. They are similar
@@ -975,6 +1136,8 @@ brace, then neither left nor right
braces in the field will be treated specially (except as part of
variable substitution; see below).</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_command_substitution_with_brackets">COMMAND SUBSTITUTION WITH BRACKETS</h2>
<div class="sectionbody">
<div class="paragraph"><p>If an open bracket occurs in a field of a command, then command
@@ -1023,6 +1186,8 @@ expr $b+2]x</tt></pre>
between them are not interpreted specially; they are passed through to
the argument verbatim.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_variable_substitution_with">VARIABLE SUBSTITUTION WITH $</h2>
<div class="sectionbody">
<div class="paragraph"><p>The dollar sign (<em>$</em>) may be used as a special shorthand form for
@@ -1093,6 +1258,8 @@ argument verbatim.</p></div>
completely equivalent to <em>[set a]</em>; it is provided as a convenience
to reduce typing.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_separating_commands_with_semi_colons">SEPARATING COMMANDS WITH SEMI-COLONS</h2>
<div class="sectionbody">
<div class="paragraph"><p>Normally, each command occupies one line (the command is terminated by a
@@ -1101,6 +1268,8 @@ separator character; multiple commands may be placed on one line by
separating them with a semi-colon. Semi-colons are not treated as
command separators if they appear within curly braces or double-quotes.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_backslash_substitution">BACKSLASH SUBSTITUTION</h2>
<div class="sectionbody">
<div class="paragraph"><p>Backslashes may be used to insert non-printing characters into command
@@ -1296,6 +1465,8 @@ most common cases. To produce particularly complicated arguments
it is probably easiest to use the <em>format</em> command along with
command substitution.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_string_and_list_index_specifications">STRING AND LIST INDEX SPECIFICATIONS</h2>
<div class="sectionbody">
<div class="paragraph"><p>Many string and list commands take one or more <em>index</em> parameters which
@@ -1342,6 +1513,8 @@ specify a position in the string relative to the start or end of the string/list
</dd>
</dl></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_command_summary">COMMAND SUMMARY</h2>
<div class="sectionbody">
<div class="olist arabic"><ol class="arabic">
@@ -1406,6 +1579,8 @@ If the first non-blank character of a command is a <em>#</em>, everything
</li>
</ol></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_expressions">EXPRESSIONS</h2>
<div class="sectionbody">
<div class="paragraph"><p>The second major interpretation applied to strings in Tcl is
@@ -1772,6 +1947,8 @@ terminate. Instead, the expression should be placed in braces:</p></div>
to be delayed; it will be re-done each time the expression is
evaluated, which is the desired result.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_lists">LISTS</h2>
<div class="sectionbody">
<div class="paragraph"><p>The third major way that strings are interpreted in Tcl is as lists.
@@ -1812,6 +1989,8 @@ you to build lists, extract elements from them, search them, and perform
other list-related functions.</p></div>
<div class="paragraph"><p>Advanced list commands include <em>lrepeat</em>, <em>lreverse</em>, <em>lmap</em>, <em>lassign</em>, <em>lset</em>.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_list_expansion">LIST EXPANSION</h2>
<div class="sectionbody">
<div class="paragraph"><p>A new addition to Tcl 8.5 is the ability to expand a list into separate
@@ -1834,6 +2013,8 @@ the resulting command.</p></div>
<div class="paragraph"><p>Note that the official Tcl syntax is <em>{*}</em>, however <em>{expand}</em> is retained
for backward compatibility with experimental versions of this feature.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_regular_expressions">REGULAR EXPRESSIONS</h2>
<div class="sectionbody">
<div class="paragraph"><p>Tcl provides two commands that support string matching using regular
@@ -1843,7 +2024,8 @@ expressions, <em>regexp</em> and <em>regsub</em>, as well as <em>switch -regexp<
POSIX regular expression support, or using the built-in regular expression engine.
The differences between these are described below.</p></div>
<div class="paragraph"><p><strong>NOTE</strong> Tcl 7.x and 8.x use perl-style Advanced Regular Expressions (<tt>ARE</tt>).</p></div>
-<h3 id="_posix_regular_expressions">POSIX Regular Expressions</h3><div style="clear:left"></div>
+<div class="sect2">
+<h3 id="_posix_regular_expressions">POSIX Regular Expressions</h3>
<div class="paragraph"><p>If the system supports POSIX regular expressions, and UTF-8 support is not enabled,
this support will be used by default. The type of regular expressions supported are
Extended Regular Expressions (<tt>ERE</tt>) rather than Basic Regular Expressions (<tt>BRE</tt>).
@@ -1852,7 +2034,9 @@ See REG_EXTENDED in the documentation.</p></div>
make for the smallest code size, but some features such as UTF-8
and <tt>\w</tt>, <tt>\d</tt>, <tt>\s</tt> are not supported.</p></div>
<div class="paragraph"><p>See regex(3) and regex(7) for full details.</p></div>
-<h3 id="_jim_built_in_regular_expressions">Jim built-in Regular Expressions</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_jim_built_in_regular_expressions">Jim built-in Regular Expressions</h3>
<div class="paragraph"><p>The Jim built-in regulare expression engine may be selected with <tt>./configure --with-jim-regexp</tt>
or it will be selected automatically if UTF-8 support is enabled.</p></div>
<div class="paragraph"><p>This engine supports UTF-8 as well as some <tt>ARE</tt> features. The differences with both Tcl 7.x/8.x
@@ -1895,6 +2079,9 @@ No support for the <tt>?</tt> non-greedy quantifier. e.g. <tt>*?</tt>
</li>
</ol></div>
</div>
+</div>
+</div>
+<div class="sect1">
<h2 id="_command_results">COMMAND RESULTS</h2>
<div class="sectionbody">
<div class="paragraph"><p>Each command produces two results: a code and a string. The
@@ -1990,6 +2177,8 @@ aborting command interpretation any further.</p></div>
<div class="paragraph"><p>The <em>info returncodes</em> command may be used to programmatically map between
return codes and names.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_procedures">PROCEDURES</h2>
<div class="sectionbody">
<div class="paragraph"><p>Tcl allows you to extend the command interface by defining
@@ -2128,6 +2317,8 @@ invocations of the procedure.</p></div>
<div class="paragraph"><p>See the <em>proc</em> command for information on
how to define procedures and what happens when they are invoked.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_variables_scalars_and_arrays">VARIABLES - SCALARS AND ARRAYS</h2>
<div class="sectionbody">
<div class="paragraph"><p>Tcl allows the definition of variables and the use of their values
@@ -2198,6 +2389,8 @@ p</tt></pre>
<pre><tt>1 2 3</tt></pre>
</div></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_arrays_as_lists_in_jim">ARRAYS AS LISTS IN JIM</h2>
<div class="sectionbody">
<div class="paragraph"><p>Unlike Tcl, Jim can automatically convert between a list (with an even
@@ -2229,6 +2422,8 @@ puts $a</tt></pre>
<pre><tt>1 one 2 two</tt></pre>
</div></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_dictionary_values">DICTIONARY VALUES</h2>
<div class="sectionbody">
<div class="paragraph"><p>Tcl 8.5 introduced the dict command, and Jim Tcl has added a version
@@ -2277,12 +2472,15 @@ jim&gt; dict set a 3 T three
</div></div>
<div class="paragraph"><p>See the <em>dict</em> command for more details.</p></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_garbage_collection_references_lambda">GARBAGE COLLECTION, REFERENCES, LAMBDA</h2>
<div class="sectionbody">
<div class="paragraph"><p>Unlike Tcl, Jim has some sophistocated support for functional programming.
These are described briefly below.</p></div>
<div class="paragraph"><p>More information may be found at <a href="http://wiki.tcl.tk/13847">http://wiki.tcl.tk/13847</a></p></div>
-<h3 id="_references">References</h3><div style="clear:left"></div>
+<div class="sect2">
+<h3 id="_references">References</h3>
<div class="paragraph"><p>A reference can be thought of as holding a value with one level of indirection,
where the value may be garbage collected when unreferenced.
Consider the following example:</p></div>
@@ -2307,7 +2505,9 @@ New String</tt></pre>
<div class="paragraph"><p>The operation <em>setref</em> replaces the value stored by the reference. If the old value
is no longer accessible by any reference, it will eventually be automatically be garbage
collected.</p></div>
-<h3 id="_garbage_collection">Garbage Collection</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_garbage_collection">Garbage Collection</h3>
<div class="paragraph"><p>Normally, all values in Tcl are passed by value. As such values are copied and released
automatically as necessary.</p></div>
<div class="paragraph"><p>With the introduction of references, it is possible to create values whose lifetime
@@ -2338,7 +2538,9 @@ f
jim&gt; finalize $r newf
newf</tt></pre>
</div></div>
-<h3 id="_lambda">Lambda</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lambda">Lambda</h3>
<div class="paragraph"><p>Jim provides a garbage collected lambda function. This is a procedure
which is able to create an anonymous procedure. Consider:</p></div>
<div class="literalblock">
@@ -2360,6 +2562,9 @@ when the garbage collector runs.</p></div>
<pre><tt>jim&gt; rename $f ""</tt></pre>
</div></div>
</div>
+</div>
+</div>
+<div class="sect1">
<h2 id="_utf_8_and_unicode">UTF-8 AND UNICODE</h2>
<div class="sectionbody">
<div class="paragraph"><p>If Jim is built with UTF-8 support enabled (configure --enable-utf),
@@ -2374,14 +2579,17 @@ while <em>string length</em> returns the number of characters.</p></div>
and <em>string bytelength</em> returns the same value as <em>string length</em>.</p></div>
<div class="paragraph"><p>Note that even if UTF-8 support is not enabled, the <tt>\uNNNN</tt> syntax
is still available to embed UTF-8 sequences.</p></div>
-<h3 id="_string_matching">String Matching</h3><div style="clear:left"></div>
+<div class="sect2">
+<h3 id="_string_matching">String Matching</h3>
<div class="paragraph"><p>Commands such as <em>string match</em>, <em>lsearch -glob</em>, <em>array names</em> and others use string
pattern matching rules. These commands support UTF-8. For example:</p></div>
<div class="literalblock">
<div class="content">
<pre><tt>string match a\[\ua0-\ubf\]b "a\u00a3b"</tt></pre>
</div></div>
-<h3 id="_format_and_scan">format and scan</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_format_and_scan">format and scan</h3>
<div class="paragraph"><p><tt>format %c</tt> allows a unicode codepoint to be be encoded. For example, the following will return
a string with two bytes and one character. The same as <tt>\ub5</tt></p></div>
<div class="literalblock">
@@ -2401,7 +2609,9 @@ return a string with three characters, not three bytes.</p></div>
<pre><tt>scan \u00b5A %c%c a b</tt></pre>
</div></div>
<div class="paragraph"><p><em>scan %s</em> will also accept a character class, including unicode ranges.</p></div>
-<h3 id="_string_classes">String Classes</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_string_classes">String Classes</h3>
<div class="paragraph"><p><em>string is</em> has <strong>not</strong> been extended to classify UTF-8 characters. Therefore, the following
will return 0, even though the string may be considered to be alphabetic.</p></div>
<div class="literalblock">
@@ -2409,7 +2619,9 @@ will return 0, even though the string may be considered to be alphabetic.</p></d
<pre><tt>string is alpha \ub5Test</tt></pre>
</div></div>
<div class="paragraph"><p>This does not affect the string classes <em>ascii</em>, <em>control</em>, <em>digit</em>, <em>double</em>, <em>integer</em> or <em>xdigit</em>.</p></div>
-<h3 id="_case_mapping_and_conversion">Case Mapping and Conversion</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_case_mapping_and_conversion">Case Mapping and Conversion</h3>
<div class="paragraph"><p>Jim provides a simplified unicode case mapping. This means that case conversion
and comparison will not increase or decrease the number of characters in a string.</p></div>
<div class="paragraph"><p><em>string toupper</em> will convert any lowercase letters to their uppercase equivalent.
@@ -2417,7 +2629,9 @@ Any character which is not a letter or has no uppercase equivalent is left uncha
Similarly for <em>string tolower</em>.</p></div>
<div class="paragraph"><p>Commands which perform case insensitive matches, such as <em>string compare -nocase</em>
and <em>lsearch -nocase</em> fold both strings to uppercase before comparison.</p></div>
-<h3 id="_invalid_utf_8_sequences">Invalid UTF-8 Sequences</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_invalid_utf_8_sequences">Invalid UTF-8 Sequences</h3>
<div class="paragraph"><p>Some UTF-8 character sequences are invalid, such as those beginning with <em>0xff</em>,
those which represent character sequences longer than 3 bytes (greater than U+FFFF),
and those which end prematurely, such as a lone <em>0xc2</em>.</p></div>
@@ -2427,11 +2641,16 @@ the following returns 2.</p></div>
<div class="content">
<pre><tt>string bytelength \xff\xff</tt></pre>
</div></div>
-<h3 id="_regular_expressions_2">Regular Expressions</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_regular_expressions_2">Regular Expressions</h3>
<div class="paragraph"><p>If UTF-8 support is enabled, the built-in regular expression engine will be
selected which supports UTF-8 strings and patterns.</p></div>
<div class="paragraph"><p>See REGULAR EXPRESSIONS</p></div>
</div>
+</div>
+</div>
+<div class="sect1">
<h2 id="_built_in_commands">BUILT-IN COMMANDS</h2>
<div class="sectionbody">
<div class="paragraph"><p>The Tcl library provides the following built-in commands, which will
@@ -2447,7 +2666,8 @@ in <tt>?question-marks?</tt>.</p></div>
<div class="paragraph"><p>Ellipses (<tt>&#8230;</tt>) indicate that any number of additional
arguments or groups of arguments may appear, in the same format
as the preceding argument(s).</p></div>
-<h3 id="CommandIndex">Command Index</h3><div style="clear:left"></div>
+<div class="sect2">
+<h3 id="CommandIndex">Command Index</h3>
<div class="tableblock">
<table rules="none"
width="100%"
@@ -2469,11 +2689,10 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#_alias">alias</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_append">append</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_array">array</a></p></td>
-<td align="left" valign="top"><p class="table"><a href="#_bio">bio</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_break">break</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#_case">case</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#_case">case</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_catch">catch</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_cd">cd</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_clock">clock</a></p></td>
@@ -2481,9 +2700,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#_collect">collect</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_concat">concat</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_continue">continue</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#_curry">curry</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#_curry">curry</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_dict">dict</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_env">env</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_eof">eof</a></p></td>
@@ -2491,9 +2710,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#_errorInfo">errorInfo</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_eval">eval</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#cmd_2">eventloop</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#_exec">exec</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#_exec">exec</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_exit">exit</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_expr">expr</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_file">file</a></p></td>
@@ -2501,9 +2720,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#_flush">flush</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_for">for</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_foreach">foreach</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#_format">format</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#_format">format</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_getref">getref</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_gets">gets</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_glob">glob</a></p></td>
@@ -2511,9 +2730,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#_if">if</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_incr">incr</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_info">info</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#_join">join</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#_join">join</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_kill">kill</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_lambda">lambda</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_lappend">lappend</a></p></td>
@@ -2521,9 +2740,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#_lindex">lindex</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_linsert">linsert</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_list">list</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#_llength">llength</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#_llength">llength</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_lmap">lmap</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_load">load</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_local">local</a></p></td>
@@ -2531,9 +2750,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#_lrepeat">lrepeat</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_lreplace">lreplace</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_lreverse">lreverse</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#_lsearch">lsearch</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#_lsearch">lsearch</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_lset">lset</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_lsort">lsort</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_open">open</a></p></td>
@@ -2541,9 +2760,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#cmd_1">os.gethostname</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#cmd_1">os.getids</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#cmd_1">os.uptime</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#cmd_1">os.wait</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#cmd_1">os.wait</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_package">package</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_pid">pid</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#cmd_1">posix</a></p></td>
@@ -2551,9 +2770,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#_puts">puts</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_pwd">pwd</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_rand">rand</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#_range">range</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#_range">range</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_read">read</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_ref">ref</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_regexp">regexp</a></p></td>
@@ -2561,9 +2780,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#_rename">rename</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_return">return</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_scan">scan</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#_seek">seek</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#_seek">seek</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_set">set</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_setref">setref</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_signal">signal</a></p></td>
@@ -2571,9 +2790,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#_socket">socket</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_source">source</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_split">split</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#_stackdump">stackdump</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#_stackdump">stackdump</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_stacktrace">stacktrace</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_string">string</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_subst">subst</a></p></td>
@@ -2581,9 +2800,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#_syslog">syslog</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_tailcall">tailcall</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_tell">tell</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#_throw">throw</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#_throw">throw</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_time">time</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_try">try</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_unknown">unknown</a></p></td>
@@ -2591,9 +2810,9 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"><a href="#cmd_2">update</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_uplevel">uplevel</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_upvar">upvar</a></p></td>
+<td align="left" valign="top"><p class="table"><a href="#cmd_2">vwait</a></p></td>
</tr>
<tr>
-<td align="left" valign="top"><p class="table"><a href="#cmd_2">vwait</a></p></td>
<td align="left" valign="top"><p class="table"><a href="#_while">while</a></p></td>
<td align="left" valign="top"><p class="table"></p></td>
<td align="left" valign="top"><p class="table"></p></td>
@@ -2601,11 +2820,14 @@ cellspacing="0" cellpadding="4">
<td align="left" valign="top"><p class="table"></p></td>
<td align="left" valign="top"><p class="table"></p></td>
<td align="left" valign="top"><p class="table"></p></td>
+<td align="left" valign="top"><p class="table"></p></td>
</tr>
</tbody>
</table>
</div>
-<h3 id="_alarm">alarm</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_alarm">alarm</h3>
<div class="paragraph"><p><tt><strong>alarm</strong> <em>seconds</em></tt></p></div>
<div class="paragraph"><p>Delivers the <em>SIGALRM</em> signal to the process after the given
number of seconds. If the platform supports <em>ularm(3)</em> then
@@ -2613,7 +2835,9 @@ the argument may be a floating point value. Otherwise it must
be an integer.</p></div>
<div class="paragraph"><p>Note that unless a signal handler for <em>SIGALRM</em> has been installed
(see <em>signal</em>), the process will exit on this signal.</p></div>
-<h3 id="_alias">alias</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_alias">alias</h3>
<div class="paragraph"><p><tt><strong>alias</strong> <em>name args&#8230;</em></tt></p></div>
<div class="paragraph"><p>Creates a single word alias (proc) for one or more words. For example,
the following creates an alias for the command <em>info exists</em>.</p></div>
@@ -2626,7 +2850,9 @@ if {[e var]} {
</div></div>
<div class="paragraph"><p><em>alias</em> returns <strong>name</strong>, allowing it to be used with 'local.</p></div>
<div class="paragraph"><p>See also <em>proc</em>, <em>curry</em>, <em>lambda</em>, <em>local</em>.</p></div>
-<h3 id="_append">append</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_append">append</h3>
<div class="paragraph"><p><tt><strong>append</strong> <em>varName value ?value value &#8230;?</em></tt></p></div>
<div class="paragraph"><p>Append all of the <strong>value</strong> arguments to the current value
of variable <strong>varName</strong>. If <strong>varName</strong> doesn&#8217;t exist,
@@ -2636,7 +2862,9 @@ it is given a value equal to the concatenation of all the
variables incrementally.
For example, <em>append a $b</em> is much more efficient than
<em>set a $a$b</em> if <em>$a</em> is long.</p></div>
-<h3 id="_array">array</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_array">array</h3>
<div class="paragraph"><p><tt><strong>array</strong> <em>option arrayName ?arg arg &#8230;?</em></tt></p></div>
<div class="paragraph"><p>This command performs one of several operations on the
variable given by <strong>arrayName</strong>.</p></div>
@@ -2726,12 +2954,16 @@ command. The legal <strong>options</strong> (which may be abbreviated) are:</p>
</p>
</dd>
</dl></div>
-<h3 id="_break">break</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_break">break</h3>
<div class="paragraph"><p><tt><strong>break</strong></tt></p></div>
<div class="paragraph"><p>This command may be invoked only inside the body of a loop command
such as <em>for</em> or <em>foreach</em> or <em>while</em>. It returns a <tt>JIM_BREAK</tt> code
to signal the innermost containing loop command to return immediately.</p></div>
-<h3 id="_case">case</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_case">case</h3>
<div class="paragraph"><p><tt><strong>case</strong> <em>string</em> ?<strong>in</strong>? <em>patList body ?patList body &#8230;?</em></tt></p></div>
<div class="paragraph"><p><tt><strong>case</strong> <em>string</em> ?<strong>in</strong>? {<em>patList body ?patList body &#8230;?</em>}</tt></p></div>
<div class="paragraph"><p><strong>Note</strong> that the switch command should generally be preferred unless compatibility
@@ -2787,7 +3019,9 @@ cases.</p></div>
}</tt></pre>
</div></div>
<div class="paragraph"><p>will return <em>2</em>.</p></div>
-<h3 id="_catch">catch</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_catch">catch</h3>
<div class="paragraph"><p><tt><strong>catch</strong> <em>?-?no?code &#8230;?</em> <strong>?--?</strong> <em>command ?resultVarName? ?optionsVarName?</em></tt></p></div>
<div class="paragraph"><p>The <em>catch</em> command may be used to prevent errors from aborting
command interpretation. <em>Catch</em> evalues <strong>command</strong>, and returns a
@@ -2833,13 +3067,17 @@ The set of codes which will be caught may be modified by specifying the one more
<div class="paragraph"><p>The use of <tt>--</tt> is optional. It signifies that no more return code options follow.</p></div>
<div class="paragraph"><p>Note that if a signal marked as <em>signal handle</em> is caught with <em>catch -signal</em>, the return value
(stored in <strong>resultVarName</strong>) is name of the signal caught.</p></div>
-<h3 id="_cd">cd</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_cd">cd</h3>
<div class="paragraph"><p><tt><strong>cd</strong> <em>dirName</em></tt></p></div>
<div class="paragraph"><p>Change the current working directory to <strong>dirName</strong>.</p></div>
<div class="paragraph"><p>Returns an empty string.</p></div>
<div class="paragraph"><p>This command can potentially be disruptive to an application, so it may
be removed in some applications.</p></div>
-<h3 id="_clock">clock</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_clock">clock</h3>
<div class="dlist"><dl>
<dt class="hdlist1">
<tt><strong>clock seconds</strong></tt>
@@ -2869,19 +3107,25 @@ be removed in some applications.</p></div>
</p>
</dd>
</dl></div>
-<h3 id="_close">close</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_close">close</h3>
<div class="paragraph"><p><tt><strong>close</strong> <em>fileId</em></tt></p></div>
<div class="paragraph"><p><tt><em>fileId</em> <strong>close</strong></tt></p></div>
<div class="paragraph"><p>Closes the file given by <strong>fileId</strong>.
<strong>fileId</strong> must be the return value from a previous invocation
of the <em>open</em> command; after this command, it should not be
used anymore.</p></div>
-<h3 id="_collect">collect</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_collect">collect</h3>
<div class="paragraph"><p><tt><strong>collect</strong></tt></p></div>
<div class="paragraph"><p>Normally reference garbage collection is automatically performed periodically.
However it may be run immediately with the <em>collect</em> command.</p></div>
<div class="paragraph"><p>See GARBAGE COLLECTION, REFERENCES, LAMBDA for more detail.</p></div>
-<h3 id="_concat">concat</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_concat">concat</h3>
<div class="paragraph"><p><tt><strong>concat</strong> <em>arg ?arg &#8230;?</em></tt></p></div>
<div class="paragraph"><p>This command treats each argument as a list and concatenates them
into a single list. It permits any number of arguments. For example,
@@ -2896,13 +3140,17 @@ the command</p></div>
<pre><tt>a b c d e f {g h}</tt></pre>
</div></div>
<div class="paragraph"><p>as its result.</p></div>
-<h3 id="_continue">continue</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_continue">continue</h3>
<div class="paragraph"><p><tt><strong>continue</strong></tt></p></div>
<div class="paragraph"><p>This command may be invoked only inside the body of a loop command such
as <em>for</em> or <em>foreach</em> or <em>while</em>. It returns a <tt>JIM_CONTINUE</tt> code to
signal the innermost containing loop command to skip the remainder of
the loop&#8217;s body but continue with the next iteration of the loop.</p></div>
-<h3 id="_curry">curry</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_curry">curry</h3>
<div class="paragraph"><p><tt><strong>alias</strong> <em>args&#8230;</em></tt></p></div>
<div class="paragraph"><p>Similar to <em>alias</em> except it creates an anonymous procedure (lambda) instead of
a named procedure.</p></div>
@@ -2916,7 +3164,9 @@ if {[$e var]} {
</div></div>
<div class="paragraph"><p><em>curry</em> returns the name of the procedure.</p></div>
<div class="paragraph"><p>See also <em>proc</em>, <em>alias</em>, <em>lambda</em>, <em>local</em>.</p></div>
-<h3 id="_dict">dict</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_dict">dict</h3>
<div class="paragraph"><p><tt><strong>dict</strong> <em>option ?arg arg &#8230;?</em></tt></p></div>
<div class="paragraph"><p>Performs one of several operations on dictionary values.</p></div>
<div class="paragraph"><p>The <strong>option</strong> argument determines what action is carried out by the
@@ -3011,7 +3261,9 @@ command. The legal <strong>options</strong> are:</p></div>
</p>
</dd>
</dl></div>
-<h3 id="_env">env</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_env">env</h3>
<div class="paragraph"><p><tt><strong>env</strong> <em>?name? ?default?</em></tt></p></div>
<div class="paragraph"><p>If <strong>name</strong> is supplied, returns the value of <strong>name</strong> from the initial
environment (see getenv(3)). An error is returned if <strong>name</strong> does not
@@ -3020,7 +3272,9 @@ that value is returned instead.</p></div>
<div class="paragraph"><p>If no arguments are supplied, returns a list of all environment variables
and their values as <tt>{name value &#8230;}</tt></p></div>
<div class="paragraph"><p>See also the global variable <em>::env</em></p></div>
-<h3 id="_eof">eof</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_eof">eof</h3>
<div class="paragraph"><p><tt><strong>eof</strong> <em>fileId</em></tt></p></div>
<div class="paragraph"><p><tt><em>fileId</em> <strong>eof</strong></tt></p></div>
<div class="paragraph"><p>Returns 1 if an end-of-file condition has occurred on <strong>fileId</strong>,
@@ -3028,7 +3282,9 @@ and their values as <tt>{name value &#8230;}</tt></p></div>
<div class="paragraph"><p><strong>fileId</strong> must have been the return value from a previous call to <em>open</em>,
or it may be <em>stdin</em>, <em>stdout</em>, or <em>stderr</em> to refer to one of the
standard I/O channels.</p></div>
-<h3 id="_error">error</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_error">error</h3>
<div class="paragraph"><p><tt><strong>error</strong> <em>message ?stacktrace?</em></tt></p></div>
<div class="paragraph"><p>Returns a <tt>JIM_ERR</tt> code, which causes command interpretation to be
unwound. <strong>message</strong> is a string that is returned to the application
@@ -3046,7 +3302,9 @@ of the error:</p></div>
error $errMsg [info stacktrace]</tt></pre>
</div></div>
<div class="paragraph"><p>See also <em>errorInfo</em>, <em>info stacktrace</em>, <em>catch</em> and <em>return</em></p></div>
-<h3 id="_errorinfo">errorInfo</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_errorinfo">errorInfo</h3>
<div class="paragraph"><p><tt><strong>errorInfo</strong> <em>error ?stacktrace?</em></tt></p></div>
<div class="paragraph"><p>Returns a human-readable representation of the given error message and stack trace.
Typical usage is:</p></div>
@@ -3058,7 +3316,9 @@ Typical usage is:</p></div>
}</tt></pre>
</div></div>
<div class="paragraph"><p>See also <em>error</em>.</p></div>
-<h3 id="_eval">eval</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_eval">eval</h3>
<div class="paragraph"><p><tt><strong>eval</strong> <em>arg ?arg &#8230;?</em></tt></p></div>
<div class="paragraph"><p><em>eval</em> takes one or more arguments, which together comprise a Tcl
command (or collection of Tcl commands separated by newlines in the
@@ -3066,7 +3326,9 @@ usual way). <em>eval</em> concatenates all its arguments in the same
fashion as the <em>concat</em> command, passes the concatenated string to the
Tcl interpreter recursively, and returns the result of that
evaluation (or any error generated by it).</p></div>
-<h3 id="_exec">exec</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_exec">exec</h3>
<div class="paragraph"><p><tt><strong>exec</strong> <em>arg ?arg &#8230;?</em></tt></p></div>
<div class="paragraph"><p>This command treats its arguments as the specification
of one or more UNIX commands to execute as subprocesses.
@@ -3269,18 +3531,24 @@ option in <em>catch</em>) will be set to a list, as follows:</p></div>
</dl></div>
<div class="paragraph"><p>The environment for the executed command is set from $::env (unless
this variable is unset, in which case the original environment is used).</p></div>
-<h3 id="_exit">exit</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_exit">exit</h3>
<div class="paragraph"><p><tt><strong>exit</strong> <em>?returnCode?</em></tt></p></div>
<div class="paragraph"><p>Terminate the process, returning <strong>returnCode</strong> to the
parent as the exit status.</p></div>
<div class="paragraph"><p>If <strong>returnCode</strong> isn&#8217;t specified then it defaults
to 0.</p></div>
<div class="paragraph"><p>Note that exit can be caught with <strong>catch</strong>.</p></div>
-<h3 id="_expr">expr</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_expr">expr</h3>
<div class="paragraph"><p><tt><strong>expr</strong> <em>arg</em></tt></p></div>
<div class="paragraph"><p>Calls the expression processor to evaluate <strong>arg</strong>, and returns
the result as a string. See the section EXPRESSIONS above.</p></div>
-<h3 id="_file">file</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_file">file</h3>
<div class="paragraph"><p><tt><strong>file</strong> <em>option name ?arg arg &#8230;?</em></tt></p></div>
<div class="paragraph"><p>Operate on a file or a file name. <strong>name</strong> is the name of a file.</p></div>
<div class="paragraph"><p><strong>Option</strong> indicates what to do with the file name. Any unique
@@ -3553,7 +3821,9 @@ conditional or looping commands, for example:</p></div>
<div class="content">
<pre><tt>if {![file exists foo]} then {error {bad file name}} else {...}</tt></pre>
</div></div>
-<h3 id="_finalize">finalize</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_finalize">finalize</h3>
<div class="paragraph"><p><tt><strong>finalize</strong> <em>reference ?command?</em></tt></p></div>
<div class="paragraph"><p>If <strong>command</strong> is omitted, returns the finalizer command for the given reference.</p></div>
<div class="paragraph"><p>Otherwise, sets a new finalizer command for the given reference. <strong>command</strong> may be
@@ -3561,7 +3831,9 @@ the empty string to remove the current finalizer.</p></div>
<div class="paragraph"><p>The reference must be a valid reference create with the <em>ref</em>
command.</p></div>
<div class="paragraph"><p>See GARBAGE COLLECTION, REFERENCES, LAMBDA for more detail.</p></div>
-<h3 id="_flush">flush</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_flush">flush</h3>
<div class="paragraph"><p><tt><strong>flush</strong> <em>fileId</em></tt></p></div>
<div class="paragraph"><p><tt><em>fileId</em> <strong>flush</strong></tt></p></div>
<div class="paragraph"><p>Flushes any output that has been buffered for <strong>fileId</strong>. <strong>fileId</strong> must
@@ -3569,7 +3841,9 @@ have been the return value from a previous call to <em>open</em>, or it may be
<em>stdout</em> or <em>stderr</em> to access one of the standard I/O streams; it must
refer to a file that was opened for writing. This command returns an
empty string.</p></div>
-<h3 id="_for">for</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_for">for</h3>
<div class="paragraph"><p><tt><strong>for</strong> <em>start test next body</em></tt></p></div>
<div class="paragraph"><p><em>For</em> is a looping command, similar in structure to the C <em>for</em> statement.
The <strong>start</strong>, <strong>next</strong>, and <strong>body</strong> arguments must be Tcl command strings,
@@ -3588,7 +3862,9 @@ command will return immediately.</p></div>
<div class="paragraph"><p>The operation of <em>break</em> and <em>continue</em> are similar to the corresponding
statements in C.</p></div>
<div class="paragraph"><p><em>For</em> returns an empty string.</p></div>
-<h3 id="_foreach">foreach</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_foreach">foreach</h3>
<div class="paragraph"><p><tt><strong>foreach</strong> <em>varName list body</em></tt></p></div>
<div class="paragraph"><p><tt><strong>foreach</strong> <em>varList list ?varList2 list2 &#8230;? body</em></tt></p></div>
<div class="paragraph"><p>In this command, <strong>varName</strong> is the name of a variable, <strong>list</strong>
@@ -3608,7 +3884,9 @@ of the loop are undefined.</p></div>
<div class="paragraph"><p>The <em>break</em> and <em>continue</em> statements may be invoked inside <strong>body</strong>,
with the same effect as in the <em>for</em> command.</p></div>
<div class="paragraph"><p><em>foreach</em> returns an empty string.</p></div>
-<h3 id="_format">format</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_format">format</h3>
<div class="paragraph"><p><tt><strong>format</strong> <em>formatString ?arg arg &#8230;?</em></tt></p></div>
<div class="paragraph"><p>This command generates a formatted string in the same way as the
C <em>sprintf</em> procedure (it uses <em>sprintf</em> in its
@@ -3627,12 +3905,16 @@ ASCII character value.</p></div>
argument, so backslash sequences in <strong>formatString</strong> will be handled
correctly even if the argument is in braces.</p></div>
<div class="paragraph"><p>The return value from <em>format</em> is the formatted string.</p></div>
-<h3 id="_getref">getref</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_getref">getref</h3>
<div class="paragraph"><p><tt><strong>getref</strong> <em>reference</em></tt></p></div>
<div class="paragraph"><p>Returns the string associated with <strong>reference</strong>. The reference must
be a valid reference create with the <em>ref</em> command.</p></div>
<div class="paragraph"><p>See GARBAGE COLLECTION, REFERENCES, LAMBDA for more detail.</p></div>
-<h3 id="_gets">gets</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_gets">gets</h3>
<div class="paragraph"><p><tt><strong>gets</strong> <em>fileId ?varName?</em></tt></p></div>
<div class="paragraph"><p><tt><em>fileId</em> <strong>gets</strong> <em>?varName?</em></tt></p></div>
<div class="paragraph"><p>Reads the next line from the file given by <strong>fileId</strong> and discards
@@ -3655,7 +3937,9 @@ at the end of the file.</p></div>
<div class="paragraph"><p><strong>fileId</strong> must be <em>stdin</em> or the return value from a previous
call to <em>open</em>; it must refer to a file that was opened
for reading.</p></div>
-<h3 id="_glob">glob</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_glob">glob</h3>
<div class="paragraph"><p><tt><strong>glob</strong> ?<strong>-nocomplain</strong>? <em>pattern ?pattern &#8230;?</em></tt></p></div>
<div class="paragraph"><p>This command performs filename globbing, using csh rules. The returned
value from <em>glob</em> is the list of expanded filenames.</p></div>
@@ -3663,7 +3947,9 @@ value from <em>glob</em> is the list of expanded filenames.</p></div>
list may be returned; otherwise an error is returned if the expanded
list is empty. The <em>-nocomplain</em> argument must be provided
exactly: an abbreviation will not be accepted.</p></div>
-<h3 id="_global">global</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_global">global</h3>
<div class="paragraph"><p><tt><strong>global</strong> <em>varName ?varName &#8230;?</em></tt></p></div>
<div class="paragraph"><p>This command is ignored unless a Tcl procedure is being interpreted.
If so, then it declares each given <strong>varName</strong> to be a global variable
@@ -3673,7 +3959,9 @@ rather than a local one. For the duration of the current procedure
of a local one.</p></div>
<div class="paragraph"><p>An alternative to using <em>global</em> is to use the <em>::</em> prefix
to explicitly name a variable in the global scope.</p></div>
-<h3 id="_if">if</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_if">if</h3>
<div class="paragraph"><p><tt><strong>if</strong> <em>expr1</em> ?<strong>then</strong>? <em>body1</em> <strong>elseif</strong> <em>expr2</em> ?<strong>then</strong>? <em>body2</em> <strong>elseif</strong> &#8230; ?<strong>else</strong>? ?<em>bodyN</em>?</tt></p></div>
<div class="paragraph"><p>The <em>if</em> command evaluates <strong>expr1</strong> as an expression (in the same way
that <em>expr</em> evaluates its argument). The value of the expression must
@@ -3689,7 +3977,9 @@ may also be omitted as long as <em>else</em> is omitted too.</p></div>
<div class="paragraph"><p>The return value from the command is the result of the body script that
was executed, or an empty string if none of the expressions was non-zero
and there was no <strong>bodyN</strong>.</p></div>
-<h3 id="_incr">incr</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_incr">incr</h3>
<div class="paragraph"><p><tt><strong>incr</strong> <em>varName ?increment?</em></tt></p></div>
<div class="paragraph"><p>Increment the value stored in the variable whose name is <strong>varName</strong>.
The value of the variable must be integral.</p></div>
@@ -3700,7 +3990,9 @@ integer) is added to the value of variable <strong>varName</strong>; otherwise
and also returned as result.</p></div>
<div class="paragraph"><p>If the variable does not exist, the variable is implicitly created
and set to <tt>0</tt> first.</p></div>
-<h3 id="_info">info</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_info">info</h3>
<div class="dlist"><dl>
<dt class="hdlist1">
<tt><strong>info</strong> <em>option ?arg arg &#8230;?</em></tt>
@@ -3946,13 +4238,17 @@ The legal <strong>option</strong>'s (which may be abbreviated) are:
</p>
</dd>
</dl></div>
-<h3 id="_join">join</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_join">join</h3>
<div class="paragraph"><p><tt><strong>join</strong> <em>list ?joinString?</em></tt></p></div>
<div class="paragraph"><p>The <strong>list</strong> argument must be a valid Tcl list. This command returns the
string formed by joining all of the elements of <strong>list</strong> together with
<strong>joinString</strong> separating each adjacent pair of elements.</p></div>
<div class="paragraph"><p>The <strong>joinString</strong> argument defaults to a space character.</p></div>
-<h3 id="_kill">kill</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_kill">kill</h3>
<div class="paragraph"><p><tt><strong>kill</strong> ?<em>SIG</em>|<strong>-0</strong>? <em>pid</em></tt></p></div>
<div class="paragraph"><p>Sends the given signal to the process identified by <strong>pid</strong>.</p></div>
<div class="paragraph"><p>The signal may be specified by name or number in one of the following forms:</p></div>
@@ -3987,13 +4283,17 @@ string formed by joining all of the elements of <strong>list</strong> together w
<div class="paragraph"><p>The special signal name <em>-0</em> simply checks that a signal <strong>could</strong> be sent.</p></div>
<div class="paragraph"><p>If no signal is specified, SIGTERM is used.</p></div>
<div class="paragraph"><p>An error is raised if the signal could not be delivered.</p></div>
-<h3 id="_lambda_2">lambda</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lambda_2">lambda</h3>
<div class="paragraph"><p><tt><strong>lambda</strong> <em>args ?statics? body</em></tt></p></div>
<div class="paragraph"><p>The <em>lambda</em> command is identical to <em>proc</em>, except rather than
creating a named procedure, it creates an anonymous procedure and returns
the name of the procedure.</p></div>
<div class="paragraph"><p>See <em>proc</em> and GARBAGE COLLECTION, REFERENCES, LAMBDA for more detail.</p></div>
-<h3 id="_lappend">lappend</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lappend">lappend</h3>
<div class="paragraph"><p><tt><strong>lappend</strong> <em>varName value ?value value &#8230;?</em></tt></p></div>
<div class="paragraph"><p>Treat the variable given by <strong>varName</strong> as a list and append each of
the <strong>value</strong> arguments to that list as a separate element, with spaces
@@ -4008,7 +4308,9 @@ For example, <em>lappend a $b</em> is much more efficient than</p></div>
<pre><tt>set a [concat $a [list $b]]</tt></pre>
</div></div>
<div class="paragraph"><p>when <em>$a</em> is long.</p></div>
-<h3 id="_lassign">lassign</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lassign">lassign</h3>
<div class="paragraph"><p><tt><strong>lassign</strong> <em>list varName ?varName? &#8230;</em></tt></p></div>
<div class="paragraph"><p>This command treats the value <strong>list</strong> as a list and assigns successive elements from that list to
the variables given by the <strong>varName</strong> arguments in order. If there are more variable names than
@@ -4020,7 +4322,9 @@ ments than variables, a list of unassigned elements is returned.</p></div>
3
a=1,b=2</tt></pre>
</div></div>
-<h3 id="_local">local</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_local">local</h3>
<div class="paragraph"><p><tt><strong>local</strong> <em>args</em></tt></p></div>
<div class="paragraph"><p>Executes it&#8217;s arguments as a command (per <em>eval</em>) and considers the return
value to be a procedure name, which is marked as having local scope.
@@ -4060,7 +4364,9 @@ than waiting until garbage collection.</p></div>
...
}</tt></pre>
</div></div>
-<h3 id="_lindex">lindex</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lindex">lindex</h3>
<div class="paragraph"><p><tt><strong>lindex</strong> <em>list index</em></tt></p></div>
<div class="paragraph"><p>Treats <strong>list</strong> as a Tcl list and returns element <strong>index</strong> from it
(0 refers to the first element of the list).
@@ -4070,7 +4376,9 @@ braces and quotes and backslashes as the Tcl command interpreter; however,
variable substitution and command substitution do not occur.</p></div>
<div class="paragraph"><p>If <strong>index</strong> is negative or greater than or equal to the number of elements
in <strong>value</strong>, then an empty string is returned.</p></div>
-<h3 id="_linsert">linsert</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_linsert">linsert</h3>
<div class="paragraph"><p><tt><strong>linsert</strong> <em>list index element ?element element &#8230;?</em></tt></p></div>
<div class="paragraph"><p>This command produces a new list from <strong>list</strong> by inserting all
of the <strong>element</strong> arguments just before the element <strong>index</strong>
@@ -4081,7 +4389,9 @@ beginning of the list. If <strong>index</strong> is greater than or equal
to the number of elements in the list, then the new elements are
appended to the list.</p></div>
<div class="paragraph"><p>See STRING AND LIST INDEX SPECIFICATIONS for all allowed forms for <strong>index</strong>.</p></div>
-<h3 id="_list">list</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_list">list</h3>
<div class="paragraph"><p><tt><strong>list</strong> <em>arg ?arg &#8230;?</em></tt></p></div>
<div class="paragraph"><p>This command returns a list comprised of all the arguments, <strong>arg</strong>. Braces
and backslashes get added as necessary, so that the <em>index</em> command
@@ -4106,11 +4416,15 @@ For example, the command</p></div>
<div class="content">
<pre><tt>a b c d e f {g h}</tt></pre>
</div></div>
-<h3 id="_llength">llength</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_llength">llength</h3>
<div class="paragraph"><p><tt><strong>llength</strong> <em>list</em></tt></p></div>
<div class="paragraph"><p>Treats <strong>list</strong> as a list and returns a decimal string giving
the number of elements in it.</p></div>
-<h3 id="_lset">lset</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lset">lset</h3>
<div class="paragraph"><p><tt><strong>lset</strong> <em>varName ?index ..? newValue</em></tt></p></div>
<div class="paragraph"><p>Sets an element in a list.</p></div>
<div class="paragraph"><p>The <em>lset</em> command accepts a parameter, <strong>varName</strong>, which it interprets
@@ -4151,7 +4465,9 @@ or equal to zero. The integer appearing in each index argument must
be strictly less than the length of the corresponding list. In other
words, the <em>lset</em> command cannot change the size of a list. If an
index is outside the permitted range, an error is reported.</p></div>
-<h3 id="_lmap">lmap</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lmap">lmap</h3>
<div class="paragraph"><p><tt><strong>lmap</strong> <em>varName list body</em></tt></p></div>
<div class="paragraph"><p><tt><strong>lmap</strong> <em>varList list ?varList2 list2 &#8230;? body</em></tt></p></div>
<div class="paragraph"><p><em>lmap</em> is a "collecting <em>foreach</em>" which returns a list of its results.</p></div>
@@ -4165,14 +4481,18 @@ jim&gt; lmap a {1 2 3} b {A B C} {list $a $b}
</div></div>
<div class="paragraph"><p>If the body invokes <em>continue</em>, no value is added for this iteration.
If the body invokes <em>break</em>, the loop ends and no more values are added.</p></div>
-<h3 id="_load">load</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_load">load</h3>
<div class="paragraph"><p><tt><strong>load</strong> <em>filename</em></tt></p></div>
<div class="paragraph"><p>Loads the dynamic extension, <strong>filename</strong>. Generally the filename should have
the extension <em>.so</em>. The initialisation function for the module must be based
on the name of the file. For example loading <tt>dir/hwaccess.so</tt> will invoke
the initialisation function, <tt>Jim_hwaccessInit</tt>. Normally the <em>load</em> command
should not be used directly. Instead it is invoked automatically by <em>package require</em>.</p></div>
-<h3 id="_lrange">lrange</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lrange">lrange</h3>
<div class="paragraph"><p><tt><strong>lrange</strong> <em>list first last</em></tt></p></div>
<div class="paragraph"><p><strong>List</strong> must be a valid Tcl list. This command will return a new
list consisting of elements <strong>first</strong> through <strong>last</strong>, inclusive.</p></div>
@@ -4185,7 +4505,9 @@ is returned.</p></div>
same result as <em>lindex <strong>list first</strong></em> (although it often does
for simple fields that aren&#8217;t enclosed in braces); it does, however,
produce exactly the same results as <em>list [lindex <strong>list first</strong>]</em></p></div>
-<h3 id="_lreplace">lreplace</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lreplace">lreplace</h3>
<div class="paragraph"><p><tt><strong>lreplace</strong> <em>list first last ?element element &#8230;?</em></tt></p></div>
<div class="paragraph"><p>Returns a new list formed by replacing one or more elements of
<strong>list</strong> with the <strong>element</strong> arguments.</p></div>
@@ -4203,7 +4525,9 @@ be added to the list in place of those that were deleted.</p></div>
the list.</p></div>
<div class="paragraph"><p>If no <strong>element</strong> arguments are specified, then the elements
between <strong>first</strong> and <strong>last</strong> are simply deleted.</p></div>
-<h3 id="_lrepeat">lrepeat</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lrepeat">lrepeat</h3>
<div class="paragraph"><p><tt><strong>lrepeat</strong> <em>number element1 ?element2 &#8230;?</em></tt></p></div>
<div class="paragraph"><p>Build a list by repeating elements <strong>number</strong> times (which must be
a positive integer).</p></div>
@@ -4212,7 +4536,9 @@ a positive integer).</p></div>
<pre><tt>jim&gt; lrepeat 3 a b
a b a b a b</tt></pre>
</div></div>
-<h3 id="_lreverse">lreverse</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lreverse">lreverse</h3>
<div class="paragraph"><p><tt><strong>lreverse</strong> <em>list</em></tt></p></div>
<div class="paragraph"><p>Returns the list in reverse order.</p></div>
<div class="literalblock">
@@ -4220,7 +4546,9 @@ a b a b a b</tt></pre>
<pre><tt>jim&gt; lreverse {1 2 3}
3 2 1</tt></pre>
</div></div>
-<h3 id="_lsearch">lsearch</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lsearch">lsearch</h3>
<div class="paragraph"><p><tt><strong>lsearch</strong> <em>?options? list pattern</em></tt></p></div>
<div class="paragraph"><p>This command searches the elements <strong>list</strong> to see if one of them matches <strong>pattern</strong>. If so, the
command returns the index of the first matching element (unless the options -all, -inline or -bool are
@@ -4307,7 +4635,9 @@ the list are to be matched against pattern and must have one of the values below
</p>
</dd>
</dl></div>
-<h3 id="_lsort">lsort</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_lsort">lsort</h3>
<div class="paragraph"><p><tt><strong>lsort</strong> ?<strong>-index</strong> <em>listindex</em>? ?<strong>-integer</strong>|<strong>-command</strong> <em>cmdname</em>? ?<strong>-decreasing</strong>|<strong>-increasing</strong>? <em>list</em></tt></p></div>
<div class="paragraph"><p>Sort the elements of <strong>list</strong>, returning a new list in sorted order.
By default, ASCII sorting is used, with the result in increasing order.</p></div>
@@ -4324,7 +4654,9 @@ be any valid list index, such as <em>1</em>, <em>end</em> or <em>end-2</em>.</p>
<div class="paragraph"><p>If <strong>-index listindex</strong> is specified, each element of the list is treated as a list and
the given index is extracted from the list for comparison. The list index may
be any valid list index, such as <em>1</em>, <em>end</em> or <em>end-2</em>.</p></div>
-<h3 id="_open">open</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_open">open</h3>
<div class="paragraph"><p><tt><strong>open</strong> <em>fileName ?access?</em></tt></p></div>
<div class="paragraph"><p><tt><strong>open</strong> <em>|command-pipeline ?access?</em></tt></p></div>
<div class="paragraph"><p>Opens a file and returns an identifier
@@ -4406,7 +4738,9 @@ input unless overridden by the command.</p></div>
<div class="paragraph"><p>The <em>pid</em> command may be used to return the process ids of the commands
forming the command pipeline.</p></div>
<div class="paragraph"><p>See also <em>socket</em>, <em>pid</em>, <em>exec</em></p></div>
-<h3 id="_package">package</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_package">package</h3>
<div class="paragraph"><p><tt><strong>package provide</strong> <em>name ?version?</em></tt></p></div>
<div class="paragraph"><p>Indicates that the current script provides the package named <strong>name</strong>.
If no version is specified, <em>1.0</em> is used.</p></div>
@@ -4422,7 +4756,9 @@ or <em>$path/$name.tcl</em> as a script package.</p></div>
otherwise if <em>$name.tcl</em> exists it is loaded with the <em>source</em> command.</p></div>
<div class="paragraph"><p>If <em>load</em> or <em>source</em> fails, <em>package require</em> will fail immediately.
No further attempt will be made to locate the file.</p></div>
-<h3 id="_pid">pid</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_pid">pid</h3>
<div class="paragraph"><p><tt><strong>pid</strong></tt></p></div>
<div class="paragraph"><p><tt><strong>pid</strong> <em>fileId</em></tt></p></div>
<div class="paragraph"><p>The first form returns the process identifier of the current process.</p></div>
@@ -4431,7 +4767,9 @@ of the process ids forming the pipeline in the same form as <em>exec &#8230; &am
If <em>fileId</em> represents a regular file handle rather than a command pipeline,
the empty string is returned instead.</p></div>
<div class="paragraph"><p>See also <em>open</em>, <em>exec</em></p></div>
-<h3 id="_proc">proc</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_proc">proc</h3>
<div class="paragraph"><p><tt><strong>proc</strong> <em>name args ?statics? body</em></tt></p></div>
<div class="paragraph"><p>The <em>proc</em> command creates a new Tcl command procedure, <strong>name</strong>.
When the new command is invoked, the contents of <strong>body</strong> will be executed.
@@ -4446,7 +4784,9 @@ execute an explicit <em>return</em>, then its return value is the value
of the last command executed in the procedure&#8217;s body.</p></div>
<div class="paragraph"><p>If an error occurs while executing the procedure body, then the
procedure-as-a-whole will return that same error.</p></div>
-<h3 id="_puts">puts</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_puts">puts</h3>
<div class="paragraph"><p><tt><strong>puts</strong> ?<strong>-nonewline</strong>? <em>?fileId? string</em></tt></p></div>
<div class="paragraph"><p><tt><em>fileId</em> <strong>puts</strong> ?<strong>-nonewline</strong>? <em>string</em></tt></p></div>
<div class="paragraph"><p>Writes the characters given by <strong>string</strong> to the file given
@@ -4461,15 +4801,21 @@ but this feature may be suppressed by specifying the <em>-nonewline</em>
switch.</p></div>
<div class="paragraph"><p>Output to files is buffered internally by Tcl; the <em>flush</em>
command may be used to force buffered characters to be output.</p></div>
-<h3 id="_pwd">pwd</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_pwd">pwd</h3>
<div class="paragraph"><p><tt><strong>pwd</strong></tt></p></div>
<div class="paragraph"><p>Returns the path name of the current working directory.</p></div>
-<h3 id="_rand">rand</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_rand">rand</h3>
<div class="paragraph"><p><tt><strong>rand</strong> <em>?min? ?max?</em></tt></p></div>
<div class="paragraph"><p>Returns a random integer between <strong>min</strong> (defaults to 0) and <strong>max</strong>
(defaults to the maximum integer).</p></div>
<div class="paragraph"><p>If only one argument is given, it is interpreted as <strong>max</strong>.</p></div>
-<h3 id="_range">range</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_range">range</h3>
<div class="paragraph"><p><tt><strong>range</strong> <em>?start? end ?step?</em></tt></p></div>
<div class="paragraph"><p>Returns a list of integers starting at <strong>start</strong> (defaults to 0)
and ranging up to but not including <strong>end</strong> in steps of <strong>step</strong> defaults to 1).</p></div>
@@ -4484,7 +4830,9 @@ jim&gt; range 2 10 4
jim&gt; range 7 4 -2
7 5</tt></pre>
</div></div>
-<h3 id="_read">read</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_read">read</h3>
<div class="paragraph"><p><tt><strong>read</strong> ?<strong>-nonewline</strong>? <em>fileId</em></tt></p></div>
<div class="paragraph"><p><tt><em>fileId</em> <strong>read</strong> ?<strong>-nonewline</strong>?</tt></p></div>
<div class="paragraph"><p><tt><strong>read</strong> <em>fileId numBytes</em></tt></p></div>
@@ -4499,7 +4847,9 @@ exactly this many bytes will be read and returned, unless there are fewer than
bytes are returned.</p></div>
<div class="paragraph"><p><strong>fileId</strong> must be <em>stdin</em> or the return value from a previous call
to <em>open</em>; it must refer to a file that was opened for reading.</p></div>
-<h3 id="_regexp">regexp</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_regexp">regexp</h3>
<div class="paragraph"><p><tt><strong>regexp ?-nocase? ?-line? ?-indices? ?-start</strong> <em>offset</em>? <strong>?-all? ?-inline? ?--?</strong> <em>exp string ?matchVar? ?subMatchVar subMatchVar &#8230;?</em></tt></p></div>
<div class="paragraph"><p>Determines whether the regular expression <strong>exp</strong> matches part or
all of <strong>string</strong> and returns 1 if it does, 0 if it doesn&#8217;t.</p></div>
@@ -4607,7 +4957,9 @@ string otherwise.</p></div>
</p>
</dd>
</dl></div>
-<h3 id="_regsub">regsub</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_regsub">regsub</h3>
<div class="paragraph"><p><tt><strong>regsub ?-nocase? ?-all? ?-line? ?-start</strong> <em>offset</em>? ?<strong>--</strong>? <em>exp string subSpec ?varName?</em></tt></p></div>
<div class="paragraph"><p>This command matches the regular expression <strong>exp</strong> against
<strong>string</strong> using the rules described in REGULAR EXPRESSIONS
@@ -4693,7 +5045,9 @@ backslashes.</p></div>
</p>
</dd>
</dl></div>
-<h3 id="_ref">ref</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_ref">ref</h3>
<div class="paragraph"><p><tt><strong>ref</strong> <em>string tag ?finalizer?</em></tt></p></div>
<div class="paragraph"><p>Create a new reference containing <strong>string</strong> of type <strong>tag</strong>.
If <strong>finalizer</strong> is specified, it is a command which will be invoked
@@ -4705,13 +5059,17 @@ no longer accessible.</p></div>
<pre><tt>+finalizer 'reference string'+</tt></pre>
</div></div>
<div class="paragraph"><p>See GARBAGE COLLECTION, REFERENCES, LAMBDA for more detail.</p></div>
-<h3 id="_rename">rename</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_rename">rename</h3>
<div class="paragraph"><p><tt><strong>rename</strong> <em>oldName newName</em></tt></p></div>
<div class="paragraph"><p>Rename the command that used to be called <strong>oldName</strong> so that it
is now called <strong>newName</strong>. If <strong>newName</strong> is an empty string
(e.g. {}) then <strong>oldName</strong> is deleted. The <em>rename</em> command
returns an empty string as result.</p></div>
-<h3 id="_return">return</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_return">return</h3>
<div class="paragraph"><p><tt><strong>return</strong> ?<strong>-code</strong> <em>code</em>? ?<strong>-errorinfo</strong> <em>stacktrace</em>? ?<strong>-errorcode</strong> <em>errorcode</em>? ?<strong>-level</strong> <em>n</em>? ?<em>value</em>?</tt></p></div>
<div class="paragraph"><p>Return immediately from the current procedure (or top-level command
or <em>source</em> command), with <strong>value</strong> as the return value. If <strong>value</strong>
@@ -4728,7 +5086,9 @@ an example of how this is done.</p></div>
<div class="paragraph"><p>If <strong>-errorinfo</strong> is specified (as returned from <em>info stacktrace</em>)
it is used to initialize the stacktrace.</p></div>
<div class="paragraph"><p>If <strong>-errorcode</strong> is specified, it is used to set the global variable $::errorCode.</p></div>
-<h3 id="_scan">scan</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_scan">scan</h3>
<div class="paragraph"><p><tt><strong>scan</strong> <em>string format varName1 ?varName2 &#8230;?</em></tt></p></div>
<div class="paragraph"><p>This command parses fields from an input string in the same fashion
as the C <em>sscanf</em> procedure. <strong>String</strong> gives the input to be parsed
@@ -4741,7 +5101,9 @@ only unusual conversion is for <em>%c</em>. For <em>%c</em> conversions a singl
character value is converted to a decimal string, which is then
assigned to the corresponding <strong>varName</strong>; no field width may be
specified for this conversion.</p></div>
-<h3 id="_seek">seek</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_seek">seek</h3>
<div class="paragraph"><p><tt><strong>seek</strong> <em>fileId offset ?origin?</em></tt></p></div>
<div class="paragraph"><p><tt><em>fileId</em> <strong>seek</strong> <em>offset ?origin?</em></tt></p></div>
<div class="paragraph"><p>Change the current access position for <strong>fileId</strong>.
@@ -4786,7 +5148,9 @@ must be one of the following:</p></div>
<em>open</em>, or it may be <em>stdin</em>, <em>stdout</em>, or <em>stderr</em> to refer to one
of the standard I/O channels.</p></div>
<div class="paragraph"><p>This command returns an empty string.</p></div>
-<h3 id="_set">set</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_set">set</h3>
<div class="paragraph"><p><tt><strong>set</strong> <em>varName ?value?</em></tt></p></div>
<div class="paragraph"><p>Returns the value of variable <strong>varName</strong>.</p></div>
<div class="paragraph"><p>If <strong>value</strong> is specified, then set the value of <strong>varName</strong> to <strong>value</strong>,
@@ -4804,13 +5168,17 @@ or local variable of the procedure, unless the <strong>global</strong> command
has been invoked to declare <strong>varName</strong> to be global.</p></div>
<div class="paragraph"><p>The <em>::</em> prefix may also be used to explicitly reference a variable
in the global scope.</p></div>
-<h3 id="_setref">setref</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_setref">setref</h3>
<div class="paragraph"><p><tt><strong>setref</strong> <em>reference string</em></tt></p></div>
<div class="paragraph"><p>Store a new string in <strong>reference</strong>, replacing the existing string.
The reference must be a valid reference create with the <em>ref</em>
command.</p></div>
<div class="paragraph"><p>See GARBAGE COLLECTION, REFERENCES, LAMBDA for more detail.</p></div>
-<h3 id="_signal">signal</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_signal">signal</h3>
<div class="paragraph"><p>Command for signal handling.</p></div>
<div class="paragraph"><p>See <em>kill</em> for the different forms which may be used to specify signals.</p></div>
<div class="paragraph"><p>Commands which return a list of signal names do so using the canonical form:
@@ -4907,12 +5275,16 @@ while {1} {
# Received SIGHUP, so reconfigure
}</tt></pre>
</div></div>
-<h3 id="_sleep">sleep</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_sleep">sleep</h3>
<div class="paragraph"><p><tt><strong>sleep</strong> <em>seconds</em></tt></p></div>
<div class="paragraph"><p>Pauses for the given number of seconds, which may be a floating
point value less than one to sleep for less than a second, or an
integer to sleep for one or more seconds.</p></div>
-<h3 id="_source">source</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_source">source</h3>
<div class="paragraph"><p><tt><strong>source</strong> <em>fileName</em></tt></p></div>
<div class="paragraph"><p>Read file <strong>fileName</strong> and pass the contents to the Tcl interpreter
as a sequence of commands to execute in the normal fashion. The return
@@ -4922,7 +5294,9 @@ file, then the <em>source</em> command will return that error.</p></div>
<div class="paragraph"><p>If a <em>return</em> command is invoked from within the file, the remainder of
the file will be skipped and the <em>source</em> command will return
normally with the result from the <em>return</em> command.</p></div>
-<h3 id="_split">split</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_split">split</h3>
<div class="paragraph"><p><tt><strong>split</strong> <em>string ?splitChars?</em></tt></p></div>
<div class="paragraph"><p>Returns a list created by splitting <strong>string</strong> at each character
that is in the <strong>splitChars</strong> argument.</p></div>
@@ -4946,16 +5320,22 @@ For example,</p></div>
<pre><tt>split "Hello world" {}</tt></pre>
</div></div>
<div class="paragraph"><p>returns <tt><em>"H e l l o { } w o r l d"</em></tt>.</p></div>
-<h3 id="_stackdump">stackdump</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_stackdump">stackdump</h3>
<div class="paragraph"><p><tt><strong>stackdump</strong> <em>stacktrace</em></tt></p></div>
<div class="paragraph"><p>Creates a human readable representation of a stack trace.</p></div>
-<h3 id="_stacktrace">stacktrace</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_stacktrace">stacktrace</h3>
<div class="paragraph"><p><tt><strong>stacktrace</strong></tt></p></div>
<div class="paragraph"><p>Returns a live stack trace as a list of <tt>proc file line proc file line &#8230;</tt>.
Iteratively uses <em>info frame</em> to create the stack trace. This stack trace is in the
same form as produced by <em>catch</em> and <em>info stacktrace</em></p></div>
<div class="paragraph"><p>See also <em>stackdump</em>.</p></div>
-<h3 id="_string">string</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_string">string</h3>
<div class="paragraph"><p><tt><strong>string</strong> <em>option arg ?arg &#8230;?</em></tt></p></div>
<div class="paragraph"><p>Perform one of several string operations, depending on <strong>option</strong>.
The legal options (which may be abbreviated) are:</p></div>
@@ -5361,7 +5741,9 @@ Any hexadecimal digit character ([0-9A-Fa-f]).
</p>
</dd>
</dl></div>
-<h3 id="_subst">subst</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_subst">subst</h3>
<div class="paragraph"><p><tt><strong>subst ?-nobackslashes? ?-nocommands? ?-novariables?</strong> <em>string</em></tt></p></div>
<div class="paragraph"><p>This command performs variable substitutions, command substitutions,
and backslash substitutions on its string argument and returns the
@@ -5382,7 +5764,9 @@ the following script returns <em>xyz {44}</em>, not <em>xyz {$a}</em>.</p></div>
<pre><tt>set a 44
subst {xyz {$a}}</tt></pre>
</div></div>
-<h3 id="_switch">switch</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_switch">switch</h3>
<div class="paragraph"><p><tt><strong>switch</strong> <em>?options? string pattern body ?pattern body &#8230;?</em></tt></p></div>
<div class="paragraph"><p><tt><strong>switch</strong> <em>?options? string {pattern body ?pattern body &#8230;?}</em></tt></p></div>
<div class="paragraph"><p>The <em>switch</em> command matches its string argument against each of
@@ -5489,7 +5873,9 @@ body among several patterns.</p></div>
}</tt></pre>
</div></div>
<div class="paragraph"><p>will return 3.</p></div>
-<h3 id="_tailcall">tailcall</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_tailcall">tailcall</h3>
<div class="paragraph"><p><tt><strong>tailcall</strong> <em>cmd ?arg&#8230;?</em></tt></p></div>
<div class="paragraph"><p>The <em>tailcall</em> command provides an optimised way of invoking a command whilst replacing
the current call frame. This is similar to <em>exec</em> in Bourne Shell.</p></div>
@@ -5511,7 +5897,9 @@ the current call frame. This is similar to <em>exec</em> in Bourne Shell.</p></d
proc sub_cmd1 ...
proc sub_cmd2 ...</tt></pre>
</div></div>
-<h3 id="_tell">tell</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_tell">tell</h3>
<div class="paragraph"><p><tt><strong>tell</strong> <em>fileId</em></tt></p></div>
<div class="paragraph"><p><tt><em>fileId</em> <strong>tell</strong></tt></p></div>
<div class="paragraph"><p>Returns a decimal string giving the current access position in
@@ -5519,13 +5907,17 @@ proc sub_cmd2 ...</tt></pre>
<div class="paragraph"><p><strong>fileId</strong> must have been the return value from a previous call to
<em>open</em>, or it may be <em>stdin</em>, <em>stdout</em>, or <em>stderr</em> to refer to one
of the standard I/O channels.</p></div>
-<h3 id="_throw">throw</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_throw">throw</h3>
<div class="paragraph"><p><tt><strong>throw</strong> <em>code ?msg?</em></tt></p></div>
<div class="paragraph"><p>This command throws an exception (return) code along with an optional message.
This command is mostly for convenient usage with <em>try</em>.</p></div>
<div class="paragraph"><p>The command <tt>throw break</tt> is equivalent to <tt>break</tt>.
The command <tt>throw 20 message</tt> can be caught with an <tt>on 20 &#8230;</tt> clause to <em>try</em>.</p></div>
-<h3 id="_time">time</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_time">time</h3>
<div class="paragraph"><p><tt><strong>time</strong> <em>command ?count?</em></tt></p></div>
<div class="paragraph"><p>This command will call the Tcl interpreter <strong>count</strong>
times to execute <strong>command</strong> (or once if <strong>count</strong> isn&#8217;t
@@ -5537,7 +5929,9 @@ specified). It will then return a string of the form</p></div>
<div class="paragraph"><p>which indicates the average amount of time required per iteration,
in microseconds.</p></div>
<div class="paragraph"><p>Time is measured in elapsed time, not CPU time.</p></div>
-<h3 id="_try">try</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_try">try</h3>
<div class="paragraph"><p><tt><strong>try</strong> <em>?catchopts? tryscript</em> ?<strong>on</strong> <em>returncodes {?resultvar? ?optsvar?} handlerscript &#8230;</em>? ?<strong>finally</strong> <em>finalscript</em>?</tt></p></div>
<div class="paragraph"><p>The <em>try</em> command is provided as a convenience for exception handling.</p></div>
<div class="paragraph"><p>This interpeter first evaluates <strong>tryscript</strong> under the effect of the catch
@@ -5575,7 +5969,9 @@ try -signal {
handler.</p></div>
<div class="paragraph"><p>In any case, the file will be closed via the <em>finally</em> clause.</p></div>
<div class="paragraph"><p>See also <em>throw</em>, <em>catch</em>, <em>return</em>, <em>error</em>.</p></div>
-<h3 id="_unknown">unknown</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_unknown">unknown</h3>
<div class="paragraph"><p><tt><strong>unknown</strong> <em>cmdName ?arg arg &#8230;?</em></tt></p></div>
<div class="paragraph"><p>This command doesn&#8217;t actually exist as part of Tcl, but Tcl will
invoke it if it does exist.</p></div>
@@ -5595,7 +5991,9 @@ or automatically executing unknown commands as UNIX sub-processes.</p></div>
change the original command slightly and then (re-)execute it.
The result of the <em>unknown</em> command is used as the result for
the original non-existent command.</p></div>
-<h3 id="_unset">unset</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_unset">unset</h3>
<div class="paragraph"><p><tt><strong>unset ?-nocomplain? ?--?</strong> <em>?name name &#8230;?</em></tt></p></div>
<div class="paragraph"><p>Remove variables.
Each <strong>name</strong> is a variable name, specified in any of the
@@ -5608,7 +6006,9 @@ index, then the entire array is deleted.</p></div>
<div class="paragraph"><p>An error occurs if any of the variables doesn&#8217;t exist, unless <em>-nocomplain</em>
is specified. The <em>--</em> argument may be specified to stop option processing
in case the variable name may be <em>-nocomplain</em>.</p></div>
-<h3 id="_uplevel">uplevel</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_uplevel">uplevel</h3>
<div class="paragraph"><p><tt><strong>uplevel</strong> <em>?level? command ?command &#8230;?</em></tt></p></div>
<div class="paragraph"><p>All of the <strong>command</strong> arguments are concatenated as if they had
been passed to <em>concat</em>; the result is then evaluated in the
@@ -5649,7 +6049,9 @@ be used to obtain the level of the current procedure.</p></div>
<div class="paragraph"><p><em>Uplevel</em> makes it possible to implement new control
constructs as Tcl procedures (for example, <em>uplevel</em> could
be used to implement the <em>while</em> construct as a Tcl procedure).</p></div>
-<h3 id="_upvar">upvar</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_upvar">upvar</h3>
<div class="paragraph"><p><tt><strong>upvar</strong> <em>?level? otherVar myVar ?otherVar myVar &#8230;?</em></tt></p></div>
<div class="paragraph"><p>This command arranges for one or more local variables in the current
procedure to refer to variables in an enclosing procedure call or
@@ -5683,7 +6085,9 @@ and it adds two to the value of that variable.
Although <em>add2</em> could have been implemented using <em>uplevel</em>
instead of <em>upvar</em>, <em>upvar</em> makes it simpler for <em>add2</em>
to access the variable in the caller&#8217;s procedure frame.</p></div>
-<h3 id="_while">while</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_while">while</h3>
<div class="paragraph"><p><tt><strong>while</strong> <em>test body</em></tt></p></div>
<div class="paragraph"><p>The <strong>while</strong> command evaluates <strong>test</strong> as an expression
(in the same way that <em>expr</em> evaluates its argument).
@@ -5698,49 +6102,15 @@ commands may be executed inside <strong>body</strong> to cause immediate
termination of the <em>while</em> command.</p></div>
<div class="paragraph"><p>The <em>while</em> command always returns an empty string.</p></div>
</div>
+</div>
+</div>
+<div class="sect1">
<h2 id="_optional_extensions">OPTIONAL-EXTENSIONS</h2>
<div class="sectionbody">
<div class="paragraph"><p>The following extensions may or may not be available depending upon
what options were selected when Jim Tcl was built.</p></div>
-<h3 id="_bio">bio</h3><div style="clear:left"></div>
-<div class="paragraph"><p>The bio command provides a way to read and write binary files
-from within Tcl. Note that since Jim supports binary strings, the
-main use of this command is <em>bio copy</em> to easily copy between file
-descriptors.</p></div>
-<div class="dlist"><dl>
-<dt class="hdlist1">
-<tt><strong>bio read ?-hex?</strong> <em>fd var numbytes</em></tt>
-</dt>
-<dd>
-<p>
- Read bytes from a file descriptor. By default the data is not encoded.
- Using <strong>-hex</strong> encodes the data as ascii hex instead. Returns
- the number of bytes actually read.
-</p>
-</dd>
-<dt class="hdlist1">
-<tt><strong>bio write ?-hex?</strong> <em>fd buf</em></tt>
-</dt>
-<dd>
-<p>
- Write a string to a file descriptor. If <strong>-hex</strong> is specified, the
- string is expected to be in ascii hexx format. Returns the number
- of bytes actually written.
-</p>
-</dd>
-<dt class="hdlist1">
-<tt><strong>bio copy</strong> <em>fromfd tofd ?numbytes?</em></tt>
-</dt>
-<dd>
-<p>
- Copy binary data from the file descriptor <strong>fromfd</strong> to the
- file descriptor <strong>tofd</strong>. If <strong>numbytes</strong> is specified, at most that many
- bytes will be copied. Otherwise copying continues until the end
- of the input file. Returns the number of bytes actually copied.
-</p>
-</dd>
-</dl></div>
-<h3 id="cmd_1">posix: os.fork, os.wait, os.gethostname, os.getids, os.uptime</h3><div style="clear:left"></div>
+<div class="sect2">
+<h3 id="cmd_1">posix: os.fork, os.wait, os.gethostname, os.getids, os.uptime</h3>
<div class="dlist"><dl>
<dt class="hdlist1">
<tt><strong>os.fork</strong></tt>
@@ -5810,11 +6180,15 @@ uid 1000 euid 1000 gid 100 egid 100</tt></pre>
</dd>
</dl></div>
</div>
+</div>
+</div>
+<div class="sect1">
<h2 id="_ansi_i_o_aio_and_eventloop_api">ANSI I/O (aio) and EVENTLOOP API</h2>
<div class="sectionbody">
<div class="paragraph"><p>Jim provides an alternative object-based API for I/O.</p></div>
<div class="paragraph"><p>See <em><a href="#_open">open</a></em> and <em><a href="#_socket">socket</a></em> for commands which return an I/O handle.</p></div>
-<h3 id="_aio">aio</h3><div style="clear:left"></div>
+<div class="sect2">
+<h3 id="_aio">aio</h3>
<div class="dlist"><dl>
<dt class="hdlist1">
<tt>$handle <strong>read ?-nonewline?</strong> <em>?len?</em></tt>
@@ -5841,6 +6215,16 @@ uid 1000 euid 1000 gid 100 egid 100</tt></pre>
</p>
</dd>
<dt class="hdlist1">
+<tt>$handle <strong>copyto</strong> <em>tofd ?size?</em></tt>
+</dt>
+<dd>
+<p>
+ Copy bytes to the file descriptor <strong>tofd</strong>. If <strong>size</strong> is specified, at most
+ that many bytes will be copied. Otherwise copying continues until the end
+ of the input file. Returns the number of bytes actually copied.
+</p>
+</dd>
+<dt class="hdlist1">
<tt>$handle <strong>flush</strong></tt>
</dt>
<dd>
@@ -5940,7 +6324,9 @@ uid 1000 euid 1000 gid 100 egid 100</tt></pre>
</p>
</dd>
</dl></div>
-<h3 id="cmd_2">eventloop: after, vwait, update</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="cmd_2">eventloop: after, vwait, update</h3>
<div class="paragraph"><p>The following commands allow a script to be invoked when the given condition occurs.
If no script is given, returns the current script. If the given script is the empty, the
handler is removed.</p></div>
@@ -6066,7 +6452,9 @@ to prevent infinite errors. (A time event handler is always removed after execut
</p>
</dd>
</dl></div>
-<h3 id="_socket">socket</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_socket">socket</h3>
<div class="paragraph"><p>Various socket types may be created.</p></div>
<div class="dlist"><dl>
<dt class="hdlist1">
@@ -6193,7 +6581,9 @@ $w close</tt></pre>
<div class="content">
<pre><tt>$r readable ...</tt></pre>
</div></div>
-<h3 id="_syslog">syslog</h3><div style="clear:left"></div>
+</div>
+<div class="sect2">
+<h3 id="_syslog">syslog</h3>
<div class="paragraph"><p><tt><strong>syslog</strong> <em>?options? ?priority? message</em></tt></p></div>
<div class="paragraph"><p>This command sends message to system syslog facility with given
priority. Valid priorities are:</p></div>
@@ -6242,6 +6632,9 @@ uucp, local0-local7</tt></pre>
</dd>
</dl></div>
</div>
+</div>
+</div>
+<div class="sect1">
<h2 id="BuiltinVariables">BUILT-IN VARIABLES</h2>
<div class="sectionbody">
<div class="paragraph"><p>The following global variables are created automatically
@@ -6359,6 +6752,8 @@ by the Tcl library.</p></div>
</dd>
</dl></div>
</div>
+</div>
+<div class="sect1">
<h2 id="_licence">LICENCE</h2>
<div class="sectionbody">
<div class="literalblock">
@@ -6406,9 +6801,12 @@ are those of the authors and should not be interpreted as representing
official policies, either expressed or implied, of the Jim Tcl Project.</tt></pre>
</div></div>
</div>
+</div>
+</div>
+<div id="footnotes"><hr /></div>
<div id="footer">
<div id="footer-text">
-Last updated 2010-11-11 10:58:17 EST
+Last updated 2010-11-15 11:22:37 EST
</div>
</div>
</body>