diff options
author | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-10-11 04:51:21 +0000 |
---|---|---|
committer | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-10-11 04:51:21 +0000 |
commit | 3514110b89bee5c37e308b4ca887e66dfe841456 (patch) | |
tree | d280d8542cc44d1cd1a75e8ec87b1f9d231561b7 /ext/tk/lib/tkextlib/itcl/incr_tcl.rb | |
parent | 05f5928c9d0f094d1e7e21a9bd9d8a8fc2f1a805 (diff) |
* ext/tk/lib/tk/*: untabify
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7029 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/tk/lib/tkextlib/itcl/incr_tcl.rb')
-rw-r--r-- | ext/tk/lib/tkextlib/itcl/incr_tcl.rb | 60 |
1 files changed, 30 insertions, 30 deletions
diff --git a/ext/tk/lib/tkextlib/itcl/incr_tcl.rb b/ext/tk/lib/tkextlib/itcl/incr_tcl.rb index 9e53a9be8b..c03f3c36cb 100644 --- a/ext/tk/lib/tkextlib/itcl/incr_tcl.rb +++ b/ext/tk/lib/tkextlib/itcl/incr_tcl.rb @@ -24,9 +24,9 @@ module Tk def self.package_version begin - TkPackage.require('Itcl') + TkPackage.require('Itcl') rescue - '' + '' end end @@ -39,59 +39,59 @@ module Tk ITCL_OBJ_TBL = {}.taint def initialize(*args) - if (@klass = self.class::ITCL_CLASSNAME).empty? - fail RuntimeError, 'unknown itcl class (abstract class?)' - end - @id = Tk::Itcl::ItclObject::TCL_OBJ_ID.join(TkCore::INTERP._ip_id_) - @path = @id - Tk::Itcl::ItclObject::ITCL_OBJ_ID[1].succ! + if (@klass = self.class::ITCL_CLASSNAME).empty? + fail RuntimeError, 'unknown itcl class (abstract class?)' + end + @id = Tk::Itcl::ItclObject::TCL_OBJ_ID.join(TkCore::INTERP._ip_id_) + @path = @id + Tk::Itcl::ItclObject::ITCL_OBJ_ID[1].succ! end def self.call_proc(name, *args) - tk_call("#{ITCL_CLASSNAME}::#{cmd}", *args) + tk_call("#{ITCL_CLASSNAME}::#{cmd}", *args) end def call_method(name, *args) - tk_call(@path, name, *args) + tk_call(@path, name, *args) end def isa(klass) - bool(tk_call(@path, 'isa', klass)) + bool(tk_call(@path, 'isa', klass)) end alias itcl_kind_of? isa def info_class - tk_call(@path, 'info', 'class') + tk_call(@path, 'info', 'class') end def info_inherit - simplelist(tk_call(@path, 'info', 'inherit')) + simplelist(tk_call(@path, 'info', 'inherit')) end def info_heritage - list(tk_call(@path, 'info', 'heritage')) + list(tk_call(@path, 'info', 'heritage')) end def info_function(*args) - if args[-1].kind_of?(Array) - params = args.pop - params.each{|param| - param = param.to_s - args << ( (param[0] == ?-)? param: "-#{param}" ) - } - end - list(tk_call(@path, 'info', 'function', *args)) + if args[-1].kind_of?(Array) + params = args.pop + params.each{|param| + param = param.to_s + args << ( (param[0] == ?-)? param: "-#{param}" ) + } + end + list(tk_call(@path, 'info', 'function', *args)) end def info_variable(*args) - if args[-1].kind_of?(Array) - params = args.pop - params.each{|param| - param = param.to_s - args << ( (param[0] == ?-)? param: "-#{param}" ) - } - end - list(tk_call(@path, 'info', 'variable', *args)) + if args[-1].kind_of?(Array) + params = args.pop + params.each{|param| + param = param.to_s + args << ( (param[0] == ?-)? param: "-#{param}" ) + } + end + list(tk_call(@path, 'info', 'variable', *args)) end end |