Ruby 使用 TkListbox

清华大佬耗费三个月吐血整理的几百G的资源,免费分享!....>>>

require 'tk'
top = TkRoot.new {title "Label and Entry Widget"}

list1 = TkListbox.new(top)
list1.insert(1," Python")
list1.insert(2," Perl")
list1.insert(3," C")
list1.insert(4," PHP")
list1.insert(5," JSP")
list1.insert(6," Ruby")
list1.pack()
Tk.mainloop