module Prawn::Markup::HashMerger
Public Class Methods
deep(hash, other)
click to toggle source
# File lib/prawn/markup/support/hash_merger.rb, line 6 def self.deep(hash, other) hash.merge(other) do |_key, this_val, other_val| if this_val.is_a?(Hash) && other_val.is_a?(Hash) deep(this_val, other_val) else other_val end end end
enhance(options, key, hash)
click to toggle source
# File lib/prawn/markup/support/hash_merger.rb, line 16 def self.enhance(options, key, hash) options[key] = hash.merge(options[key]) end