Class: String

Inherits:
Object
  • Object
show all
Defined in:
lib/inker/wrappers/string.rb

Overview

The string class, which is wrapped in order to add the possibility to convert a string to Inker::Color.

Instance Method Summary collapse

Instance Method Details

#to_colorInker::Color

Creates a new instance of Inker::Color directly from the string

Examples:

"#000000".to_color

Returns:



10
11
12
# File 'lib/inker/wrappers/string.rb', line 10

def to_color
  Inker.color(self)
end