From c6993d3b810317693e295b42a1d6c8fd8b4c702d Mon Sep 17 00:00:00 2001 From: Grzegorz Jakubiak Date: Fri, 23 Oct 2020 10:08:55 +0200 Subject: Alias color to allow British English spelling --- lib/ruby2d/renderable.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/ruby2d/renderable.rb b/lib/ruby2d/renderable.rb index d6e7ae8..c214667 100644 --- a/lib/ruby2d/renderable.rb +++ b/lib/ruby2d/renderable.rb @@ -32,8 +32,8 @@ module Ruby2D end # Allow British English spelling of color - def colour; self.color end - def colour=(c); self.color = c end + alias_method :colour, :color + alias_method :colour=, :color= # Allow shortcuts for setting color values def r; self.color.r end -- cgit v1.2.3