Sha256: dc34d6d546ca1f2e9a8cdced3d6bee0fdac31d9fe0909f47d6102ae8901d657e

Contents?: true

Size: 301 Bytes

Versions: 6

Compression:

Stored size: 301 Bytes

Contents

module MultiEncoder
  class QRcodeImage < AbstractImage

    def type
      'qrcodes'
    end

    def write
      qrcode = QREncoder.encode @contents.downcase
      png = qrcode.png @options
      FileUtils.mkdir_p directory
      png.save file_path
      save if respond_to? :save
    end
  end
end

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
barcode_encoder-0.0.9 lib/multi_encoder/images/qrcode.rb
multi_encoder-0.0.9 lib/multi_encoder/images/qrcode.rb
multi_encoder-0.0.8 lib/multi_encoder/images/qrcode.rb
multi_encoder-0.0.7 lib/multi_encoder/images/qrcode.rb
multi_encoder-0.0.6 lib/multi_encoder/images/qrcode.rb
multi_encoder-0.0.5 lib/multi_encoder/images/qrcode.rb