lib/SVGElements/Rect.rb
def to(right, bottom)
			@attributes[:width] = right - @attributes[:x]
			@attributes[:height] = bottom - @attributes[:y]
			yield self if block_given?
			return self
		end
# #to allows a rectangle to be drawn from its top left and bottom right
# coordinates, rather than the top left and the height/width. For
# example Rect.new(1,1).to(2,2) draws the same square as Rect.new(1,1,1,1)
to allows a rectangle to be drawn from its top left and bottom right
coordinates, rather than the top left and the height/width.
to allows a rectangle to be drawn from its top left and bottom right coordinates rather than the top left and the height / width .
def to(right, bottom)
			@attributes[:width] = right - @attributes[:x]
			@attributes[:height] = bottom - @attributes[:y]
			yield self if block_given?
			return self
		end
def to ( right , bottom ) @attributes [ :width ] = right - @attributes [ :x ] @attributes [ :height ] = bottom - @attributes [ :y ] yield self if block_given? return self end
to allows a rectangle to be drawn from its top left and bottom right
coordinates, rather than the top left and the height/width.
to allows a rectangle to be drawn from its top left and bottom right coordinates rather than the top left and the height / width .
right
bottom