summaryrefslogtreecommitdiff
path: root/ext/tk
diff options
context:
space:
mode:
Diffstat (limited to 'ext/tk')
-rw-r--r--ext/tk/lib/tk.rb3
-rw-r--r--ext/tk/lib/tktext.rb4
-rw-r--r--ext/tk/tkutil.c2
3 files changed, 5 insertions, 4 deletions
diff --git a/ext/tk/lib/tk.rb b/ext/tk/lib/tk.rb
index 2aa49879fd..dae2aeb0d8 100644
--- a/ext/tk/lib/tk.rb
+++ b/ext/tk/lib/tk.rb
@@ -233,6 +233,7 @@ module TkComm
return format("rb_out %s", id);
end
def uninstall_cmd(id)
+ id = $1 if /rb_out (c\d+)/
Tk_CMDTBL[id] = nil
end
private :install_cmd, :uninstall_cmd
@@ -2116,7 +2117,7 @@ class TkScrollbar<TkWindow
end
def get
- ary1 = tk_send('get', path).split
+ ary1 = tk_send('get').split
ary2 = []
for i in ary1
ary2.push number(i)
diff --git a/ext/tk/lib/tktext.rb b/ext/tk/lib/tktext.rb
index 281435ef69..3dde30d60d 100644
--- a/ext/tk/lib/tktext.rb
+++ b/ext/tk/lib/tktext.rb
@@ -272,7 +272,7 @@ class TkText<TkTextWin
end
def tag_cget(tag, key)
- tk_tcl2ruby tk_call @t.path, 'tag', 'cget', tag, "-#{key}"
+ tk_tcl2ruby tk_call @path, 'tag', 'cget', tag, "-#{key}"
end
def tag_configure(tag, key, val=None)
@@ -289,7 +289,7 @@ class TkText<TkTextWin
|| key == 'latinfont' || key == 'asciifont' )
tagfont_configure({key=>val})
else
- tk_call 'tag', 'configure', tag, "-#{key}", val
+ tk_send 'tag', 'configure', tag, "-#{key}", val
end
end
end
diff --git a/ext/tk/tkutil.c b/ext/tk/tkutil.c
index e93733bb67..990c81d724 100644
--- a/ext/tk/tkutil.c
+++ b/ext/tk/tkutil.c
@@ -29,7 +29,7 @@ tk_s_new(argc, argv, class)
{
VALUE obj = rb_obj_alloc(class);
- rb_funcall2(obj, rb_intern("initialize"), argc, argv);
+ rb_obj_call_init(obj, argc, argv);
if (rb_iterator_p()) rb_obj_instance_eval(0, 0, obj);
return obj;
}