# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 75 def add(keys={}) window(tk_call(@path, 'add', *hash_kv(keys))) end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 83 def child_site(idx) window(tk_call(@path, 'childsite', index(idx))) end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 79 def child_site_list list(tk_call(@path, 'childsite')) end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 87 def delete(idx1, idx2=nil) if idx2 tk_call(@path, 'delete', index(idx1), index(idx2)) else tk_call(@path, 'delete', index(idx1)) end self end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 96 def index(idx) #number(tk_call(@path, 'index', tagid(idx))) @tabset.index(tagid(idx)) end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 101 def insert(idx, keys={}) window(tk_call(@path, 'insert', index(idx), *hash_kv(keys))) end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 105 def next tk_call(@path, 'next') self end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 110 def prev tk_call(@path, 'prev') self end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 125 def scrollcommand(cmd=Proc.new) configure_cmd 'scrollcommand', cmd self end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 115 def select(idx) tk_call(@path, 'select', index(idx)) self end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 120 def show_tab(idx) @tabset.show_tab(idx) self end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 40 def tagid(tagOrId) if tagOrId.kind_of?(Tk::Itk::Component) tagOrId.name else #_get_eval_string(tagOrId) tagOrId end end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 154 def view(*index) if index.size == 0 idx = num_or_str(tk_send_without_enc('view')) if idx.kind_of?(Fixnum) && idx < 0 nil else idx end else tk_send_without_enc('view', *index) self end end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 170 def view_moveto(*index) view('moveto', *index) end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 175 def view_scroll(index, what='pages') view('scroll', index, what) end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 132 def xscrollbar(bar=nil) if bar @scrollbar = bar @scrollbar.orient 'horizontal' self.scrollcommand {|*arg| @scrollbar.set(*arg)} @scrollbar.command {|*arg| self.xview(*arg)} Tk.update # avoid scrollbar trouble end @scrollbar end
# File tk/lib/tkextlib/iwidgets/tabnotebook.rb, line 142 def yscrollbar(bar=nil) if bar @scrollbar = bar @scrollbar.orient 'vertical' self.scrollcommand {|*arg| @scrollbar.set(*arg)} @scrollbar.command {|*arg| self.yview(*arg)} Tk.update # avoid scrollbar trouble end @scrollbar 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.