Novis\Image\Barcode
Makes barcodes: lines of bars that a scanner reads, and the square DataMatrix code.
Members
2 members.
| Member | Signature |
|---|---|
render | render(string $data, Symbology $symbology, ?{ height?: uint, module?: uint, margin?: uint, text?: bool, format?: Format } $options = null): bytes |
svg | svg(string $data, Symbology $symbology, ?{ height?: uint, module?: uint, margin?: uint, text?: bool } $options = null): string |
Enums
Symbology { Code128, Gs1128, Ean13, Ean8, UpcA, Code39, Itf14, DataMatrix }The barcode format thatBarcode::renderandBarcode::svgdraw. A barcode format is also called a symbology.Ean13andUpcAare the barcodes on products in shops.UpcAis used in North America.Ean8is the short form for small products.Itf14is the barcode on a shipping box.Code128andCode39contain text, such as a tracking number.Gs1128contains standard fields, such as a product number and a batch number.DataMatrixis a square code. The others are lines of bars.
Example apps
These complete apps use this class. You can download and run each one.
- PDF documents: A small web app that makes three PDF files. They are an invoice, an encrypted report and event tickets. See each file, then run the app and its tests.
