Debian Codegraph @

html/Blt_TreeDeleteNode.html

raw symbols SCIP
1
2 <!-- manual page source format generated by PolyglotMan v3.0.9, -->
3 <!-- available via anonymous ftp from ftp.cs.berkeley.edu:/ucb/people/phelps/tcltk/rman.tar.Z -->
4
5 <HTML>
6 <HEAD>
7 <TITLE>Blt_TreeDeleteNode(3) manual page</TITLE>
8 </HEAD>
9 <BODY bgcolor=white>
10 <A HREF="#toc">Table of Contents</A><P>
11
12 <H2><A NAME="sect0" HREF="#toc0">Name</A></H2>
13 Blt_TreeDeleteNode - Deletes a node
14 and its descendants.
15 <H2><A NAME="sect1" HREF="#toc1">Synopsis</A></H2>
16 <BR>
17 <PRE>#include &lt;bltTree.h&gt;
18
19 Blt_TreeNode
20 Blt_TreeDeleteNode(tree, node)
21 </PRE>
22 <H2><A NAME="sect2" HREF="#toc2">Arguments</A></H2>
23 <P>
24 Blt_Tree <I>tree</I><tt> </tt>&nbsp;<tt> </tt>&nbsp;(in)<BR>
25 <tt> </tt>&nbsp;<tt> </tt>&nbsp;Tree containing the node. <P>
26 Blt_TreeNode <I>node</I><tt> </tt>&nbsp;<tt> </tt>&nbsp;(in)<BR>
27 <tt> </tt>&nbsp;<tt> </tt>&nbsp;Node to be deleted.
28 <H2><A NAME="sect3" HREF="#toc3">Description</A></H2>
29 This procedure deletes a given node and all
30 it descendants from a tree data object. <P>
31 The arguments are as follows:
32
33 <DL>
34
35 <DT><I>tree</I> </DT>
36 <DD>The tree containing the parent node. </DD>
37
38 <DT><I>node</I> </DT>
39 <DD>Node to be deleted. The node
40 and its descendant nodes are deleted. Each node's data values are deleted
41 also. The reference count of the Tcl_Obj is decremented. </DD>
42 </DL>
43 <P>
44 Since all tree
45 objects must contain at least a root node, the root node itself can't be
46 deleted unless the tree is released and destroyed. Therefore you can clear
47 a tree by deleting its root, but the root node will remain until the tree
48 is destroyed.
49 <H2><A NAME="sect4" HREF="#toc4">Returns</A></H2>
50 Always returns TCL_OK. Errors generated in a notification
51 callbacks are backgrounded (see <B>Tcl_TreeCreateNotifyHandler</B>).
52 <H2><A NAME="sect5" HREF="#toc5">Example</A></H2>
53 The
54 following example deletes the root node. <BR>
55 <CODE>Blt_TreeNode root;<BR>
56 <P>
57 root = Blt_TreeRootNode(token);<BR>
58 Blt_TreeDeleteNode(token, root);<BR>
59
60 <H2><A NAME="sect6" HREF="#toc6"></CODE>Notifications</A></H2>
61 <B>Blt_TreeDeleteNode</B> can trigger tree notify events. You can
62 be notified whenever a node is deleted by using the <B>Blt_TreeCreateNotifyHandler</B>.
63 A callback routine is registered that will be automatically invoked whenever
64 a node is deleted via <B>Blt_TreeDeleteNode</B> to the tree.
65 <H2><A NAME="sect7" HREF="#toc7">Keywords</A></H2>
66 tree, token
67 <P>
68
69 <HR><P>
70 <A NAME="toc"><B>Table of Contents</B></A><P>
71 <UL>
72 <LI><A NAME="toc0" HREF="#sect0">Name</A></LI>
73 <LI><A NAME="toc1" HREF="#sect1">Synopsis</A></LI>
74 <LI><A NAME="toc2" HREF="#sect2">Arguments</A></LI>
75 <LI><A NAME="toc3" HREF="#sect3">Description</A></LI>
76 <LI><A NAME="toc4" HREF="#sect4">Returns</A></LI>
77 <LI><A NAME="toc5" HREF="#sect5">Example</A></LI>
78 <LI><A NAME="toc6" HREF="#sect6">Notifications</A></LI>
79 <LI><A NAME="toc7" HREF="#sect7">Keywords</A></LI>
80 </UL>
81 </BODY></HTML>