diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-03-06 03:56:38 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-03-06 03:56:38 +0000 |
commit | 287a34ae0dfc23e4158f67cb7783d239f202c368 (patch) | |
tree | 5e35d5b41aae961b37cf6632f60c42f51c7aa775 /ext/tk/sample/tkoptdb-safeTk.rb | |
parent | 9b52ae2e6491bb5d6c59e1799449f6268baf6f89 (diff) | |
download | ruby-287a34ae0dfc23e4158f67cb7783d239f202c368.tar.gz |
* {ext,lib,test}/**/*.rb: removed trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22784 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/tk/sample/tkoptdb-safeTk.rb')
-rw-r--r-- | ext/tk/sample/tkoptdb-safeTk.rb | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/ext/tk/sample/tkoptdb-safeTk.rb b/ext/tk/sample/tkoptdb-safeTk.rb index a06098323f..3972577b0f 100644 --- a/ext/tk/sample/tkoptdb-safeTk.rb +++ b/ext/tk/sample/tkoptdb-safeTk.rb @@ -18,19 +18,19 @@ EOM if ENV['LANG'] =~ /^ja/ # read Japanese resource - ent = TkOptionDB.read_entries(File.expand_path('resource.ja', + ent = TkOptionDB.read_entries(File.expand_path('resource.ja', File.dirname(__FILE__)), 'euc-jp') else # read English resource - ent = TkOptionDB.read_entries(File.expand_path('resource.en', + ent = TkOptionDB.read_entries(File.expand_path('resource.en', File.dirname(__FILE__))) end file = File.expand_path('tkoptdb.rb', File.dirname(__FILE__)) ip = MultiTkIp.new_safeTk{ - # When a block is given to 'new_safeTk' method, + # When a block is given to 'new_safeTk' method, # the block is evaluated on $SAFE==4. ent.each{|pat, val| Tk.tk_call('option', 'add', pat, val)} } @@ -38,22 +38,22 @@ ip = MultiTkIp.new_safeTk{ print "ip.eval_proc{$SAFE} ==> ", ip.eval_proc{$SAFE}, "\n" print "\ncall 'ip.wait_on_mainloop = false'\n" -print "If 'ip.wait_on_mainloop? == true', ", - "when 'mainloop' is called on 'ip.eval_proc', ", - "'ip.eval_proc' does't return while the root window exists.\n", - "If you want to avoid that, set wait_on_mainloop to false. ", - "Then the mainloop in the eval_proc returns soon ", - "and the following steps are evaluated. \n", - "If you hate the both of them, use 'ip.bg_eval_proc' or ", +print "If 'ip.wait_on_mainloop? == true', ", + "when 'mainloop' is called on 'ip.eval_proc', ", + "'ip.eval_proc' does't return while the root window exists.\n", + "If you want to avoid that, set wait_on_mainloop to false. ", + "Then the mainloop in the eval_proc returns soon ", + "and the following steps are evaluated. \n", + "If you hate the both of them, use 'ip.bg_eval_proc' or ", "wrap 'ip.eval_proc' by a thread.\n" ip.wait_on_mainloop = false ret = ip.eval_proc{ - # When a block is given to 'eval_proc' method, + # When a block is given to 'eval_proc' method, # the block is evaluated on the IP's current safe level. - # So, the followings raises an exception. - # An Exception object of the exception is returned as a + # So, the followings raises an exception. + # An Exception object of the exception is returned as a # return value of this method. load file @@ -64,7 +64,7 @@ print "If a proc object is given, the proc is evaluated on the safe-level which safe0_cmd = Proc.new{ print 'safe0_cmd safe-level == ', $SAFE, "\n" - # This proc object keeps current safe-level ($SAFE==0). + # This proc object keeps current safe-level ($SAFE==0). load file } ip.eval_proc{safe0_cmd.call} |