This repository is private.
All pages are served over SSL and all pushing and pulling is done over SSH.
No one may fork, clone, or view it unless they are added as a member.
Every repository with this icon (
) is private.
Every repository with this icon (
This repository is public.
Anyone may fork, clone, or view it.
Every repository with this icon (
) is public.
Every repository with this icon (
commit 790b14bf5208455fc8bf4a60466a8cf7628c92bd
tree 215f10d54a9c07db84ffd92d1cf659ec70f47d7d
parent 315fc2bc69d9ecc88ab85be13bd1ac149ae409e9
tree 215f10d54a9c07db84ffd92d1cf659ec70f47d7d
parent 315fc2bc69d9ecc88ab85be13bd1ac149ae409e9
rqrcode /
README
== rQRCode, Encode QRCodes rQRCode is a library for encoding QR Codes in Ruby. It has a simple interface with all the standard qrcode options. It was adapted from the Javascript library by Kazuhiko Arase. RubyForge Project Page http://rubyforge.org/projects/rqrcode/ == An Overview Let's clear up some rQRCode stuff. # rQRCode is a *standalone library*. It requires no other libraries. Just Ruby! # It is an encoding library. You can't decode QR codes with it. # The interface is simple and assumes you just want to encode a string into a QR code # QR code is trademarked by Denso Wave inc == Resources wikipedia:: http://en.wikipedia.org/wiki/QR_Code Denso-Wave website:: http://www.denso-wave.com/qrcode/index-e.html kaywa:: http://qrcode.kaywa.com == Installing You may get the latest stable version from Rubyforge. $ gem install rqrcode You can also get the source from http://github.com/whomwah/rqrcode/tree/master $ git clone git://github.com/whomwah/rqrcode.git === Loading rQRCode Itself You have installed the gem already, yeah? require 'rubygems' require 'rqrcode' === Simple QRCode generation to screen qr = RQRCode::QRCode.new( 'my string to generate', :size => 4, :level => :h ) puts qr.to_s # # Prints: # xxxxxxx x x x x x xx xxxxxxx # x x xxx xxxxxx xxx x x # x xxx x xxxxx x xx x xxx x # ... etc === Simple QRCode generation to view (RubyOnRails) <b>Controller:</b> @qr = RQRCode::QRCode.new( 'my string to generate', :size => 4, :level => :h ) <b>View: (minimal styling added)</b> <style type="text/css"> table { border-width: 0; border-style: none; border-color: #0000ff; border-collapse: collapse; } td { border-width: 0; border-style: none; border-color: #0000ff; border-collapse: collapse; padding: 0; margin: 0; width: 10px; height: 10px; } td.black { background-color: #000; } td.white { background-color: #fff; } </style> <table> <% @qr.modules.each_index do |x| %> <tr> <% @qr.modules.each_index do |y| %> <% if @qr.is_dark(x,y) %> <td class="black"/> <% else %> <td class="white"/> <% end %> <% end %> </tr> <% end %> </table> == Contact Author:: Duncan Robertson Email:: duncan@whomwah.com Home Page:: http://whomwah.com License:: MIT Licence (http://www.opensource.org/licenses/mit-license.html)









