Sha256: 99866986b3afb01961fec5f2ee46d5cdf1519b602ef39e65c238f8379d87c54a

Contents?: true

Size: 411 Bytes

Versions: 3

Compression:

Stored size: 411 Bytes

Contents

class Prawn::SVG::Elements::Container < Prawn::SVG::Elements::Base
  def parse
    state.disable_drawing = true if name == 'clipPath'

    set_display_none if name == 'symbol' && !state.inside_use
    set_display_none if %w(defs clipPath).include?(name)
  end

  def container?
    true
  end

  private

  def set_display_none
    properties.display = 'none'
    computed_properties.display = 'none'
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
prawn-svg-0.27.1 lib/prawn/svg/elements/container.rb
prawn-svg-0.27.0 lib/prawn/svg/elements/container.rb
prawn-svg-0.26.0 lib/prawn/svg/elements/container.rb