diff options
author | fvogel <fvogelnew1@free.fr> | 2020-05-08 16:04:37 (GMT) |
---|---|---|
committer | fvogel <fvogelnew1@free.fr> | 2020-05-08 16:04:37 (GMT) |
commit | 4967e9c77f3209c4b99b21208c55d527a5a74799 (patch) | |
tree | f82009c44b410dae1cd36ca8fa425b1b923fcc6a | |
parent | 30487c02821b30ae9136fd2f83ad69418130aa9c (diff) | |
download | tk-4967e9c77f3209c4b99b21208c55d527a5a74799.zip tk-4967e9c77f3209c4b99b21208c55d527a5a74799.tar.gz tk-4967e9c77f3209c4b99b21208c55d527a5a74799.tar.bz2 |
A few cosmetic changes
-rw-r--r-- | doc/ttk_treeview.n | 11 | ||||
-rw-r--r-- | generic/ttk/ttkTreeview.c | 8 |
2 files changed, 9 insertions, 10 deletions
diff --git a/doc/ttk_treeview.n b/doc/ttk_treeview.n index aa7b87f..a126dd2 100644 --- a/doc/ttk_treeview.n +++ b/doc/ttk_treeview.n @@ -344,6 +344,11 @@ Modify or query the widget state; see \fIttk::widget(n)\fR. \fIpathName \fBtag \fIargs...\fR .RS .TP +\fIpathName \fBtag add \fItag items\fR +Adds the specified \fItag\fR to each of the listed \fIitems\fR. +If \fItag\fR is already present for a particular item, +then the \fB\-tags\fR for that item are unchanged. +.TP \fIpathName \fBtag bind \fItagName \fR?\fIsequence\fR? ?\fIscript\fR? Add a Tk binding script for the event sequence \fIsequence\fR to the tag \fItagName\fR. When an X event is delivered to an item, @@ -373,7 +378,6 @@ returns a dictionary of the option settings for \fItagName\fR. See \fBTAG OPTIONS\fR for the list of available options. .TP \fIpathName \fBtag delete \fItagName\fR -. Deletes all tag information for the \fItagName\fR argument. The command removes the tag from all items in the widget and also deletes any other information associated with the tag, such as bindings and display @@ -388,11 +392,6 @@ the specified tag. \fIpathName \fBtag names\fR Returns a list of all tags used by the widget. .TP -\fIpathName \fBtag add \fItag items\fR -Adds the specified \fItag\fR to each of the listed \fIitems\fR. -If \fItag\fR is already present for a particular item, -then the \fB\-tags\fR for that item are unchanged. -.TP \fIpathName \fBtag remove \fItag\fR ?\fIitems\fR? Removes the specified \fItag\fR from each of the listed \fIitems\fR. If \fIitems\fR is omitted, removes \fItag\fR from each item in the tree. diff --git a/generic/ttk/ttkTreeview.c b/generic/ttk/ttkTreeview.c index 05c58f1..559f1b3 100644 --- a/generic/ttk/ttkTreeview.c +++ b/generic/ttk/ttkTreeview.c @@ -2963,7 +2963,7 @@ static int TreeviewSelectionCommand( if (objc == 2) { Tcl_Obj *result = Tcl_NewListObj(0,0); - for (item = tv->tree.root->children; item; item=NextPreorder(item)) { + for (item = tv->tree.root->children; item; item = NextPreorder(item)) { if (item->state & TTK_STATE_SELECTED) Tcl_ListObjAppendElement(NULL, result, ItemID(tv, item)); } @@ -2989,7 +2989,7 @@ static int TreeviewSelectionCommand( switch (selop) { case SELECTION_SET: - for (item=tv->tree.root; item; item=NextPreorder(item)) { + for (item=tv->tree.root; item; item = NextPreorder(item)) { item->state &= ~TTK_STATE_SELECTED; } /*FALLTHRU*/ @@ -3124,7 +3124,7 @@ static int TreeviewTagDeleteCommand( /* remove the tag from all items */ while (item) { RemoveTag(item, tag); - item=NextPreorder(item); + item = NextPreorder(item); } /* then remove the tag from the tag table */ Ttk_DeleteTagFromTable(tagTable, tag); @@ -3262,7 +3262,7 @@ static int TreeviewTagRemoveCommand( TreeItem *item = tv->tree.root; while (item) { RemoveTag(item, tag); - item=NextPreorder(item); + item = NextPreorder(item); } } |