Class: MyFonts::Face

Inherits:
Model
  • Object
show all
Includes:
Previewable
Defined in:
lib/myfonts/face.rb

Instance Attribute Summary

Attributes inherited from Model

#url

Instance Method Summary collapse

Methods included from Previewable

#preview

Methods inherited from Model

#dom

Constructor Details

#initialize(url, name = nil) ⇒ Face

Returns a new instance of Face.



8
9
10
11
# File 'lib/myfonts/face.rb', line 8

def initialize(url, name=nil)
  @name = name
  super(url)
end

Instance Method Details

#familyObject



17
18
19
# File 'lib/myfonts/face.rb', line 17

def family
  @family ||= get_family
end

#nameObject



13
14
15
# File 'lib/myfonts/face.rb', line 13

def name
  @name ||= get_name
end