THPDFPage.DrawAztec Method
Encodes Data as an Aztec 2D barcode (ISO/IEC 24778) and renders the symbol as filled module squares at the given page position
Declaration
function DrawAztec(const Data: AnsiString; X, Y: Single; ModuleSize: Single= 2; Color: TColor= clBlack): Integer;
Unit
HPDFDoc
Parameters
| Name | Purpose |
|---|---|
Data | Latin-1 byte payload carried by the symbol |
X | Left edge of the symbol in the current HotPDF coordinate space |
Y | Top edge of the symbol in the current HotPDF coordinate space |
ModuleSize | Width and height of one module square in page units |
Color | Fill colour of the dark modules |
Return value
The symbol size in modules per side, or 0 when the data cannot be encoded
Usage notes
- The smallest fitting symbol is selected automatically: compact 15x15 through 27x27, then full symbols up to 143x143
- The default error correction budget is 33 percent of the data words plus 11 words, matching the ISO/IEC 24778 recommendation
- The encoder is also available directly as
THPDFAztecin theHPDFAztecunit when the raw module matrix is needed - Call this before the page is finalised so the rectangles join the page content stream