Sha256: e93a86ca905b3b5a24f3ba69f2a41d8306ccc2bbd9a9ad2f4b59e1b22e32f888
Contents?: true
Size: 546 Bytes
Versions: 30
Compression:
Stored size: 546 Bytes
Contents
require_relative "base_index" module Fontist module Indexes class PreferredFamilyFontIndex < BaseIndex def self.path Fontist.formula_preferred_family_index_path end def add_formula(formula) formula.fonts.each do |font| font.styles.each do |style| font_name = style.preferred_family_name || font.name add_index_formula(font_name, formula.to_index_formula) end end end def normalize_key(key) key.downcase end end end end
Version data entries
30 entries across 30 versions & 1 rubygems