# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 1976 def self.id2obj(tree, id) tpath = tree.path Tk::TreeCtrl::Item::TreeCtrlItemID_TBL.mutex.synchronize{ if Tk::TreeCtrl::Item::TreeCtrlItemID_TBL[tpath] Tk::TreeCtrl::Item::TreeCtrlItemID_TBL[tpath][id]? Tk::TreeCtrl::Item::TreeCtrlItemID_TBL[tpath][id] : id else id end } end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 1988 def initialize(parent, keys={}) @tree = parent @tpath = parent.path @path = @id = @tree.item_create(keys) Tk::TreeCtrl::Item::TreeCtrlItemID_TBL.mutex.synchronize{ Tk::TreeCtrl::Item::TreeCtrlItemID_TBL[@tpath] ||= {} Tk::TreeCtrl::Item::TreeCtrlItemID_TBL[@tpath][@id] = self } end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2007 def ancestors @tree.item_ancestors(@id) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2011 def bbox(*args) @tree.item_bbox(@id, *args) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2037 def cget(opt) @tree.item_cget(@id, opt) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2040 def cget_strict(opt) @tree.item_cget_strict(@id, opt) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2034 def cget_tkstring(opt) @tree.item_cget_tkstring(@id, opt) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2015 def children @tree.item_children(@id) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2019 def collapse @tree.item_collapse(@id) self end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2024 def collapse_recurse @tree.item_collapse_recurse(@id) self end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2029 def complex(*args) @tree.item_complex(@id, *args) self end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2048 def configinfo(*args) @tree.item_configinfo(@id, *args) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2044 def configure(*args) @tree.item_configure(@id, *args) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2052 def current_configinfo(*args) @tree.current_item_configinfo(@id, *args) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2091 def current_element_configinfo(*args) @tree.current_item_element_configinfo(@id, *args) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2056 def delete @tree.item_delete(@id) self end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2069 def element_actual(column, elem, key) @tree.item_element_actual(@id, column, elem, key) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2079 def element_cget_strict(opt) @tree.item_element_cget_strict(@id, opt) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2073 def element_cget_tkstring(opt) @tree.item_element_cget(@id, opt) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2087 def element_configinfo(*args) @tree.item_element_configinfo(@id, *args) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2083 def element_configure(*args) @tree.item_element_configure(@id, *args) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2061 def element_dump @tree.item_dump(@id) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2065 def element_dump_hash @tree.item_dump_hash(@id) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2095 def expand @tree.item_expand(@id) self end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2100 def expand_recurse @tree.item_expand_recurse(@id) self end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2105 def firstchild(child=nil) if child @tree.item_firstchild(@id, child) self else @tree.item_firstchild(@id) end end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2130 def index @tree.item_index(@id) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2134 def isancestor(des) @tree.item_isancestor(@id, des) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2142 def isopen @tree.item_isopen(@id) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2241 def item_text(column, txt=nil, *args) if args.empty? if txt @tree.item_text(@id, column, txt) self else @tree.item_text(@id, column) end else @tree.item_text(@id, column, txt, *args) self end end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2152 def lastchild(child=nil) if child @tree.item_lastchild(@id, child) self else @tree.item_lastchild(@id) end end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2162 def nextsibling(nxt=nil) if nxt @tree.item_nextsibling(@id, nxt) self else @tree.item_nextsibling(@id) end end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2172 def numchildren @tree.item_numchildren(@id) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2178 def parent_index @tree.item_parent(@id) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2182 def prevsibling(nxt=nil) if nxt @tree.item_prevsibling(@id, nxt) self else @tree.item_prevsibling(@id) end end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2192 def remove @tree.item_remove(@id) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2196 def rnc @tree.item_rnc(@id) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2200 def sort(*opts) @tree.item_sort(@id, *opts) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2203 def sort_not_really(*opts) @tree.item_sort_not_really(@id, *opts) self end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2208 def state_forcolumn(column, *args) @tree.item_state_forcolumn(@id, column, *args) self end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2214 def state_get(*args) @tree.item_state_get(@id, *args) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2218 def state_set(*args) @tree.item_state_set(@id, *args) self end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2223 def style_elements(column) @tree.item_style_elements(@id, column) end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2227 def style_map(column, style, map) @tree.item_style_map(@id, column, style, map) self end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2232 def style_set(column=nil, *args) if args.empty? @tree.item_style_set(@id, column) else @tree.item_style_set(@id, column, *args) self end end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2003 def to_s @id.to_s.dup end
# File tk/lib/tkextlib/treectrl/tktreectrl.rb, line 2255 def toggle @tree.item_toggle(@id) self end
Commenting is here to help enhance the documentation. For example, code samples, or clarification of the documentation.
If you have questions about Ruby or the documentation, please post to one of the Ruby mailing lists. You will get better, faster, help that way.
If you wish to post a correction of the docs, please do so, but also file bug report so that it can be corrected for the next release. Thank you.
If you want to help improve the Ruby documentation, please visit Documenting-ruby.org.