Displaying 3 results from an estimated 3 matches for "set_item_bold".
2006 Dec 01
0
TreeCtrl#traverse patch
...t accepts a block and yields each TreeItemId in turn
into it:
# print all the labels in the tree:
tree.traverse { | item | puts tree.get_item_text(item) }
It can optionally accept the id of a branch to start at
# embolden all items at branch and below:
tree.traverse(branch) { | item | puts tree.set_item_bold(item) }
Wanted to check if anyone sees any probs or thinks this is a bad idea.
It''s kind of sugary, but would be a lot slower and messier in Ruby, plus
we already had the recursive C++ code written to do the GC marking. One
use case is finding the item whose item data is a particular r...
2007 Jan 06
0
[835] trunk/wxruby2/doc/textile: Updated documentation about TreeItemId
..., then the id does not refer to a valid
+item. This is most useful when testing whether any item has been clicked
+as part of a "TreeEvent":treeevent.html handler; for example:
+
+ def on_tree_clicked(event)
+ if event.get_item.nonzero?
+ # .. an item was clicked, make it bold
+ set_item_bold(event.get_item)
+ else
+ # otherwise the click didn''t happen over an item
+ ...
+
+h3. Associating Ruby objects with TreeCtrl items
+
</ins><span class="cx"> TreeCtrls can be linked to non-GUI application objects by using the
</span><span class="...
2007 Apr 13
0
[956] branches/wxruby2/wxwidgets_282: Additions to TreeCtrl API 2.6->2.8
...passed in with the currently selected items. This
</span><span class="cx"> function can be called only if the control has the TR_MULTIPLE style.
</span><span class="lines">@@ -767,6 +814,13 @@
</span><span class="cx"> See also: "set_item_bold":#TreeCtrl_setitembold
</span><span class="cx">
</span><span class="cx">
</span><ins>+h3(#TreeCtrl_isempty). TreeCtrl#is_empty
+
+ Boolean *is_empty*()
+
+Returns if the control is empty (i.e. has no items, even no root one).
+
+
</...