lib/prawn/images.rb in prawn-1.2.1 vs lib/prawn/images.rb in prawn-1.3.0

- old
+ new

@@ -87,11 +87,11 @@ else # Build the image object info = Prawn.image_handler.find(image_content).new(image_content) # Bump PDF version if the image requires it - min_version(info.min_pdf_version) if info.respond_to?(:min_pdf_version) + renderer.min_version(info.min_pdf_version) if info.respond_to?(:min_pdf_version) # Add the image to the PDF and register it in case we see it again. image_obj = info.build_pdf_object(self) image_registry[image_sha1] = {:obj => image_obj, :info => info} end @@ -121,10 +121,10 @@ label = "I#{next_image_id}" state.page.xobjects.merge!(label => pdf_obj) # add the image to the current page instruct = "\nq\n%.3f 0 0 %.3f %.3f %.3f cm\n/%s Do\nQ" - add_content instruct % [ w, h, x, y - h, label ] + renderer.add_content instruct % [ w, h, x, y - h, label ] end private def verify_and_open_image(io_or_path)