From d9d5c2e0eeed5cf567dfcb261e419b53eb5dccdb Mon Sep 17 00:00:00 2001 From: nagai Date: Fri, 14 May 2004 09:41:59 +0000 Subject: * ext/tk/lib/tk/canvas.rb: improve coords support for canvas items. Now, supports all of the followings. TkcLine.new(c, 0, 0, 100, 100, :fill=>'red') TkcLine.new(c, [0, 0, 100, 100], :fill=>'red') TkcLine.new(c, [0, 0], [100, 100], :fill=>'red') TkcLine.new(c, [[0, 0], [100, 100]], :fill=>'red') TkcLine.new(c, :coords=>[0, 0, 100, 100], :fill=>'red') TkcLine.new(c, :coords=>[[0, 0], [100, 100]], :fill=>'red') git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@6309 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ext/tk/lib/tk/canvas.rb | 196 +++++++++++++++++++++--------------------------- 1 file changed, 85 insertions(+), 111 deletions(-) (limited to 'ext/tk/lib') diff --git a/ext/tk/lib/tk/canvas.rb b/ext/tk/lib/tk/canvas.rb index 7defecdfe..b311db6e2 100644 --- a/ext/tk/lib/tk/canvas.rb +++ b/ext/tk/lib/tk/canvas.rb @@ -60,12 +60,9 @@ class TkCanvas ['', '', '', self.coords(tagOrId)]} when 'dash', 'activedash', 'disableddash' conf = tk_split_simplelist(tk_send_without_enc('itemconfigure', tagid(tagOrId), @@ -410,6 +417,7 @@ class TkCanvas