【お知らせ】この部分は英語原文のみでの提供となります。何卒ご了承ください。
2.1.26.52 tree_hide_empty_nodes
Contents
Description
Walk all tree nides and set all empty ones to be hidden
Syntax
int tree_hide_empty_nodes( TreeNode tr, bool bRecursive = true, bool bRemoveShowAttrib = true )
Parameters
- tr
- [input]the tree node to walk
- bRecursive
- [input]true will walk the entire tree, false will only the current tree node
- bRemoveShowAttrib
- [input]true will remove the attribute STR_SHOW_ATTRIB if not empty, false not remove
Return
number of the empty tree nodes
Examples
EX1
#include <GetNBox.h> void tree_hide_empty_nodes_ex1() { GETN_TREE(myTree) GETN_NUM(count, "Count", 100) GETN_ID(2) GETN_CHECK(check, "Print?", 0) GETN_ID(4) GETN_STR(printed, "Printed Document", "") GETN_ID(8) GetNBox(myTree); // myTree.printed is shown int nn = tree_hide_empty_nodes(myTree); GetNBox(myTree); // myTree.printed is hidden }
Remark
See Also
Header to Include
origin.h