beetlebug▾
/

ttk::treeview move

Moves an item to a new parent or a new place.

PATHNAME move ITEM PARENT INDEX

Description

Makes ITEM a child of PARENT before the child at INDEX, a number or end. The children of ITEM move with it. A detached item comes back into the tree.

Returns

An empty string.

Examples

% ttk::treeview .ttvmo
> foreach id {a b c} {.ttvmo insert {} end -id $id}
> .ttvmo move c {} 0
> .ttvmo children {}
c a b

Errors

% ttk::treeview .ttvmo2; .ttvmo2 insert {} end -id a; .ttvmo2 move a nosuch 0
Item nosuch not found
-errorcode NONE

Facts

Capability
None.
Tcl release
Tcl 9.1 and 8.6.
Since
ztk 1.0.0-beta.1

See also