Delphi is a structured communication technique or method, originally developed as a systematic, interactive forecasting method which relies on a panel of experts. Delphi is a programming language and software development kit (SDK) for desktop, mobile, web and console applications. Delphi’s compilers use their own Object Pascal dialect of Pascal and generate native code for several platforms: Windows (x86 and x64), OS X (32-bit only), iOS (32 and 64-bit) and Android.

Delphi application is reliable and creative exploration of ideas or the production of suitable information for decision making.The Delphi Technique is a method used to estimate the likelihood and outcome of future events. A group of experts exchange views, and each independently gives estimates and assumptions to a facilitator who reviews the data and issues a summary report.
For more than 20 years, Delphi Technology has been a leading provider of technology solutions to the insurance and risk management industries. By leveraging its extensive industry knowledge and experience. Delphi Technology delivers a comprehensive range of innovative technology solutions for professional liability insurers, property and casualty carriers, third party administrators (TPAs), self insureds, and risk retention groups (RRGs).

1a

 Generating QR-Code Using Delphi

In Delphi Barcodes :: A QR code is a specific barcode, when phones with camera allowed mobile phone users to quickly scan the image and get more info on a product, business, event, offer, URL address. QR (quick response) codes can be used to encode URL, text or other data. Most smartphones like iPhones and Android phones now have apps that let you to read QR codes. When your mobile reads (scans) a QR Code, the QR code will then send you off to a website or online voucher or an online business card.The QR code system became popular outside the automotive industry due to its fast readability and greater storage capacity compared to standard UPC barcodes. Applications include product tracking, item identification, time tracking, document management and general marketing.

2a

Using Delphi there are several ways you can generate QR codes – to encode any text (URL, phone number, simple message). QR Codes store up to 4,296 alphanumeric characters of arbitrary text.

3a
A QR code (Quick Response Code) is a specific 2D barcode, the 2D Barcode VCL components is a set of components designed for generating and printing barcode symbols in your Delphi or C++ Builder applications. Using the components set like any other VCL components. Encrypted QR codes, which are not very common and have a few implementations.
One-dimensional barcodes that were designed to be mechanically scanned by a narrow beam of light, a QR code is detected by a 2-dimensional digital image sensor and then digitally analyzed by a programmed processor. The processor locates the three distinctive squares at the corners of the QR code image, using a smaller square (or multiple squares) near the fourth corner to normalize the image for size, orientation, and angle of viewing. The small dots throughout the QR code are then converted to binary numbers and validated with an error-correcting algorithm. The amount of data that can be stored in the QR code symbol depends on the datatype (mode, or input character set), version (1, …, 40, indicating the overall dimensions of the symbol) and error correction level. The maximum storage capacities occur for 40-L symbols.

QR Codes can easily be displayed inside ReportBuilder reports using a variety of third party libraries currently available. Below is a list of components along with the features they offer.

  • Quricol: Open source QR Code generator that uses QRencode library. Requires a DLL file in order to function which must be deployed with your application.
  • PSoft Barcode Studio: Commercial Delphi barcode generating library capable of creating QR Codes. Directly supports ReportBuilder.
  • Han-soft 2D Barcodes: Commercial Delphi barcode generating library capable of creating QR Codes. Directly supports ReportBuilder.
  • J4L Barcodes for Delphi: Commercial Delphi barcode generating library capable of creating QR Codes.

umang_india

Usage of QR codes
Code payments- QR codes can be used to store bank account information or credit card information, they can be specifically designed to work with particular payment provider applications and in the field of cryptographic currencies, payment addresses, cryptographic keys and transaction information are often shared between digital wallets in this way. Website login- QR codes can be used to log in into websites: a QR code is shown on the login page on a computer screen and when a registered user scans it with a verified smartphone, they will automatically be logged in. Authentication is performed by the smartphone which contacts the server.

Generating QR Codes Using Delphi – DelphiZXingQRCode – Open Source

