TPDFlibSBBarcodes

Editions

Description

TPDFlibSBBarcodes (unit PDFlibSBBarcodes) descends from TPDFlibSBLayers and implements the Small Business barcode drawing methods: rMQR, GS1 DataBar Limited, GS1 DataBar Expanded and MaxiCode symbols, rendered as vector content on the selected page.

It belongs to the Small Business edition; the Enterprise edition includes every Small Business class, so it is part of both editions. TPDFlibSBSignReview descends from it and adds the next feature group.

Syntax

Delphi

TPDFlibSBBarcodes = Class(TPDFlibSBLayers);

Key members

DrawRMQRCodeDraws an rMQR code for Text into the box on the selected page; ECLevel and Version are passed to the encoder as its two options
DrawGS1DataBarLimitedDraws a GS1 DataBar Limited symbol for Text into the box on the selected page
DrawGS1DataBarExpandedDraws a GS1 DataBar Expanded symbol for Text into the box on the selected page
DrawMaxiCodeDraws a MaxiCode symbol for Text into the box on the selected page, with Primary as the structured postal message of modes 2 and 3 and Mode selecting the mode

Remarks

All four methods share one drawing routine: the symbol comes from the professional barcode encoder runtime, is scaled uniformly to fit the box and centred in it, and is appended to the page as vector primitives on a white background rectangle. A selected document and page and a finite box with a positive width and height are required; otherwise the method returns 0 with LastErrorCode set to PDFLIB_ERROR_BARCODE_ENCODING.

When the encoder runtime is not available, the methods return 0 and set LastErrorCode to PDFLIB_ERROR_BARCODE_ENCODER_UNAVAILABLE; a failed encoding leaves PDFLIB_ERROR_BARCODE_ENCODING.

Applications normally create TPDFlibSmallBusiness or TPDFlibEnterprise and get the methods of this class through them. The same methods on a plain TPDFlib return 0, an empty string or False and set LastErrorCode to PDFLIB_ERROR_SMALLBUSINESS_REQUIRED.

See also

TPDFlibSBLayers, TPDFlibSBSignReview, TPDFlibSmallBusiness, TPDFlibEnterprise