summaryrefslogtreecommitdiff
path: root/ext/tk/lib/tk.rb
diff options
context:
space:
mode:
Diffstat (limited to 'ext/tk/lib/tk.rb')
-rw-r--r--ext/tk/lib/tk.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/ext/tk/lib/tk.rb b/ext/tk/lib/tk.rb
index 9cdd3b918e..e5d1c6f63b 100644
--- a/ext/tk/lib/tk.rb
+++ b/ext/tk/lib/tk.rb
@@ -4289,6 +4289,10 @@ class TkWindow<TkObject
self
end
+ def caret(keys=nil)
+ TkXIM.caret(path, keys)
+ end
+
def destroy
super
children = []
@@ -5400,6 +5404,9 @@ class TkMenu<TkWindow
configure_cmd 'postcommand', cmd
self
end
+ def set_focus
+ tk_call('tk_menuSetFocus', path)
+ end
def tearoffcommand(cmd=Proc.new)
configure_cmd 'tearoffcommand', cmd
self