summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authortreectrl <treectrl>2006-11-30 03:29:44 (GMT)
committertreectrl <treectrl>2006-11-30 03:29:44 (GMT)
commitd06d46b9d793a14d301e135e6fd76a0c77bbb7b5 (patch)
tree4541a1618e4849901c37e986a011d8301e69c2f2 /doc
parent6137f8797b9b058e0cf9b93cf6b8708e42aeacde (diff)
downloadtktreectrl-d06d46b9d793a14d301e135e6fd76a0c77bbb7b5.zip
tktreectrl-d06d46b9d793a14d301e135e6fd76a0c77bbb7b5.tar.gz
tktreectrl-d06d46b9d793a14d301e135e6fd76a0c77bbb7b5.tar.bz2
The item option -button may now be "auto" in which case a button is drawn only when the item has a child whose -visible option is true.
Diffstat (limited to 'doc')
-rw-r--r--doc/treectrl.html34
-rw-r--r--doc/treectrl.man28
-rw-r--r--doc/treectrl.n44
3 files changed, 66 insertions, 40 deletions
diff --git a/doc/treectrl.html b/doc/treectrl.html
index b69a793..8b94ca5 100644
--- a/doc/treectrl.html
+++ b/doc/treectrl.html
@@ -1,10 +1,10 @@
-<! -- Copyright (c) 2002-2003 Christian Krone. -- -- See the file &quot;license.terms&quot; for information on usage and redistribution -- of this file, and for a DISCLAIMER OF ALL WARRANTIES. -- -- $Id: treectrl.html,v 1.43 2006/11/21 02:09:35 treectrl Exp $
+<! -- Copyright (c) 2002-2003 Christian Krone. -- -- See the file &quot;license.terms&quot; for information on usage and redistribution -- of this file, and for a DISCLAIMER OF ALL WARRANTIES. -- -- $Id: treectrl.html,v 1.44 2006/11/30 03:30:12 treectrl Exp $
--><html><head>
<title>treectrl - Tk Commands </title>
</head>
<! -- Generated from file 'doc/treectrl.man' by tcllib/doctools with format 'html'
-->
-<! -- CVS: $Id: treectrl.html,v 1.43 2006/11/21 02:09:35 treectrl Exp $ treectrl.n
+<! -- CVS: $Id: treectrl.html,v 1.44 2006/11/30 03:30:12 treectrl Exp $ treectrl.n
-->
<body>
@@ -1526,7 +1526,7 @@ the meaning of each option):
<br><br>
<dl>
-<dt><strong><strong>-button</strong></strong> <i class='arg'>boolean</i><dd>
+<dt><strong><strong>-button</strong></strong> <i class='arg'>boolean|auto</i><dd>
<dt><strong><strong>-height</strong></strong> <i class='arg'>height</i><dd>
<dt><strong><strong>-tags</strong></strong> <i class='arg'>tagList</i><dd>
<dt><strong><strong>-visible</strong></strong> <i class='arg'>boolean</i><dd>
@@ -1556,16 +1556,26 @@ The following options are supported by this command:
<br><br>
<dl>
-<dt><strong><strong>-button</strong></strong> <i class='arg'>boolean</i><dd>
-<i class='arg'>Boolean</i> must have one of the forms accepted by <strong>Tcl_GetBoolean</strong>. It
-indicates whether or not an expand/collapse button should be drawn next to this
-item, typically to indicate the item has children. The button will only be
-displayed if:
-a) the column specified by the treectrl option <strong>-treecolumn</strong> is visible;
-and b) the treectrl option <strong>-showbuttons</strong> is true;
-and c) for the root item, the treectrl option <strong>-showrootbutton</strong> is true.
-
+<dt><strong><strong>-button</strong></strong> <i class='arg'>boolean|auto</i><dd>
+The value of this option must have one of the forms accepted by <strong>Tcl_GetBoolean</strong>
+or be the word <strong>auto</strong> (or any abbreviation of it). It indicates whether or not an expand/collapse
+button should be drawn next to the item, typically to indicate that the item has
+children.
+If the value of this option is <strong>auto</strong>, then a button is displayed next to the
+item whenever the item has any children whose item option <strong>-visible</strong> is true.
+The button will only be displayed if:
<br><br>
+<ol>
+<li>
+the column specified by the treectrl option <strong>-treecolumn</strong> is visible, and
+<br><br>
+<li>
+the treectrl option <strong>-showbuttons</strong> is true, and
+<br><br>
+<li>
+for the root item, the treectrl option <strong>-showrootbutton</strong> is true.
+</ol>
+
<dt><strong><strong>-count</strong></strong> <i class='arg'>numItems</i><dd>
Specifies the number of items to create. Must be &gt;= 0. Defaults to 1.
diff --git a/doc/treectrl.man b/doc/treectrl.man
index 957a129..f2cd1a6 100644
--- a/doc/treectrl.man
+++ b/doc/treectrl.man
@@ -3,7 +3,7 @@
See the file "license.terms" for information on usage and redistribution
of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- $Id: treectrl.man,v 1.44 2006/11/21 02:09:35 treectrl Exp $}
+ $Id: treectrl.man,v 1.45 2006/11/30 03:30:13 treectrl Exp $}
][manpage_begin treectrl n 2.2]
[moddesc {Tk Commands}]
[titledesc {Create and manipulate hierarchical multicolumn widgets}]
@@ -1032,7 +1032,7 @@ the meaning of each option):
[list_begin opt]
-[opt_def [option -button] [arg boolean]]
+[opt_def [option -button] [arg boolean|auto]]
[opt_def [option -height] [arg height]]
[opt_def [option -tags] [arg tagList]]
[opt_def [option -visible] [arg boolean]]
@@ -1058,14 +1058,22 @@ The following options are supported by this command:
[list_begin opt]
-[opt_def [option -button] [arg boolean]]
-[arg Boolean] must have one of the forms accepted by [fun Tcl_GetBoolean]. It
-indicates whether or not an expand/collapse button should be drawn next to this
-item, typically to indicate the item has children. The button will only be
-displayed if:
-a) the column specified by the treectrl option [option -treecolumn] is visible;
-and b) the treectrl option [option -showbuttons] is true;
-and c) for the root item, the treectrl option [option -showrootbutton] is true.
+[opt_def [option -button] [arg boolean|auto]]
+The value of this option must have one of the forms accepted by [fun Tcl_GetBoolean]
+or be the word [const auto] (or any abbreviation of it). It indicates whether or not an expand/collapse
+button should be drawn next to the item, typically to indicate that the item has
+children.
+If the value of this option is [const auto], then a button is displayed next to the
+item whenever the item has any children whose item option [option -visible] is true.
+The button will only be displayed if:
+[list_begin enum]
+[enum]
+the column specified by the treectrl option [option -treecolumn] is visible, and
+[enum]
+the treectrl option [option -showbuttons] is true, and
+[enum]
+for the root item, the treectrl option [option -showrootbutton] is true.
+[list_end]
[opt_def [option -count] [arg numItems]]
Specifies the number of items to create. Must be >= 0. Defaults to 1.
diff --git a/doc/treectrl.n b/doc/treectrl.n
index cc6cf3e..efdae6a 100644
--- a/doc/treectrl.n
+++ b/doc/treectrl.n
@@ -6,13 +6,13 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
-'\" $Id: treectrl.n,v 1.60 2006/11/21 02:09:35 treectrl Exp $
+'\" $Id: treectrl.n,v 1.61 2006/11/30 03:30:20 treectrl Exp $
.so man.macros
.TH "treectrl" n 2.2 treectrl "Tk Commands"
.BS
-.SH "NAME"
+.SH NAME
treectrl \- Create and manipulate hierarchical multicolumn widgets
-.SH "SYNOPSIS"
+.SH SYNOPSIS
package require \fBtreectrl 2.2\fR
.sp
\fBtreectrl\fR \fIpathName\fR ?\fIoptions\fR?
@@ -354,7 +354,7 @@ package require \fBtreectrl 2.2\fR
\fIpathName\fR \fByview scroll\fR \fInumber\fR \fIwhat\fR
.sp
.BE
-.SH "DESCRIPTION"
+.SH DESCRIPTION
.TP
\fBtreectrl\fR \fIpathName\fR ?\fIoptions\fR?
.PP
@@ -1632,7 +1632,7 @@ The following options are supported by this command (see \fBitem create\fR for
the meaning of each option):
.RS
.TP
-\fB\fB-button\fR\fR \fIboolean\fR
+\fB\fB-button\fR\fR \fIboolean|auto\fR
.TP
\fB\fB-height\fR\fR \fIheight\fR
.TP
@@ -1659,14 +1659,22 @@ the state \fBfocus\fR is also set.
The following options are supported by this command:
.RS
.TP
-\fB\fB-button\fR\fR \fIboolean\fR
-\fIBoolean\fR must have one of the forms accepted by \fBTcl_GetBoolean\fR. It
-indicates whether or not an expand/collapse button should be drawn next to this
-item, typically to indicate the item has children. The button will only be
-displayed if:
-a) the column specified by the treectrl option \fB-treecolumn\fR is visible;
-and b) the treectrl option \fB-showbuttons\fR is true;
-and c) for the root item, the treectrl option \fB-showrootbutton\fR is true.
+\fB\fB-button\fR\fR \fIboolean|auto\fR
+The value of this option must have one of the forms accepted by \fBTcl_GetBoolean\fR
+or be the word \fBauto\fR (or any abbreviation of it). It indicates whether or not an expand/collapse
+button should be drawn next to the item, typically to indicate that the item has
+children.
+If the value of this option is \fBauto\fR, then a button is displayed next to the
+item whenever the item has any children whose item option \fB-visible\fR is true.
+The button will only be displayed if:
+.RS
+.IP [1]
+the column specified by the treectrl option \fB-treecolumn\fR is visible, and
+.IP [2]
+the treectrl option \fB-showbuttons\fR is true, and
+.IP [3]
+for the root item, the treectrl option \fB-showrootbutton\fR is true.
+.RE
.TP
\fB\fB-count\fR\fR \fInumItems\fR
Specifies the number of items to create. Must be >= 0. Defaults to 1.
@@ -2766,7 +2774,7 @@ visible; if it is positive then lower information
becomes visible.
A \fB<Scroll-y>\fR event is generated.
.RE
-.SH "COLUMNS"
+.SH COLUMNS
A treectrl widget is capable of displaying multiple columns next to each
other.
An item can be considered as a row, which reaches over all columns.
@@ -3072,7 +3080,7 @@ TRUE are considered.
\fB!visible\fR
When this qualifier is given, only columns whose \fB-visible\fR option is
FALSE are considered.
-.SH "STATES"
+.SH STATES
For every item a set of boolean states is managed. These states play an
integral role in the appearance of each item.
The following states are predefined for every item:
@@ -3149,7 +3157,7 @@ In the example above, the \fBrect\fR element is filled with blue when the treect
has the focus and the item is selected. If the treectrl does not have the focus, the
example specifies that gray should be used for selected items. Also note that if the
item is not selected, no color is specified for the -fill option.
-.SH "ELEMENTS"
+.SH ELEMENTS
Elements are the smallest building blocks
which are handled by a treectrl widget.
One or more elements together can be combined to a style,
@@ -3889,7 +3897,7 @@ the Return key toggles the active item.
The mousewheel scrolls the view of the widget four lines up or down
depending on the direction, the wheel was turned.
The active cursor or the selection is not affected.
-.SH "EXAMPLES"
+.SH EXAMPLES
Get the unique identifier for the leftmost visible column:
.nf
@@ -3939,5 +3947,5 @@ $T notify bind MyTag <ColumnDrag-receive> {
.fi
.SH "SEE ALSO"
bind(n), bitmap(n), image(n), listbox(n), options(n)
-.SH "KEYWORDS"
+.SH KEYWORDS
tree, widget \ No newline at end of file