class Fzeet::Windows::SIZE
Public Class Methods
[](cx, cy)
click to toggle source
# File lib/fzeet/windows/core/Size.rb, line 10 def self.[](cx, cy) new.set(cx, cy) end
Also aliased as: from
Public Instance Methods
==(other)
click to toggle source
# File lib/fzeet/windows/core/Size.rb, line 26 def ==(other) self[:cx] == other[:cx] && self[:cy] == other[:cy] end
clear()
click to toggle source
# File lib/fzeet/windows/core/Size.rb, line 24 def clear; set(0, 0) end
dup()
click to toggle source
# File lib/fzeet/windows/core/Size.rb, line 17 def dup; self.class[self[:cx], self[:cy]] end
get()
click to toggle source
# File lib/fzeet/windows/core/Size.rb, line 19 def get; [self[:cx], self[:cy]] end
Also aliased as: to_a
inflate(dx, dy)
click to toggle source
# File lib/fzeet/windows/core/Size.rb, line 28 def inflate(dx, dy) dup.inflate!(dx, dy) end
inflate!(dx, dy)
click to toggle source
# File lib/fzeet/windows/core/Size.rb, line 29 def inflate!(dx, dy) tap { |s| s[:cx] += dx; s[:cy] += dy } end
set(cx, cy)
click to toggle source
# File lib/fzeet/windows/core/Size.rb, line 22 def set(cx, cy) tap { |s| s[:cx], s[:cy] = cx, cy } end