DelphiZXingQRCode is a Delphi port of the QR Code functionality in ZXing, an open source barcode image processing library. DelphiZXingQRCode is a single-unit implementation you simply add to your (new or) existing project, set a few properties and paint the image. DelphiZXingQRCode (for the moment) supports auto, numeric, alphanumeric, ISO-8859-1, UTF-8 without Bom and UTF-8 with Bom encoding.
If you need to include the generation of QR barcode images in your Delphi application, you might want to take a look at open source “DelphiZXingQRCode” – a Delphi port of the QR Code functionality in ZXing, an open source barcode image processing library.

Just a few lines of code, TDelphiZXingQRCode related and your QR is ready: Sample Delphi code:
4a

If you only need the image generated out of your application, you might want to try this fantastic free online QR Code Generator from the ZXing Project.
J4L Components includes the QR-code implementation featuring: auto, byte, alpha, numeric and kanji encoding. The Google Chart Tools (Chart API) also let you generate QR-code images using an HTTP POST or GET methods –Generating Qr Codes with Delphi and Google Chart API

Encoding
The format information records two things: the error correction level and the mask pattern used for the symbol. Masking is used to break up patterns in the data area that might confuse a scanner, such as large blank areas or misleading features that look like the locator marks. The mask patterns are defined on a grid that is repeated as necessary to cover the whole symbol. Modules corresponding to the dark areas of the mask are inverted. The format information is protected from errors with a BCH code, and two complete copies are included in each QR symbol.


FireMonkey / Mobile (Android, iOS) QR Code Generation Using Delphi XE 5 / DelphiZXingQRCode

The DelphiZXingQRCode unit, ported from ZXing allows to easily add QR Code generation to your Delphi VCL applications.
While the DelphiZXingQRCode was designed to support VCL applications (and be used in newer as well as in older Delphi versions), it can also easily be “upgraded” for Fire Monkey applications – for desktop or mobile (Android, iOS).

DelphiZXingQRCode -> FireMonkey Support
To FireMonkey-enable the DelphiZXingQRCode unit a few changes to the source code were required. The unit uses “contnrs” (System.Contnrs.pas) unit which implements TObjectList (used by the unit) and other container like classes. Under FireMonkey for mobile, more specifically under ARC, the classes contained in System.Contnrs.pas cannot be used because they are not ARC compliant.
Equivalent classes are to be found in
System.Generics.Collections.pas (ARC compliant) where generics versions of TObjectList is defined. Therefore, the first change is to replace “uses contnrs, …” with “uses System.Generics.Collections, …”
This also requires to make changes like: from “Blocks: TObjectList;” to “Blocks: TObjectList<TBlockPair>;” – that is to use strongly typed generics list classes.
Further, there are lots of “ansistring” and “widestring” types used for parameters in various functions inside the unit. If you want to go mobile, those are not supported and you should use “string”. More info here:
Migrating Delphi Code to Mobile from Desktop. Therefore, the second change to the unit would be to replace “widestring” with “string” and “ansistring” with “array of byte” (or something else as explained in the article).

Single Pixel Drawing (and Other Canvas Drawing) FireMonkey Style
In the VCL, the TCanvas class allows accessing single pixels through the “Canvas.Pixels()” property. In FireMonkey this is not supported and you have to use the SetPixel property of a TBitmapData instance.
Once the qr code is generated, to convert it to a bitmap image, in FireMonkey:
5a

VCL’s Canvas.StretchDraw to FMX’s Canvas.DrawBitmap
There’s no StrecthDraw in FMX’s Canvas class. There’s DrawBitmap. StretchDraw by default does no antialiasing. Using TImage, the code to get/display the generated QR Code is as follows:
6a
By default, in FMX, when using DrawBitmap to resize it, antialiasing is used by default. There are two properties you need to set to ensure a bigger copy of your (small) qr code is drawn pixel-copy-perfect. FMX version of DelphiZXIngQRCode.pas: FMX-DelphiZXIngQRCode
7a

Reference links:
1]
https://en.wikipedia.org/wiki/QR_code
2]
https://en.wikipedia.org/wiki/Delphi_(programming_language)
3]http://delphi.about.com/b/2012/05/28/generating-qr-code-using-delphi.htm
4]
http://zarko-gajic.iz.hr/