diff options
| author | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-12-21 03:12:40 +0000 |
|---|---|---|
| committer | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-12-21 03:12:40 +0000 |
| commit | e618dd0f39befbc449ae219b13997a9cd5a705d8 (patch) | |
| tree | 73115205f8f324be2f13578562c5b2e19027c0ac | |
| parent | 16233238c4f14d5bc0c6d58c877277967611840e (diff) | |
| download | ruby-e618dd0f39befbc449ae219b13997a9cd5a705d8.tar.gz ruby-e618dd0f39befbc449ae219b13997a9cd5a705d8.tar.xz ruby-e618dd0f39befbc449ae219b13997a9cd5a705d8.zip | |
* ext/tk/lib/tk/grid.rb: rescue bug of 'grid configure' on Tcl/Tk8.3-
git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@7620 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
| -rw-r--r-- | ChangeLog | 4 | ||||
| -rw-r--r-- | ext/tk/lib/tk/grid.rb | 11 |
2 files changed, 14 insertions, 1 deletions
@@ -1,3 +1,7 @@ +Tue Dec 21 12:10:04 2004 Hidetoshi NAGAI <nagai@ai.kyutech.ac.jp> + + * ext/tk/lib/tk/grid.rb: rescue bug of 'grid configure' on Tcl/Tk8.3- + Tue Dec 21 00:53:01 2004 Yukihiro Matsumoto <matz@ruby-lang.org> * ext/openssl/ossl_asn1.c (ossl_asn1_traverse): [ruby-dev:25261] diff --git a/ext/tk/lib/tk/grid.rb b/ext/tk/lib/tk/grid.rb index 74287d43b..499101f1b 100644 --- a/ext/tk/lib/tk/grid.rb +++ b/ext/tk/lib/tk/grid.rb @@ -42,7 +42,16 @@ module TkGrid params.push("-#{k}") params.push((v.kind_of?(TkObject))? v.epath: v) } - tk_call_without_enc("grid", 'configure', *params) + if Tk::TCL_MAJOR_VERSION < 8 || + (Tk::TCL_MAJOR_VERSION == 8 && Tk::TCL_MINOR_VERSION <= 3) + if params[0] == '-' || params[0] == 'x' || params[0] == '^' + tk_call_without_enc('grid', *params) + else + tk_call_without_enc('grid', 'configure', *params) + end + else + tk_call_without_enc('grid', 'configure', *params) + end end alias grid configure |
