Class: Quartz::Size

Inherits:
Object
  • Object
show all
Defined in:
lib/rubyquartz/size.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(width, height) ⇒ Size

Returns a new instance of Size.



30
31
32
33
# File 'lib/rubyquartz/size.rb', line 30

def initialize(width, height)
  @width = width
  @height = height
end

Instance Attribute Details

#heightObject

Returns the value of attribute height.



28
29
30
# File 'lib/rubyquartz/size.rb', line 28

def height
  @height
end

#widthObject

Returns the value of attribute width.



28
29
30
# File 'lib/rubyquartz/size.rb', line 28

def width
  @width
end

Instance Method Details

#to_sObject



35
36
37
# File 'lib/rubyquartz/size.rb', line 35

def to_s
  "(#{@width}, #{@height})"
end