Method: TkTextListBox#initialize
- Defined in:
- ext/ae-editor/ae-editor.rb
#initialize(parent = nil, keys = {}) ⇒ TkTextListBox
Returns a new instance of TkTextListBox.
530 531 532 533 534 535 536 537 538 539 540 |
# File 'ext/ae-editor/ae-editor.rb', line 530 def initialize(parent=nil, keys={}) super(parent, keys) wrap 'none' tag_configure('selected','background' =>'#bbd9b1','borderwidth'=>1, 'relief'=>'raised') tag_configure('class', 'foreground' => '#3398cb') @count = 0 @selected = -1 self.bind_append('KeyPress'){|e| key_press(e)} self.bind_append('KeyRelease'){|e| key_release(e)} self.bind_append("ButtonPress-1", proc{|x,y| (x,y)}, "%x %y") end |